mirror of
https://sourceware.org/git/binutils-gdb.git
synced 2024-11-29 04:53:56 +08:00
garbage collect gdb/breakpoint.c:breakpoint_thread_match
Used to be necessary for the thread-hop code, but that's gone now. Nothing uses this anymore. gdb/ 2014-11-04 Pedro Alves <palves@redhat.com> * breakpoint.c (breakpoint_thread_match): Delete function. * breakpoint.h (breakpoint_thread_match): Delete declaration.
This commit is contained in:
parent
79f2a78e76
commit
441ef17f09
@ -1,3 +1,8 @@
|
|||||||
|
2014-11-04 Pedro Alves <palves@redhat.com>
|
||||||
|
|
||||||
|
* breakpoint.c (breakpoint_thread_match): Delete function.
|
||||||
|
* breakpoint.h (breakpoint_thread_match): Delete declaration.
|
||||||
|
|
||||||
2014-11-03 Siva Chandra Reddy <sivachandra@google.com>
|
2014-11-03 Siva Chandra Reddy <sivachandra@google.com>
|
||||||
|
|
||||||
PR c++/17494
|
PR c++/17494
|
||||||
|
@ -4322,65 +4322,6 @@ hardware_watchpoint_inserted_in_range (struct address_space *aspace,
|
|||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* breakpoint_thread_match (PC, PTID) returns true if the breakpoint at
|
|
||||||
PC is valid for process/thread PTID. */
|
|
||||||
|
|
||||||
int
|
|
||||||
breakpoint_thread_match (struct address_space *aspace, CORE_ADDR pc,
|
|
||||||
ptid_t ptid)
|
|
||||||
{
|
|
||||||
struct bp_location *bl, **blp_tmp;
|
|
||||||
/* The thread and task IDs associated to PTID, computed lazily. */
|
|
||||||
int thread = -1;
|
|
||||||
int task = 0;
|
|
||||||
|
|
||||||
ALL_BP_LOCATIONS (bl, blp_tmp)
|
|
||||||
{
|
|
||||||
if (bl->loc_type != bp_loc_software_breakpoint
|
|
||||||
&& bl->loc_type != bp_loc_hardware_breakpoint)
|
|
||||||
continue;
|
|
||||||
|
|
||||||
/* ALL_BP_LOCATIONS bp_location has bl->OWNER always non-NULL. */
|
|
||||||
if (!breakpoint_enabled (bl->owner)
|
|
||||||
&& bl->owner->enable_state != bp_permanent)
|
|
||||||
continue;
|
|
||||||
|
|
||||||
if (!breakpoint_location_address_match (bl, aspace, pc))
|
|
||||||
continue;
|
|
||||||
|
|
||||||
if (bl->owner->thread != -1)
|
|
||||||
{
|
|
||||||
/* This is a thread-specific breakpoint. Check that ptid
|
|
||||||
matches that thread. If thread hasn't been computed yet,
|
|
||||||
it is now time to do so. */
|
|
||||||
if (thread == -1)
|
|
||||||
thread = pid_to_thread_id (ptid);
|
|
||||||
if (bl->owner->thread != thread)
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (bl->owner->task != 0)
|
|
||||||
{
|
|
||||||
/* This is a task-specific breakpoint. Check that ptid
|
|
||||||
matches that task. If task hasn't been computed yet,
|
|
||||||
it is now time to do so. */
|
|
||||||
if (task == 0)
|
|
||||||
task = ada_get_task_number (ptid);
|
|
||||||
if (bl->owner->task != task)
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (overlay_debugging
|
|
||||||
&& section_is_overlay (bl->section)
|
|
||||||
&& !section_is_mapped (bl->section))
|
|
||||||
continue; /* unmapped overlay -- can't be a match */
|
|
||||||
|
|
||||||
return 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/* bpstat stuff. External routines' interfaces are documented
|
/* bpstat stuff. External routines' interfaces are documented
|
||||||
|
@ -1144,9 +1144,6 @@ extern int hardware_watchpoint_inserted_in_range (struct address_space *,
|
|||||||
CORE_ADDR addr,
|
CORE_ADDR addr,
|
||||||
ULONGEST len);
|
ULONGEST len);
|
||||||
|
|
||||||
extern int breakpoint_thread_match (struct address_space *,
|
|
||||||
CORE_ADDR, ptid_t);
|
|
||||||
|
|
||||||
/* Returns true if {ASPACE1,ADDR1} and {ASPACE2,ADDR2} represent the
|
/* Returns true if {ASPACE1,ADDR1} and {ASPACE2,ADDR2} represent the
|
||||||
same breakpoint location. In most targets, this can only be true
|
same breakpoint location. In most targets, this can only be true
|
||||||
if ASPACE1 matches ASPACE2. On targets that have global
|
if ASPACE1 matches ASPACE2. On targets that have global
|
||||||
|
Loading…
Reference in New Issue
Block a user