mirror of
https://github.com/darlinghq/darling-gdb.git
synced 2025-03-05 16:09:49 +00:00
PR binutils/10654
* dwarf2.c (lookup_address_in_line_info_table): Remove workaround for invalid location lists generated by gcc-2.95 and Intel 6.0 C++. Remove "function" parm, adjust caller.
This commit is contained in:
parent
ffa86b03e5
commit
107601c847
@ -1,3 +1,10 @@
|
||||
2009-09-24 Alan Modra <amodra@bigpond.net.au>
|
||||
|
||||
PR binutils/10654
|
||||
* dwarf2.c (lookup_address_in_line_info_table): Remove workaround
|
||||
for invalid location lists generated by gcc-2.95 and Intel 6.0 C++.
|
||||
Remove "function" parm, adjust caller.
|
||||
|
||||
2009-09-23 Matt Rice <ratmice@gmail.com>
|
||||
|
||||
* bfd-in.h (bfd_elf_size_dynamic_sections): Add audit and depaudit
|
||||
@ -920,21 +927,21 @@
|
||||
|
||||
2009-07-22 H.J. Lu <hongjiu.lu@intel.com>
|
||||
|
||||
* elflink.c (elf_link_output_extsym): Revert the last change.
|
||||
* elflink.c (elf_link_output_extsym): Revert the last change.
|
||||
|
||||
2009-07-22 H.J. Lu <hongjiu.lu@intel.com>
|
||||
|
||||
PR ld/10433
|
||||
* elflink.c (elf_link_output_extsym): Special case ifunc syms
|
||||
when ref_regular, not def_regular.
|
||||
PR ld/10433
|
||||
* elflink.c (elf_link_output_extsym): Special case ifunc syms
|
||||
when ref_regular, not def_regular.
|
||||
|
||||
2009-07-21 H.J. Lu <hongjiu.lu@intel.com>
|
||||
|
||||
PR ld/10426
|
||||
* elflink.c (elf_link_add_object_symbols): Turn an IFUNC symbol
|
||||
from a DSO into a normal FUNC symbol.
|
||||
(elf_link_output_extsym): Turn an undefined IFUNC symbol into
|
||||
a normal FUNC symbol.
|
||||
PR ld/10426
|
||||
* elflink.c (elf_link_add_object_symbols): Turn an IFUNC symbol
|
||||
from a DSO into a normal FUNC symbol.
|
||||
(elf_link_output_extsym): Turn an undefined IFUNC symbol into
|
||||
a normal FUNC symbol.
|
||||
|
||||
2009-07-17 Chao-ying Fu <fu@mips.com>
|
||||
|
||||
@ -1083,12 +1090,12 @@
|
||||
* coffcode.h (sec_to_styp_flags): Partially revert (functional
|
||||
changes only) earlier patch:-
|
||||
|
||||
2009-06-25 Kai Tietz <kai.tietz@onevision.com>
|
||||
2009-06-25 Kai Tietz <kai.tietz@onevision.com>
|
||||
|
||||
* coffcode.h (sec_to_styp_flags): Set discardable for .reloc and
|
||||
give .debug and .reloc data characteristics.
|
||||
(DOT_RELOC): New define for .reloc section string.
|
||||
(coff_write_object_contents): Use DOT_RELOC instead of string.
|
||||
* coffcode.h (sec_to_styp_flags): Set discardable for .reloc and
|
||||
give .debug and .reloc data characteristics.
|
||||
(DOT_RELOC): New define for .reloc section string.
|
||||
(coff_write_object_contents): Use DOT_RELOC instead of string.
|
||||
|
||||
2009-07-02 Tom Tromey <tromey@redhat.com>
|
||||
|
||||
@ -2354,9 +2361,9 @@
|
||||
|
||||
2009-05-24 Alan Modra <amodra@bigpond.net.au>
|
||||
|
||||
* bfdio.c (bfd_seek): Formatting. Ensure newly allocated memory
|
||||
for BFD_IN_MEMORY is cleared.
|
||||
(bfd_bwrite): Zero excess memory allocated.
|
||||
* bfdio.c (bfd_seek): Formatting. Ensure newly allocated memory
|
||||
for BFD_IN_MEMORY is cleared.
|
||||
(bfd_bwrite): Zero excess memory allocated.
|
||||
|
||||
2009-05-22 Julian Brown <julian@codesourcery.com>
|
||||
|
||||
|
92
bfd/dwarf2.c
92
bfd/dwarf2.c
@ -1495,95 +1495,27 @@ decode_line_info (struct comp_unit *unit, struct dwarf2_debug *stash)
|
||||
static bfd_boolean
|
||||
lookup_address_in_line_info_table (struct line_info_table *table,
|
||||
bfd_vma addr,
|
||||
struct funcinfo *function,
|
||||
const char **filename_ptr,
|
||||
unsigned int *linenumber_ptr)
|
||||
{
|
||||
/* Note: table->last_line should be a descendingly sorted list. */
|
||||
struct line_info* next_line = table->last_line;
|
||||
struct line_info* each_line = NULL;
|
||||
*filename_ptr = NULL;
|
||||
struct line_info *each_line;
|
||||
|
||||
if (!next_line)
|
||||
return FALSE;
|
||||
for (each_line = table->last_line;
|
||||
each_line;
|
||||
each_line = each_line->prev_line)
|
||||
if (addr >= each_line->address)
|
||||
break;
|
||||
|
||||
each_line = next_line->prev_line;
|
||||
|
||||
/* Check for large addresses */
|
||||
if (addr > next_line->address)
|
||||
each_line = NULL; /* ensure we skip over the normal case */
|
||||
|
||||
/* Normal case: search the list; save */
|
||||
while (each_line && next_line)
|
||||
if (each_line
|
||||
&& !(each_line->end_sequence || each_line == table->last_line))
|
||||
{
|
||||
/* If we have an address match, save this info. This allows us
|
||||
to return as good as results as possible for strange debugging
|
||||
info. */
|
||||
bfd_boolean addr_match = FALSE;
|
||||
if (each_line->address <= addr && addr < next_line->address)
|
||||
{
|
||||
addr_match = TRUE;
|
||||
|
||||
/* If this line appears to span functions, and addr is in the
|
||||
later function, return the first line of that function instead
|
||||
of the last line of the earlier one. This check is for GCC
|
||||
2.95, which emits the first line number for a function late. */
|
||||
|
||||
if (function != NULL)
|
||||
{
|
||||
bfd_vma lowest_pc;
|
||||
struct arange *arange;
|
||||
|
||||
/* Find the lowest address in the function's range list */
|
||||
lowest_pc = function->arange.low;
|
||||
for (arange = &function->arange;
|
||||
arange;
|
||||
arange = arange->next)
|
||||
{
|
||||
if (function->arange.low < lowest_pc)
|
||||
lowest_pc = function->arange.low;
|
||||
}
|
||||
/* Check for spanning function and set outgoing line info */
|
||||
if (addr >= lowest_pc
|
||||
&& each_line->address < lowest_pc
|
||||
&& next_line->address > lowest_pc)
|
||||
{
|
||||
*filename_ptr = next_line->filename;
|
||||
*linenumber_ptr = next_line->line;
|
||||
}
|
||||
else
|
||||
{
|
||||
*filename_ptr = each_line->filename;
|
||||
*linenumber_ptr = each_line->line;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
*filename_ptr = each_line->filename;
|
||||
*linenumber_ptr = each_line->line;
|
||||
}
|
||||
}
|
||||
|
||||
if (addr_match && !each_line->end_sequence)
|
||||
return TRUE; /* we have definitely found what we want */
|
||||
|
||||
next_line = each_line;
|
||||
each_line = each_line->prev_line;
|
||||
}
|
||||
|
||||
/* At this point each_line is NULL but next_line is not. If we found
|
||||
a candidate end-of-sequence point in the loop above, we can return
|
||||
that (compatibility with a bug in the Intel compiler); otherwise,
|
||||
assuming that we found the containing function for this address in
|
||||
this compilation unit, return the first line we have a number for
|
||||
(compatibility with GCC 2.95). */
|
||||
if (*filename_ptr == NULL && function != NULL)
|
||||
{
|
||||
*filename_ptr = next_line->filename;
|
||||
*linenumber_ptr = next_line->line;
|
||||
*filename_ptr = each_line->filename;
|
||||
*linenumber_ptr = each_line->line;
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
*filename_ptr = NULL;
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
@ -2298,7 +2230,7 @@ comp_unit_find_nearest_line (struct comp_unit *unit,
|
||||
if (func_p && (function->tag == DW_TAG_inlined_subroutine))
|
||||
stash->inliner_chain = function;
|
||||
line_p = lookup_address_in_line_info_table (unit->line_table, addr,
|
||||
function, filename_ptr,
|
||||
filename_ptr,
|
||||
linenumber_ptr);
|
||||
return line_p || func_p;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user