Fix typo in t-dimode
[official-gcc.git] / libbacktrace / ChangeLog
blob983f81672fb1d1c7e9fd93b5dca273acc57dae2a
1 2021-11-12  Martin Liska  <mliska@suse.cz>
3         PR libbacktrace/103167
4         * elf.c (elf_uncompress_lzma_block): Cast to unsigned int.
5         (elf_uncompress_lzma): Likewise.
6         * xztest.c (test_samples): memcpy only if v > 0.
8 2021-10-22  Martin Liska  <mliska@suse.cz>
10         PR testsuite/102742
11         * btest.c (MIN_DESCRIPTOR): New.
12         (MAX_DESCRIPTOR): Likewise.
13         (check_available_files): Likewise.
14         (check_open_files): Check only file descriptors that
15         were not available at the entry.
16         (main): Call check_available_files.
18 2021-08-13  Sergei Trofimovich  <siarheit@google.com>
20         * install-debuginfo-for-buildid.sh.in: Force non-localized readelf
21         output with LANG=C.
23 2021-06-28  ClĂ©ment Chigot  <clement.chigot@atos.net>
25         * xcoff.c (SSUBTYP_DWRNGES): New define.
26         (xcoff_add): Use correct XCOFF DWARF section subtype
27         for DEBUG_RANGES. Remove lineoff workaround.
28         Adjust base_address.
29         (xcoff_initialize_syminfo): Adapt to new base_address.
30         (xcoff_lookup_pc): Likewise.
31         (xcoff_initialize_fileline): Likewise.
33 2021-05-03  H.J. Lu  <hjl.tools@gmail.com>
35         PR bootstrap/99703
36         * configure: Regenerated.
38 2021-03-03  Ian Lance Taylor  <iant@golang.org>
40         * dwarf.c (read_line_program): Don't special case file 0.
41         (read_function_entry): Likewise.
43 2021-03-02  Ian Lance Taylor  <iant@golang.org>
45         PR libbacktrace/98818
46         * dwarf.c (dwarf_buf_error): Add errnum parameter.  Change all
47         callers.
48         * backtrace.h: Update backtrace_error_callback comment.
50 2021-02-12  Ian Lance Taylor  <iant@golang.org>
52         * configure.ac: Check for objcopy --add-gnu-debuglink by using
53         objcopy --help.
54         * configure: Regenerate
56 2021-01-18  Ian Lance Taylor  <iant@golang.org>
58         * Makefile.am (%_dwz): If dwz fails, use uncompressed debug info.
59         * Makefile.in: Regenerate.
60         * configure: Regenerate.
62 2021-01-18  Ian Lance Taylor  <iant@golang.org>
64         PR debug/98716
65         * dwarf.c (read_v2_paths): Allocate zero entry for dirs and
66         filenames.
67         (read_line_program): Remove parameter u, change caller.  Don't
68         subtract one from dirs and filenames index.
69         (read_function_entry): Don't subtract one from filenames index.
71 2021-01-05  Samuel Thibault  <samuel.thibault@ens-lyon.org>
73         * configure: Re-generate.
75 2020-12-05  Iain Sandoe  <iain@sandoe.co.uk>
77         PR target/97865
78         * configure: Regenerate.
80 2020-12-02  Ian Lance Taylor  <iant@golang.org>
82         * dwarf.c (resolve_string): Use > rather than >= to check whether
83         string index extends past buffer.
84         (resolve_addr_index): Similarly for address index.
86 2020-11-29  John David Anglin  <danglin@gcc.gnu.org>
88         * configure: Regenerate.
90 2020-10-20  Ian Lance Taylor  <iant@golang.org>
92         * internal.h (ATTRIBUTE_FALLTHROUGH): Define.
93         * elf.c (elf_zlib_inflate): Use ATTRIBUTE_FALLTHROUGH.
95 2020-09-28  Ian Lance Taylor  <iant@golang.org>
97         PR libbacktrace/97082
98         * Makefile.am (check_DATA): Add mtest.dSYM if USE_DSYMUTIL.
99         * Makefile.in: Regenerate.
101 2020-09-28  Ian Lance Taylor  <iant@golang.org>
103         PR libbacktrace/97227
104         * configure.ac (USE_DSYMUTIL): Define instead of HAVE_DSYMUTIL.
105         * Makefile.am: Change all uses of HAVE_DSYMUTIL to USE_DSYMUTIL.
106         * configure: Regenerate.
107         * Makefile.in: Regenerate.
109 2020-09-23  Ian Lance Taylor  <iant@golang.org>
111         * dwarf.c (report_inlined_functions): Handle PC == -1 and PC ==
112         p->low.
113         (dwarf_lookup_pc): Likewise.
115 2020-09-17  Ian Lance Taylor  <iant@golang.org>
117         PR libbacktrace/97080
118         * fileline.c (backtrace_syminfo_to_full_callback): New function.
119         (backtrace_syminfo_to_full_error_callback): New function.
120         * elf.c (elf_nodebug): Call syminfo_fn if possible.
121         * internal.h (struct backtrace_call_full): Define.
122         (backtrace_syminfo_to_full_callback): Declare.
123         (backtrace_syminfo_to_full_error_callback): Declare.
124         * mtest.c (f3): Only check all[i] if data.index permits.
126 2020-09-16  Iain Sandoe  <iain@sandoe.co.uk>
128         * macho.c (MACH_O_CPU_TYPE_PPC): New.
129         (MACH_O_CPU_TYPE_PPC64): New.
130         Add compile-tests for powerpc to the Mach-O variants.
132 2020-09-14  Ian Lance Taylor  <iant@golang.org>
134         PR libbacktrace/93608
135         Add support for MiniDebugInfo.
136         * elf.c (struct elf_view): Define.  Replace most uses of
137         backtrace_view with elf_view.
138         (elf_get_view): New static functions.  Replace most calls of
139         backtrace_get_view with elf_get_view.
140         (elf_release_view): New static functions.  Replace most calls of
141         backtrace_release_view with elf_release_view.
142         (elf_uncompress_failed): Rename from elf_zlib_failed.  Change all
143         callers.
144         (LZMA_STATES, LZMA_POS_STATES, LZMA_DIST_STATES): Define.
145         (LZMA_DIST_SLOTS, LZMA_DIST_MODEL_START): Define.
146         (LZMA_DIST_MODEL_END, LZMA_FULL_DISTANCES): Define.
147         (LZMA_ALIGN_SIZE, LZMA_LEN_LOW_SYMBOLS): Define.
148         (LZMA_LEN_MID_SYMBOLS, LZMA_LEN_HIGH_SYMBOLS): Define.
149         (LZMA_LITERAL_CODERS_MAX, LZMA_LITERAL_CODER_SIZE): Define.
150         (LZMA_PROB_IS_MATCH_LEN, LZMA_PROB_IS_REP_LEN): Define.
151         (LZMA_PROB_IS_REP0_LEN, LZMA_PROB_IS_REP1_LEN): Define.
152         (LZMA_PROB_IS_REP2_LEN, LZMA_PROB_IS_REP0_LONG_LEN): Define.
153         (LZMA_PROB_DIST_SLOT_LEN, LZMA_PROB_DIST_SPECIAL_LEN): Define.
154         (LZMA_PROB_DIST_ALIGN_LEN): Define.
155         (LZMA_PROB_MATCH_LEN_CHOICE_LEN): Define.
156         (LZMA_PROB_MATCH_LEN_CHOICE2_LEN): Define.
157         (LZMA_PROB_MATCH_LEN_LOW_LEN): Define.
158         (LZMA_PROB_MATCH_LEN_MID_LEN): Define.
159         (LZMA_PROB_MATCH_LEN_HIGH_LEN): Define.
160         (LZMA_PROB_REP_LEN_CHOICE_LEN): Define.
161         (LZMA_PROB_REP_LEN_CHOICE2_LEN): Define.
162         (LZMA_PROB_REP_LEN_LOW_LEN): Define.
163         (LZMA_PROB_REP_LEN_MID_LEN): Define.
164         (LZMA_PROB_REP_LEN_HIGH_LEN): Define.
165         (LZMA_PROB_LITERAL_LEN): Define.
166         (LZMA_PROB_IS_MATCH_OFFSET, LZMA_PROB_IS_REP_OFFSET): Define.
167         (LZMA_PROB_IS_REP0_OFFSET, LZMA_PROB_IS_REP1_OFFSET): Define.
168         (LZMA_PROB_IS_REP2_OFFSET): Define.
169         (LZMA_PROB_IS_REP0_LONG_OFFSET): Define.
170         (LZMA_PROB_DIST_SLOT_OFFSET): Define.
171         (LZMA_PROB_DIST_SPECIAL_OFFSET): Define.
172         (LZMA_PROB_DIST_ALIGN_OFFSET): Define.
173         (LZMA_PROB_MATCH_LEN_CHOICE_OFFSET): Define.
174         (LZMA_PROB_MATCH_LEN_CHOICE2_OFFSET): Define.
175         (LZMA_PROB_MATCH_LEN_LOW_OFFSET): Define.
176         (LZMA_PROB_MATCH_LEN_MID_OFFSET): Define.
177         (LZMA_PROB_MATCH_LEN_HIGH_OFFSET): Define.
178         (LZMA_PROB_REP_LEN_CHOICE_OFFSET): Define.
179         (LZMA_PROB_REP_LEN_CHOICE2_OFFSET): Define.
180         (LZMA_PROB_REP_LEN_LOW_OFFSET): Define.
181         (LZMA_PROB_REP_LEN_MID_OFFSET): Define.
182         (LZMA_PROB_REP_LEN_HIGH_OFFSET): Define.
183         (LZMA_PROB_LITERAL_OFFSET): Define.
184         (LZMA_PROB_TOTAL_COUNT): Define.
185         (LZMA_IS_MATCH, LZMA_IS_REP, LZMA_IS_REP0): Define.
186         (LZMA_IS_REP1, LZMA_IS_REP2, LZMA_IS_REP0_LONG): Define.
187         (LZMA_DIST_SLOT, LZMA_DIST_SPECIAL, LZMA_DIST_ALIGN): Define.
188         (LZMA_MATCH_LEN_CHOICE, LZMA_MATCH_LEN_CHOICE2): Define.
189         (LZMA_MATCH_LEN_LOW, LZMA_MATCH_LEN_MID): Define.
190         (LZMA_MATCH_LEN_HIGH, LZMA_REP_LEN_CHOICE): Define.
191         (LZMA_REP_LEN_CHOICE2, LZMA_REP_LEN_LOW): Define.
192         (LZMA_REP_LEN_MID, LZMA_REP_LEN_HIGH, LZMA_LITERAL): Define.
193         (elf_lzma_varint): New static function.
194         (elf_lzma_range_normalize): New static function.
195         (elf_lzma_bit, elf_lzma_integer): New static functions.
196         (elf_lzma_reverse_integer): New static function.
197         (elf_lzma_len, elf_uncompress_lzma_block): New static functions.
198         (elf_uncompress_lzma): New static function.
199         (backtrace_uncompress_lzma): New function.
200         (elf_add): Add memory and memory_size parameters.  Change all
201         callers.  Look for .gnu_debugdata section, and, if found,
202         decompress it and use it for symbols and debug info.  Permit the
203         descriptor parameter to be -1.
204         * internal.h (backtrace_uncompress_lzma): Declare.
205         * mtest.c: New file.
206         * xztest.c: New file.
207         * configure.ac: Check for nm, xz, and comm programs.  Check for
208         liblzma library.
209         (HAVE_MINIDEBUG): Define.
210         * Makefile.am (mtest_SOURCES): Define.
211         (mtest_CFLAGS, mtest_LDADD): Define.
212         (TESTS): Add mtest_minidebug if HAVE_MINIDEBUG.
213         (%_minidebug): New pattern rule, if HAVE_MINIDEBUG.
214         (xztest_SOURCES, xztest_CFLAGS, xztest_LDADD): Define.
215         (xztest_alloc_SOURCES, xztest_alloc_CFLAGS): Define
216         (xztest_alloc_LDADD): Define.
217         (BUILDTESTS): Add mtest, xztest, xztest_alloc.
218         (CLEANFILES): Add files created by minidebug pattern.
219         (btest.lo): Correct INCDIR reference.
220         (mtest.lo, xztest.lo, ztest.lo): New targets.
221         * configure: Regenerate.
222         * config.h.in: Regenerate.
223         * Makefile.in: Regenerate.
225 2020-09-09  Ian Lance Taylor  <iant@golang.org>
227         * pecoff.c (coff_initialize_syminfo): Add is_64 parameter.
228         (coff_add): Determine and pass is_64.
230 2020-09-09  Ian Lance Taylor  <iant@golang.org>
232         PR libbacktrace/96973
233         * fileline.c (macho_get_executable_path): New static function.
234         (fileline_initialize): Call macho_get_executable_path.
236 2020-09-09  Ian Lance Taylor  <iant@golang.org>
238         * dwarf.c (function_addrs_search): Compare against the next entry
239         low address, not the high address.
240         (unit_addrs_search): Likewise.
241         (build_address_map): Add a trailing unit_addrs.
242         (read_function_entry): Add a trailing function_addrs.
243         (read_function_info): Likewise.
244         (report_inlined_functions): Search backward for function_addrs
245         match.
246         (dwarf_lookup_pc): Search backward for unit_addrs and
247         function_addrs matches.
249 2020-09-08  Ian Lance Taylor  <iant@golang.org>
251         * simple.c (simple_unwind): Correct comment spelling.
253 2020-09-08  Ian Lance Taylor  <iant@golang.org>
255         * macho.c (macho_add_dsym): Make space for '/' in dsym.  Use
256         correct length when freeing diralc.
258 2020-09-08  Ian Lance Taylor  <iant@golang.org>
260         PR libbacktrace/96973
261         * macho.c (macho_add_fat): Correctly swap 32-bit file offset.
263 2020-09-08  Ian Lance Taylor  <iant@golang.org>
265         PR libbacktrace/96971
266         * filetype.awk: Only match magic number at start of line.
268 2020-08-24  Ian Lance Taylor  <iant@golang.org>
270         * macho.c (MACH_O_MH_MAGIC_FAT_64): Define.
271         (MACH_O_MH_CIGAM_FAT_64): Define.
272         (struct macho_fat_arch_64): Define.
273         (macho_add_fat): Add and use is_64 parameter.
274         (macho_add): Recognize 64-bit fat files.
276 2020-07-30  H.J. Lu  <hjl.tools@gmail.com>
278         PR bootstrap/96202
279         * configure: Regenerated.
281 2020-07-08  Ian Lance Taylor  <iant@golang.org>
283         * configure.ac: Test linker support for DWARF5
284         * configure: Regenerate
286 2020-05-29  H.J. Lu  <hjl.tools@gmail.com>
288         PR bootstrap/95413
289         * configure: Regenerated.
291 2020-05-15  H.J. Lu  <hongjiu.lu@intel.com>
293         PR bootstrap/95147
294         * configure: Regenerated.
296 2020-05-14  H.J. Lu  <hongjiu.lu@intel.com>
298         * configure: Regenerated.
300 2020-05-13  Ian Lance Taylor  <iant@golang.org>
302         * ztest.c (test_large): Mark state ATTRIBUTE_UNUSED.
304 2020-05-13  Ian Lance Taylor  <iant@golang.org>
306         PR go/95061
307         * posix.c (backtrace_open): Treat EACCESS like ENOENT.
309 2020-05-12  H.J. Lu  <hongjiu.lu@intel.com>
311         * Makefile.am (AM_CFLAGS): Add $(CET_HOST_FLAGS).
312         * configure.ac: Add GCC_CET_HOST_FLAGS(CET_HOST_FLAGS) and
313         AC_SUBST(CET_HOST_FLAGS).  Clear CET_HOST_FLAGS if jit isn't
314         enabled.
315         * Makefile.in: Regenerated.
316         * configure: Likewise.
318 2020-05-11  Ian Lance Taylor  <iant@golang.org>
320         PR libbacktrace/95012
321         * configure.ac: Check for getpagesize declaration.
322         * mmap.c: Declare getpagesize if necessary.
323         * mmapio.c: Likewise.
324         * configure: Regenerate.
325         * config.h.in: Regenerate.
326         * Makefile.in: Regenerate.
328 2020-05-09  Roland McGrath  <mcgrathr@google.com>
330         * elf.c (elf_add): Bail early if there are no section headers at all.
332 2020-05-09  Ian Lance Taylor  <iant@golang.org>
334         * elf.c (elf_add): Don't free strtab if an error occurs after
335         recording symbol information.
337 2020-05-09  Ian Lance Taylor  <iant@golang.org>
339         PR libbacktrace/88745
340         * macho.c: New file.
341         * filetype.awk: Recognize Mach-O files.
342         * Makefile.am (FORMAT_FILES): Add macho.c.
343         (check_DATA): New variable.  Set to .dSYM if HAVE_DSYMUTIL.
344         (%.dSYM): New pattern target.
345         (test_macho_SOURCES, test_macho_CFLAGS): New targets.
346         (test_macho_LDADD): New target.
347         (BUILDTESTS): Add test_macho.
348         (macho.lo): Add dependencies.
349         * configure.ac: Recognize macho file type.  Check for
350         mach-o/dyld.h.  Don't try to run objcopy if we don't find it.
351         Look for dsymutil and define a HAVE_DSYMUTIL conditional.
352         * Makefile.in: Regenerate.
353         * configure: Regenerate.
354         * config.h.in: Regenerate.
356 2020-05-09  Ian Lance Taylor  <iant@golang.org>
358         * read.c (backtrace_get_view): Support short read.
360 2020-05-09  Ian Lance Taylor  <iant@golang.org>
362         * elf.c (elf_add): If debug sections are very large or far apart,
363         read them individually rather than as a single view.
365 2020-05-08  Ian Lance Taylor  <iant@golang.org>
367         * fileline.c (sysctl_exec_name): New static function.
368         (sysctl_exec_name1): New macro or static function.
369         (sysctl_exec_name2): Likewise.
370         (fileline_initialize): Try sysctl_exec_name[12].
371         * configure.ac: Check for sysctl args to fetch executable name.
372         * configure: Regenerate.
373         * config.h.in: Regenerate.
375 2020-02-15  Ian Lance Taylor  <iant@golang.org>
377         * ztest.c (test_large): Update file to current libgo test file.
379 2020-02-03  Ian Lance Taylor  <iant@golang.org>
381         * Makefile.am (libbacktrace_TEST_CFLAGS): Define.
382         (test_elf32_CFLAGS): Use $(libbacktrace_test_CFLAGS).
383         (test_elf_64_CFLAGS, test_xcoff_32_CFLAGS): Likewise.
384         (test_xcoff_64_CFLAGS, test_pecoff_CFLAGS): Likewise.
385         (test_unknown_CFLAGS, unittest_CFLAGS): Likewise.
386         (unittest_alloc_CFLAGS, allocfail_CFLAGS): Likewise.
387         (b2test_CFLAGS, b3test_CFLAGS, btest_CFLAGS): Likewise.
388         (btest_lto_CFLAGS, btest_alloc_CFLAGS, stest_CFLAGS): Likewise.
389         (stest_alloc_CFLAGS): Likewise.
390         * Makefile.in: Regenerate.
391         * ztest.c (error_callback_compress): Mark vdata unused.
392         (test_large): Add casts to avoid warnings.
394 2020-01-01  Jakub Jelinek  <jakub@redhat.com>
396         Update copyright years.
398 2019-12-13  Ian Lance Taylor  <iant@golang.org>
400         Add DWARF 5 support.
401         * dwarf.c (struct attr): Add val field.
402         (enum attr_val_encoding): Add ATTR_VAL_ADDDRESS_INDEX,
403         ATTR_VAL_STRING_INDEX, ATTR_VAL_RNGLISTS_INDEX.
404         (struct line_header): Add addrsize field.
405         (struct line_header_format): Define.
406         (struct unit): Add str_offsets_base, addr_base, and rnglists_base
407         fields.
408         (read_uint24): New static function.
409         (read_attribute): Add implicit_val parameter.  Replace dwarf_str
410         and dwarf_str_size parameters with dwarf_sections parameter.  Add
411         support for new DWARF 5 forms.  Change all callers.
412         (resolve_string): New static function.
413         (resolve_addr_index): Likewise.
414         (read_abbrevs): Support DW_FORM_implicit_const.
415         (struct pcrange): Add lowpc_is_addr_index, highpc_is_addr_Index,
416         and ranges_is_index fields.
417         (update_pcrange): Support DWARF 5 encodings.
418         (add_high_low_range): New static function, split out of
419         add_ranges.
420         (add_ranges_from_ranges): Likewise.
421         (add_ranges_from_rnglists): New static function.
422         (add_ranges): Just call new helper functions.
423         (find_address_ranges): Use resolve_string for strings, after
424         reading all attributes.  Handle new DWARF 5 attributes.
425         (build_address_map): Support DWARF 5 compilation units.
426         (read_v2_paths): New static function, split out of
427         read_line_header.
428         (read_lnct): New static function.
429         (read_line_header_format_entries): Likewise.
430         (read_line_header): Add ddata parameter.  Support DWARF 5 line
431         headers.  Call new helper functions.  Change all callers.
432         (read_line_program): Use addrsize from line program header.  Don't
433         special case directory index 0 for DWARF 5.
434         (read_referenced_name): Use resolve_string.
435         (read_function_entry): Handle DWARF 5 encodings.  Use
436         resolve_string.
437         * internal.h (enum dwarf_section): Add DEBUG_ADDR,
438         DEBUG_STR_OFFSETS, DEBUG_LINE_STR, DEBUG_RNGLISTS.
439         * elf.c (dwarf_section_names): Add new section names.
440         * pecoff.c (dwarf_section_names): Likewise.
441         * xcoff.c (xcoff_add): Clear dwarf_sections before setting
442         fields.
443         * configure.ac: Define HAVE_DWARF5 automake conditional.
444         * Makefile.am (dwarf5_SOURCES): New variable if HAVE_DWARF5.
445         (dwarf5_CFLAGS, dwarf5_LDADD): Likewise.
446         (dwarf5_alloc_SOURCES, dwarf5_alloc_CFLAGS): Likewise.
447         (dwarf5_alloc_LDADD): Likewise.
448         (BUILDTESTS): Add dwarf5 tests if HAVE_DWARF5.
449         (CLEANFILES, clean-local): Define.
451 2019-12-08  Ian Lance Taylor  <iant@golang.org>
453         * dwarf.c (struct pcrange): Define.
454         (update_pcrange, add_ranges): New static functions.
455         (add_unit_addr): Change signature to work with add_ranges.  Don't
456         add base_address here.
457         (add_unit_ranges): Remove.
458         (find_address_ranges): Replace str/ranges parameters with
459         dwarf_sections.  Use update_pcrange and add_ranges.  Change all
460         callers.
461         (add_function_range): Change signature to work with add_ranges.
462         Don't add base_address here.
463         (add_function_ranges): Remove.
464         (read_function_entry): Use update_pcrange and add_ranges.
466 2019-12-04  Ian Lance Taylor  <iant@golang.org>
468         * edtest.c (test1): Add noclone attribute.
470 2019-12-04  Ian Lance Taylor  <iant@golang.org>
472         * internal.h (enum dwarf_section): Define.
473         (struct dwarf_sections): Define.
474         (backtrace_dwarf_add): Update declaration to replace specific
475         section parameters with dwarf_sections parameter.
476         * dwarf.c (struct dwarf_data): Replace specific section fields
477         with dwarf_sections field.
478         (read_attribute): Use dwarf_sections with altlink.
479         (build_address_map): Replace specific section parameters with
480         dwarf_sections parameter.  Change all callers.
481         (read_line_info): Use dwarf_sections with ddata.
482         (read_referenced_name): Likewise.
483         (add_function_ranges): Likewise.
484         (read_function_entry): Likewise.
485         (read_function_info): Likewise.
486         (build_dwarf_data): Replace specific section parameters with
487         dwarf_sections parameter.  Change all callers.
488         (backtrace_dwarf_add): Likewise.
489         * elf.c (enum debug_section): Remove.
490         (dwarf_section_names): Remove .zdebug names.
491         (elf_add): Track zsections separately.  Build dwarf_sections.
492         * pecoff.c (enum debug_section): Remove.
493         (struct debug_section_info): Remove data field.
494         (coff_add): Build dwarf_sections.
495         * xcoff.c (enum dwarf_section): Remove.  Replace DWSECT_xxx
496         references with DEBUG_xxx references.
497         (xcoff_add): Build dwarf_sections.
499 2019-09-27  Maciej W. Rozycki  <macro@wdc.com>
501         * configure: Regenerate.
503 2019-09-26  Ian Lance Taylor  <iant@golang.org>
505         PR libbacktrace/91908
506         * pecoff.c (backtrace_initialize): Explicitly cast unchecked
507         __sync_bool_compare_and_swap to void.
508         * xcoff.c (backtrace_initialize): Likewise.
510 2019-09-03  Ulrich Weigand  <uweigand@de.ibm.com>
512         * configure.ac: Remove references to spu.
513         * configure: Regenerate.
515 2019-05-24  Clement Chigot  <clement.chigot@atos.net>
517         * Makefile.am (BUILDTESTS): Remove test_elf, add test_elf_32 and
518         test_elf_64.
519         * Makefile.in: Regenerate.
521 2019-05-14  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
523         * configure.ac (have_dl_iterate_phdr): Remove *-*-solaris2.10*
524         handling.
525         * configure: Regenerate.
527 2019-03-11  Ian Lance Taylor  <iant@golang.org>
529         PR libbacktrace/89669
530         * Makefile.am (BUILDTESTS): Only add ztest and ztest_alloc if
531         HAVE_ELF.
532         * Makefile.in: Regenerate.
534 2019-02-26  Tom de Vries  <tdevries@suse.de>
536         * btest.c (test5): Allow global.* as minimal symbol name for global.
538 2019-02-26  Tom de Vries  <tdevries@suse.de>
540         * Makefile.am (TESTS): Only add b3test_dwz_buildid if HAVE_DWZ.
541         * Makefile.in: Regenerate.
543 2019-02-12  Tom de Vries  <tdevries@suse.de>
545         PR libbacktrace/81983
546         * dwarf.c (dwarf_lookup_pc): Don't call bsearch if nmemb == 0.
548 2019-02-10  Tom de Vries  <tdevries@suse.de>
550         * Makefile.am (BUILDTESTS): Add btest_lto.
551         * Makefile.in: Regenerate.
552         * btest.c (test1, f2, f3, test3, f22, f23): Declare with
553         __attribute__((noclone)).
555 2019-02-08  Tom de Vries  <tdevries@suse.de>
557         * backtrace.c (backtrace_full): Declare with __attribute__((noinline)).
558         * print.c (backtrace_print): Same.
559         * simple.c (backtrace_simple): Same.
561 2019-02-08  Tom de Vries  <tdevries@suse.de>
563         PR libbacktrace/78063
564         * dwarf.c (build_address_map): Keep all parsed units.
565         (read_referenced_name_from_attr): Handle DW_FORM_ref_addr.
567 2019-01-31  Tom de Vries  <tdevries@suse.de>
569         PR libbacktrace/89136
570         * elf.c (elf_add): Read build-id if with_buildid_data.  Fix
571         'debugaltlink_name_len =+ 1'.
573 2019-01-29  Tom de Vries  <tdevries@suse.de>
575         * install-debuginfo-for-buildid.sh.in: New script.
576         * Makefile.am (check_PROGRAMS): Add b2test and b3test.
577         (TESTS): Add b2test_buildid and b3test_dwz_buildid.
578         * Makefile.in: Regenerate.
579         * configure.ac (HAVE_ELF): Set with AM_CONDITIONAL.
580         (READELF): Set with AC_CHECK_PROG.
581         (install-debuginfo-for-buildid.sh): Generate with AC_CONFIG_FILES.
582         * configure: Regenerate.
583         * elf.c (SYSTEM_BUILD_ID_DIR): Factor out of ...
584         (elf_open_debugfile_by_buildid): ... here.
586 2019-01-29  Tom de Vries  <tdevries@suse.de>
588         * Makefile.am: Replace check_PROGRAMS with BUILDTESTS, except for
589         allocfail.
590         (TESTS): Don't add check_PROGRAMS. Add BUILDTESTS.
591         (check_PROGRAMS): Add BUILDTESTS.
592         * Makefile.in: Regenerate.
594 2019-01-28  Tom de Vries  <tdevries@suse.de>
596         * Makefile.am (xcoff_%.c): Generate sed result into temporary file.
597         Use $< to access prerequisite.
598         * Makefile.in: Regenerate.
600 2019-01-25  Nathan Sidwell  <nathan@acm.org>
602         * elf.c (elf_add): Pass "" filename to recursive call with
603         separated debug.
605 2019-01-25  Tom de Vries  <tdevries@suse.de>
607         * elf.c (elf_add): When handling .gnu_debugaltlink, call elf_add with
608         filename == "".
609         * Makefile.am (TESTS): Add btest_dwz_gnudebuglink.
610         * Makefile.in: Regenerate.
612 2019-01-25  Tom de Vries  <tdevries@suse.de>
614         * Makefile.am: Rewrite dtest rule into "%_gnudebuglink" pattern rule.
615         (TESTS): Rename dtest to btest_gnudebuglink.
616         * Makefile.in: Regenerate.
618 2019-01-23  Tom de Vries  <tdevries@suse.de>
620         * dwarf.c (struct unit): Use size_t for low_offset/high_offset fields.
621         (units_search, find_unit): Use size_t for offset.
622         (build_address_map): Use size_t for unit_offset.
624 2019-01-20  Gerald Pfeifer  <gerald@pfeifer.com>
626         * allocfail.c (main): Increase portability of printf statement.
628 2019-01-18  Ian Lance Taylor  <iant@golang.org>
630         PR libbacktrace/88890
631         * mmapio.c (backtrace_get_view): Change size parameter to
632         uint64_t.  Check that value fits in size_t.
633         * read.c (backtrace_get_view): Likewise.
634         * internal.h (backtrace_get_view): Update declaration.
635         * elf.c (elf_add): Pass shstrhdr->sh_size to backtrace_get_view.
637 2019-01-17  Tom de Vries  <tdevries@suse.de>
639         PR libbacktrace/82857
640         * configure.ac (DWZ): Set with AC_CHECK_PROG.
641         (HAVE_DWZ): Set with AM_CONDITIONAL.
642         * configure: Regenerate.
643         * Makefile.am (TESTS): Add btest_dwz.
644         * Makefile.in: Regenerate.
646 2019-01-17  Tom de Vries  <tdevries@suse.de>
648         PR libbacktrace/82857
649         * dwarf.c (enum attr_val_encoding): Add ATTR_VAL_REF_ALT_INFO.
650         (read_attribute): Handle DW_FORM_GNU_ref_alt using
651         ATTR_VAL_REF_ALT_INFO.
652         (read_referenced_name_from_attr): Handle DW_FORM_GNU_ref_alt.
654 2019-01-17  Tom de Vries  <tdevries@suse.de>
656         * dwarf.c (struct unit): Add low_offset and high_offset fields.
657         (struct unit_vector): New type.
658         (struct dwarf_data): Add units and units_counts fields.
659         (find_unit): New function.
660         (find_address_ranges): Add and handle unit_tag parameter.
661         (build_address_map): Add and handle units_vec parameter.
662         (build_dwarf_data): Pass units_vec to build_address_map.  Store resulting
663         units vector.
665 2019-01-17  Tom de Vries  <tdevries@suse.de>
667         PR libbacktrace/82857
668         * dwarf.c (read_attribute): Handle DW_FORM_GNU_strp_alt
669         using altlink.
671 2019-01-17  Tom de Vries  <tdevries@suse.de>
673         * dwarf.c (enum attr_val_encoding): Add ATTR_VAL_NONE.
674         (read_attribute): Add altlink parameter.  Handle missing altlink for
675         DW_FORM_GNU_strp_alt and DW_FORM_GNU_ref_alt.
676         (find_address_ranges, build_address_map, build_dwarf_data): Add and
677         handle altlink parameter.
678         (read_referenced_name, read_function_entry): Add argument to
679         read_attribute call.
681 2019-01-17  Tom de Vries  <tdevries@suse.de>
683         * dwarf.c (struct dwarf_data): Add altlink field.
684         (backtrace_dwarf_add): Add and handle fileline_altlink parameter.
685         * elf.c (elf_add): Add argument to backtrace_dwarf_add call.
686         (phdr_callback, backtrace_initialize): Add argument to elf_add calls.
687         * internal.h (backtrace_dwarf_add): Add fileline_altlink parameter.
688         * pecoff.c (coff_add): Add argument to backtrace_dwarf_add call.
689         * xcoff.c (xcoff_add): Same.
691 2019-01-17  Tom de Vries  <tdevries@suse.de>
693         * internal.h (backtrace_dwarf_add): Add fileline_entry parameter.
694         * dwarf.c (backtrace_dwarf_add): Add and handle fileline_entry parameter.
695         * elf.c (elf_add): Add and handle fileline_entry parameter.  Add
696         argument to backtrace_dwarf_add call.
697         (phdr_callback, backtrace_initialize): Add argument to elf_add calls.
698         * pecoff.c (coff_add): Add argument to backtrace_dwarf_add call.
699         * xcoff.c (xcoff_add): Same.
701 2019-01-17  Tom de Vries  <tdevries@suse.de>
703         * elf.c (elf_add): Add and handle with_buildid_data and
704         with_buildid_size parameters.  Handle .gnu_debugaltlink section.
705         (phdr_callback, backtrace_initialize): Add arguments to elf_add calls.
707 2019-01-16  Tom de Vries  <tdevries@suse.de>
709         * dwarf.c (read_referenced_name_from_attr): New function.  Factor out
710         of ...
711         (read_referenced_name): ... here, and ...
712         (read_function_entry): ... here.
714 2019-01-16  Tom de Vries  <tdevries@suse.de>
716         * dwarf.c (read_referenced_name): Don't allow DW_AT_name to override any
717         name.
718         (read_function_entry): Same.  Don't allow name found via
719         DW_AT_abstract_origin or case DW_AT_specification to override linkage
720         name.
722 2019-01-09  Sandra Loosemore  <sandra@codesourcery.com>
724         PR other/16615
726         * backtrace.h: Mechanically replace "can not" with "cannot".
728 2019-01-01  Jakub Jelinek  <jakub@redhat.com>
730         Update copyright years.
732 2018-12-29  Gerald Pfeifer  <gerald@pfeifer.com>
734         * Makefile.am (xcoff_%.c): Use an actual newline instead of \n
735         in sed pattern.
736         * Makefile.in: Regenerate.
738 2018-12-28  Tom de Vries  <tdevries@suse.de>
740         * dwarf.c (build_address_map): Reuse unused units.
742 2018-12-28  Tom de Vries  <tdevries@suse.de>
744         * dwarf.c (build_address_map): Simplify by removing local variable
745         abbrevs.
747 2018-12-28  Ian Lance Taylor  <iant@golang.org>
748             Tom de Vries  <tdevries@suse.de>
750         PR libbacktrace/88063
751         * dwarf.c (free_unit_addrs_vector): Remove.
752         (build_address_map): Keep track of allocated units in vector.  Free
753         allocated units and corresponding abbrevs upon failure.  Remove now
754         redundant call to free_unit_addrs_vector.  Free addrs vector upon
755         failure.  Free allocated unit vector.
757 2018-12-28  Tom de Vries  <tdevries@suse.de>
759         * dwarf.c (build_address_map): Free addrs vector upon failure.
761 2018-12-14  Tom de Vries  <tdevries@suse.de>
763         PR testsuite/88491
764         * allocfail.sh: Remove "set -o pipefail".
766 2018-12-12  Tom de Vries  <tdevries@suse.de>
768         * Makefile.am (TESTS): Add allocfail.sh.
769         (check_PROGRAMS): Add allocfail.
770         * Makefile.in: Regenerate.
771         * instrumented_alloc.c: New file.  Redefine malloc and realloc.
772         Include alloc.c.
773         * allocfail.c: New file.
774         * allocfail.sh: New file.
776 2018-11-30  Tom de Vries  <tdevries@suse.de>
778         * Makefile.am (check_PROGRAMS): Add test_elf, test_xcoff_32,
779         test_xcoff_64, test_pecoff and test_unknown.
780         * Makefile.in: Regenerate.
781         * test_format.c: New file.
783 2018-11-30  Tom de Vries  <tdevries@suse.de>
785         * Makefile.am : Add _with_alloc version for each test in
786         check_PROGRAMS.
787         * Makefile.in: Regenerate.
789 2018-11-30  Tom de Vries  <tdevries@suse.de>
791         * internal.h (backtrace_vector_free): New static inline fuction,
792         factored out of ...
793         * dwarf.c (read_line_info): ... here.
795 2018-11-28  Tom de Vries  <tdevries@suse.de>
797         * dwarf.c (read_abbrevs): Fix handling of abbrevs->abbrevs allocation
798         failure.
800 2018-11-27  Tom de Vries  <tdevries@suse.de>
802         * mmap.c (backtrace_vector_release): Same.
803         * unittest.c (test1): Add check.
805 2018-11-27  Tom de Vries  <tdevries@suse.de>
807         * alloc.c (backtrace_vector_release): Handle vec->size == 0 using free
808         instead of realloc.
809         * Makefile.am (check_PROGRAMS): Add unittest.
810         * Makefile.in: Regenerate.
811         * unittest.c: New file.
813 2018-11-22  Tom de Vries  <tdevries@suse.de>
815         * dwarf.c (read_initial_length): Factor out of ...
816         (build_address_map, read_line_info): ... here.
818 2018-11-21  Tom de Vries  <tdevries@suse.de>
820         * dwarf.c (read_string): Factor out of ...
821         (read_attribute, read_line_header, read_line_program): ... here.
823 2018-10-31  Joseph Myers  <joseph@codesourcery.com>
825         PR bootstrap/82856
826         * Makefile.am: Include multilib.am.
827         * configure.ac: Remove AC_PREREQ.  Use AC_LANG_SOURCE.
828         * Makefile.in, aclocal.m4, config.h.in, configure: Regenerate.
830 2018-10-05  Ian Lance Taylor  <iant@golang.org>
832         PR libbacktrace/87529
833         * backtrace.h: Document that backtrace_create_state should be
834         called only once.
836 2018-08-05 Iain Buclaw  <ibuclaw@gdcproject.org>
838         * configure.ac: Move define of HAVE_ZLIB into check for -lz.
839         * Makefile.in: Regenerate.
840         * config.h.in: Likewise.
841         * configure: Likewise.
843 2018-08-01  Tony Reix  <tony.reix@atos.net>
845         * xcoff.c (struct xcoff_line, struct xcoff_line_vector): Remove.
846         (struct xcoff_func, struct xcoff_func_vector): New structs.
847         (xcoff_syminfo): Drop leading dot from symbol name.
848         (xcoff_line_compare, xcoff_line_search): Remove.
849         (xcoff_func_compare, xcoff_func_search): New static functions.
850         (xcoff_lookup_pc): Search function table.
851         (xcoff_add_line, xcoff_process_linenos): Remove.
852         (xcoff_initialize_fileline): Build function table.
854 2018-06-21 Denis Khalikov <d.khalikov@partner.samsung.com>
856         PR other/86198
857         * elf.c (elf_add): Increase ".note.gnu.build-id" section size
858         checking up to 36 bytes.
860 2018-04-24  H.J. Lu  <hongjiu.lu@intel.com>
862         * configure: Regenerated.
864 2018-04-19  Jakub Jelinek  <jakub@redhat.com>
866         * configure: Regenerated.
868 2018-04-17  Ian Lance Taylor  <iant@golang.org>
870         * backtrace.c: Revert last two changes.  Don't call mmap
871         directly.
873 2018-04-17  Ian Lance Taylor  <iant@golang.org>
875         * backtrace.c: Include backtrace-supported.h before checking
876         BACKTRACE_USES_MALLOC.
878 2018-04-17  Ian Lance Taylor  <iant@golang.org>
880         * backtrace.c (backtrace_full): When testing whether we can
881         allocate memory, call mmap directly, and munmap the memory.
883 2018-04-04  Jakub Jelinek  <jakub@redhat.com>
885         PR other/85161
886         * elf.c (elf_zlib_fetch): Fix up predefined macro names in test for
887         big endian, only use 32-bit loads if endianity macros are predefined
888         and indicate big or little endian.
890 2018-02-14  Igor Tsimbalist  <igor.v.tsimbalist@intel.com>
892         PR target/84148
893         * configure: Regenerate.
895 2018-02-15  Jakub Jelinek  <jakub@redhat.com>
897         PR other/82368
898         * elf.c (SHT_PROGBITS): Undefine and define.
900 2018-02-14  Jakub Jelinek  <jakub@redhat.com>
902         PR other/82368
903         * elf.c (EM_PPC64, EF_PPC64_ABI): Undefine and define.
904         (struct elf_ppc64_opd_data): New type.
905         (elf_initialize_syminfo): Add opd argument, handle symbols
906         pointing into the PowerPC64 ELFv1 .opd section.
907         (elf_add): Read .opd section on PowerPC64 ELFv1, pass pointer
908         to structure with .opd data to elf_initialize_syminfo.
910 2018-01-31  Ian Lance Taylor  <iant@golang.org>
912         * elf.c (elf_add): Close descriptor if we use a debugfile.
913         * btest.c (check_open_files): New static function.
914         (main): Call check_open_files.
916 2018-01-25  Ian Lance Taylor  <iant@golang.org>
918         * elf.c (elf_open_debugfile_by_debuglink): Don't check CRC if the
919         desired CRC is zero.
920         (elf_add): Don't clear *found_sym and *found_dwarf if debuginfo.
922 2018-01-25  Ian Lance Taylor  <iant@golang.org>
924         * pecoff.c (coff_add): Only release syms_view if it is valid.
926 2018-01-25  Ian Lance Taylor  <iant@golang.org>
928         * pecoff.c (coff_add): Another memcpy -> coff_read4 fix.
930 2018-01-24  Ian Lance Taylor  <iant@golang.org>
932         * pecoff.c (coff_add): Use coff_read4, not memcpy.
934 2018-01-24  Ian Lance Taylor  <iant@golang.org>
936         PR other/68239
937         * mmap.c (backtrace_free_locked): Don't put more than 16 entries
938         on the free list.
940 2018-01-19  Tony Reix  <tony.reix@atos.net>
942         * xcoff.c (xcoff_incl_compare): New function.
943         (xcoff_incl_search): New function.
944         (xcoff_process_linenos): Use bsearch to find include file.
945         (xcoff_initialize_fileline): Sort include file information.
947 2018-01-16  Ian Lance Taylor  <iant@golang.org>
949         * elf.c (codes) [GENERATE_FIXED_HUFFMAN_TABLE]: Fix size to be
950         288.
951         (main) [GENERATE_FIXED_HUFFMAN_TABLE]: Pass 288 to
952         elf_zlib_inflate_table.  Generate elf_zlib_default_dist_table.
953         (elf_zlib_default_table): Update.
954         (elf_zlib_default_dist_table): New static array.
955         (elf_zlib_inflate): Use elf_zlib_default_dist_table for dist table
956         for block type 1.
957         * ztest.c (struct zlib_test): Add uncompressed_len.
958         (tests): Initialize uncompressed_len field.  Add new test case.
959         (test_samples): Use uncompressed_len field.
961 2018-01-03  Jakub Jelinek  <jakub@redhat.com>
963         Update copyright years.
965 2017-11-17  Igor Tsimbalist  <igor.v.tsimbalist@intel.com>
967         * configure.ac: Add CET_FLAGS to EXTRA_FLAGS.
968         * aclocal.m4: Regenerate.
969         * Makefile.in: Likewise.
970         * configure: Likewise.
972 2017-10-06  Ian Lance Taylor  <iant@golang.org>
974         * ztest.c (test_large): Pass unsigned long *, not size_t *, to
975         zlib uncompress function.
977 2017-10-05  Ian Lance Taylor  <iant@golang.org>
979         * elf.c (elf_zlib_fetch): Change pval argument to uint64_t *.
980         Read a four byte integer.
981         (elf_zlib_inflate): Change val to uint64_t.  Align pin to a 32-bit
982         boundary before ever calling elf_zlib_fetch.
983         * ztest.c (test_large): Simplify print statements a bit.
985 2017-10-02  Ian Lance Taylor  <iant@golang.org>
987         * ztest.c: #include <errno.h>.
988         (TEST_TIMING): Don't define, don't test.
989         (xclock_gettime, xclockid_t): Define if !HAVE_CLOCK_GETTIME.
990         (clockid_t, clock_gettime, CLOCK_REALTIME): Likewise.
991         (ZLIB_CLOCK_GETTIME_ARG): Define.
992         * configure.ac: Change clock_gettime_link to CLOCK_GETTIME_LINK.
993         * Makefile.am: Likewise.
994         * configure, Makefile.in: Rebuild.
996 2017-10-02  Thomas Schwinge  <thomas@codesourcery.com>
998         PR other/67165
999         * Makefile.am: Append the content of clock_gettime_link to
1000         ztest_LDADD.
1001         * configure.ac: Test for the case that clock_gettime is in librt.
1002         * Makefile.in: Regenerate.
1003         * configure: Likewise.
1005         PR other/67165
1006         * configure.ac: Check for clock_gettime.
1007         * config.h.in: Regenerate.
1008         * configure: Likewise.
1009         * ztest.c (average_time, test_large): Conditionalize test timing
1010         on clock_gettime availability.
1012 2017-09-29  Tony Reix  <tony.reix@atos.net>
1014         * xcoff.c: Initial support for DWARF debug sections in XCOFF.
1015         (STYP_DWARF, SSUBTYP_DW*): Define.
1016         (enum dwarf_section): Define.
1017         (struct dwsect_info): Define.
1018         (xcoff_add): Look for DWARF sections, pass them to
1019         backtrace_dwarf_add.
1021 2017-09-28  Ian Lance Taylor  <iant@golang.org>
1023         PR other/67165
1024         * elf.c (__builtin_prefetch): Define if not __GNUC__.
1025         (unlikely): Define.
1026         (SHF_UNCOMPRESSED, ELFCOMPRESS_ZLIB): Define.
1027         (b_elf_chdr): Define type.
1028         (enum debug_section): Add ZDEBUG_xxx values.
1029         (debug_section_names): Add names for new sections.
1030         (struct debug_section_info): Add compressed field.
1031         (elf_zlib_failed, elf_zlib_fetch): New static functions.
1032         (HUFFMAN_TABLE_SIZE, HUFFMAN_VALUE_MASK): Define.
1033         (HUFFMAN_BITS_SHIFT, HUFFMAN_BITS_MASK): Define.
1034         (HUFFMAN_SECONDARY_SHIFT): Define.
1035         (ZDEBUG_TABLE_SIZE): Define.
1036         (ZDEBUG_TABLE_CODELEN_OFFSET, ZDEBUG_TABLE_WORK_OFFSET): Define.
1037         (final_next_secondary): New static variable if
1038         BACKTRACE_GENERATE_FIXED_HUFFMAN_TABLE.
1039         (elf_zlib_inflate_table): New static function.
1040         (BACKTRACE_GENERATE_FIXED_HUFFMAN_TABLE): If define, define main
1041         function to produce fixed Huffman table.
1042         (elf_zlib_default_table): New static variable.
1043         (elf_zlib_inflate): New static function.
1044         (elf_zlib_verify_checksum): Likewise.
1045         (elf_zlib_inflate_and_verify): Likewise.
1046         (elf_uncompress_zdebug): Likewise.
1047         (elf_uncompress_chdr): Likewise.
1048         (backtrace_uncompress_zdebug): New extern function.
1049         (elf_add): Look for .zdebug sections and SHF_COMPRESSED debug
1050         sections, and uncompress them.
1051         * internal.h (backtrace_compress_zdebug): Declare.
1052         * ztest.c: New file.
1053         * configure.ac: Check for -lz and check whether the linker
1054         supports --compress-debug-sections.
1055         * Makefile.am (ztest_SOURCES): New variable.
1056         (ztest_CFLAGS, ztest_LDADD): New variables.
1057         (check_PROGRAMS): Add ztest.
1058         (ctestg_SOURCES): New variable.
1059         (ctestg_CFLAGS, ctestg_LDFLAGS, ctestg_LDADD): New variables.
1060         (ctesta_SOURCES): New variable.
1061         (ctesta_CFLAGS, ctesta_LDFLAGS, ctesta_LDADD): New variables.
1062         (check_PROGRAMS): Add ctestg and ctesta.
1063         * configure, config.h.in, Makefile.in: Rebuild.
1065 2017-09-22  Ian Lance Taylor  <iant@golang.org>
1067         PR sanitizer/77631
1068         * configure.ac: Check for lstat and readlink.
1069         * elf.c (lstat, readlink): Provide dummy versions if real versions
1070         are not available.
1071         * configure, config.h.in: Rebuild.
1073 2017-09-21  Ian Lance Taylor  <iant@google.com>
1075         PR go/82284
1076         * elf.c (backtrace_initialize): Set pd.exe_filename.
1078 2017-09-20  Ian Lance Taylor  <iant@golang.org>
1079             Denis Khalikov  <d.khalikov@partner.samsung.com>
1081         PR sanitizer/77631
1082         Support for external debug info.
1083         * elf.c: Include <errno.h>, <sys/stat.h>, <unistd.h>.
1084         (S_ISLNK): Define if not defined.
1085         (xstrnlen): Define if strnlen is not available.
1086         (b_elf_note): Define type.
1087         (NT_GNU_BUILD_ID): Define macro.
1088         (elf_crc32, elf_crc32_file): New static functions.
1089         (elf_is_symlink, elf_readlink): New static functions.
1090         (elf_open_debugfile_by_buildid): New static function.
1091         (elf_try_debugfile): New static function.
1092         (elf_find_debugfile_by_debuglink): New static function.
1093         (elf_open_debugfile_by_debuglink): New static function.
1094         (elf_add): Add filename and debuginfo parameters.  Adjust all
1095         callers.  Look for external debug info notes, and try to fetch
1096         debug info from external file.
1097         (struct phdr_data): Add exe_filename field.
1098         (phdr_callback): Pass filename to elf_add.
1099         (backtrace_initialize): Add filename parameter.
1100         * internal.h (backtrace_initialize): Add filename parameter.
1101         * fileline.c (fileline_initialize): Pass filename to
1102         backtrace_initialize.
1103         * pecoff.c (fileline_initialize): Add unused filename parameter.
1104         * unknown.c (fileline_initialize): Likewise.
1105         * xcoff.c (fileline_initialize): Likewise.
1106         * configure.ac: Check for objcopy --add-gnu-debuglink.
1107         * Makefile.am (dtest): New test target.
1108         * configure, Makefile.in: Rebuild.
1110 2017-09-12  Steve Ellcey  <sellcey@cavium.com>
1112         PR other/81096
1113         * Makefile.am (ttest_CFLAGS): Add $(AM_CFLAGS)
1114         * Makefile.in: Regenerate.
1116 2017-09-12  Steve Ellcey  <sellcey@cavium.com>
1118         PR other/81096
1119         * libbacktrace/Makefile.in
1120         (HAVE_PTHREAD_TRUE@@NATIVE_TRUE@ttest_CFLAGS): Add $(AM_CFLAGS)
1122 2017-08-02  David Edelsohn  <dje.gcc@gmail.com>
1124         PR bootstrap/81638
1125         * xcoff.c (xcoff_process_linenos): Initialize incl to NULL.
1127 2017-07-28  Tony Reix  <tony.reix@atos.net>
1129         * xcoff.c: Don't leak a file descriptor if an archive is malformed.
1131 2017-07-28  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
1133         * fileline.c (fileline_initialize): Print pid_t as long.
1135 2017-07-26  Tony Reix  <tony.reix@atos.net>
1137         * configure.ac: Check for XCOFF32/XCOFF64.  Check for loadquery.
1138         * filetype.awk: Separate AIX XCOFF32 and XCOFF64.
1139         * xcoff.c: Add support for AIX XCOFF32 and XCOFF64 formats.
1140         * configure, config.h.in: Regenerate.
1142 2017-07-21  Tony Reix  <tony.reix@atos.net>
1144         * filetype.awk: Add AIX XCOFF type detection.
1145         * configure.ac: Recognize xcoff format.
1146         * Makefile.am (FORMAT_FILES): Add xcoff.c.
1147         * fileline.c: Include <unistd.h>.
1148         (fileline_initialize): Add case for AIX procfs.
1149         * xcoff.c: New file.
1150         * configure, Makefile.in: Rebuild.
1152 2017-06-21  Richard Biener  <rguenther@suse.de>
1154         * configure.ac: Add AC_SYS_LARGEFILE.
1155         * config.h.in: Regenerate.
1156         * configure: Likewise.
1158 2017-06-11  Ian Lance Taylor  <iant@golang.org>
1160         * elf.c (backtrace_initialize): Always set *fileline_fn.
1161         * ttest.c: New file.
1162         * btest.c: Move support functions into testlib.c.  Change calls to
1163         check to pass file name.
1164         * testlib.c: New file, copied from (part of) btest.c.
1165         * testlib.h: New file, declarations for testlib.c.
1166         * edtest.c: Use testlib.h and testlib.c.
1167         * configure.ac: Test for -pthread, set HAVE_PTHREAD conditional.
1168         * Makefile.am (btest_SOURCES): Add testlib.c.
1169         (edtest_SOURCES): Likewise.
1170         (CHECK_PROGRAMS): Add ttest if HAVE_PTHREAD.
1171         (ttest_SOURCES, ttest_CFLAGS, ttest_LDADD): Define.
1172         * configure, Makefile.in: Rebuild.
1174 2017-05-19  Than McIntosh  <thanm@google.com>
1176         * dwarf.c (free_line_header): Don't free dirs if dirs_count == 0.
1177         (read_line_header): Don't allocate dirs if dirs_count == 0.
1178         * edtest.c: New file.
1179         * edtest2.c: New file.
1180         * Makefile.am (edtest_SOURCES, edtest_LDADD): Define.
1181         (check_PROGRAMS): Add edtest.
1182         (edtest2_build.c, gen_edtest2_build): New targets.
1183         * Makefile.in: Rebuild.
1185 2017-03-08  Sam Thursfield  <sam.thursfield@codethink.co.uk>
1187         * btest.c (test5): Replace #ifdef guard with 'unused' attribute
1188         to fix compile warning when BACKTRACE_SUPPORTED isn't defined.
1190 2017-01-01  Jakub Jelinek  <jakub@redhat.com>
1192         Update copyright years.
1194 2016-11-15  Matthias Klose  <doko@ubuntu.com>
1196         * configure: Regenerate.
1198 2016-09-11  Carlos Liam  <carlos@aarzee.me>
1200         * all: Remove meaningless trailing whitespace.
1202 2016-05-18  Uros Bizjak  <ubizjak@gmail.com>
1204         PR target/71161
1205         * elf.c (phdr_callback) [__i386__]: Add
1206         __attribute__((__force_align_arg_pointer__)).
1208 2016-03-02  Maxim Ostapenko  <m.ostapenko@partner.samsung.com>
1210         * elf.c (backtrace_initialize): Properly initialize elf_fileline_fn to
1211         avoid possible crash.
1212         (elf_add): Don't set *fileline_fn to elf_nodebug value in case of
1213         missing debug info anymore.
1215 2016-02-06  John David Anglin  <danglin@gcc.gnu.org>
1217         * mmap.c (MAP_FAILED): Define if not defined.
1219 2016-01-04  Jakub Jelinek  <jakub@redhat.com>
1221         Update copyright years.
1223 2015-12-18  Andris Pavenis  <andris.pavenis@iki.fi>
1225         * configure.ac: Specify that DJGPP do not have mmap
1226         even when sys/mman.h exists.
1227         * configure: Regenerate
1229 2015-12-09  John David Anglin  <danglin@gcc.gnu.org>
1231         PR libgfortran/68115
1232         * configure.ac: Set libbacktrace_cv_sys_sync to no on hppa*-*-hpux*.
1233         * configure: Regenerate.
1234         * elf.c (backtrace_initialize): Cast __sync_bool_compare_and_swap call
1235         to void.
1237 2015-09-17  Ian Lance Taylor  <iant@google.com>
1239         * posix.c (backtrace_open): Cast second argument of open() to int.
1241 2015-09-11  Ian Lance Taylor  <iant@google.com>
1243         * Makefile.am (backtrace.lo): Depend on internal.h.
1244         (sort.lo, stest.lo): Add explicit dependencies.
1245         * Makefile.in: Rebuild.
1247 2015-09-09  Hans-Peter Nilsson  <hp@axis.com>
1249         * backtrace.c: #include <sys/types.h>.
1251 2015-09-08  Ian Lance Taylor  <iant@google.com>
1253         PR other/67457
1254         * backtrace.c: #include "internal.h".
1255         (struct backtrace_data): Add can_alloc field.
1256         (unwind): If can_alloc is false, don't try to get file/line
1257         information.
1258         (backtrace_full): Set can_alloc field in bdata.
1259         * alloc.c (backtrace_alloc): Don't call error_callback if it is
1260         NULL.
1261         * mmap.c (backtrace_alloc): Likewise.
1262         * internal.h: Update comments for backtrace_alloc and
1263         backtrace_free.
1265 2015-09-08  Ian Lance Taylor  <iant@google.com>
1267         PR other/67457
1268         * mmap.c (backtrace_alloc): Correct test for mmap failure.
1270 2015-08-31  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
1272         * configure.ac: For spu-*-* targets, set have_fcntl to no.
1273         * configure: Regenerate.
1275 2015-08-27  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
1277         * configure.ac: Remove [disable-shared] argument to LT_INIT.
1278         Remove setting PIC_FLAG when building as target library.
1279         * configure: Regenerate.
1281 2015-08-26  Hans-Peter Nilsson  <hp@axis.com>
1283         * configure.ac: Only compile with -fPIC if the target
1284         supports it.
1285         * configure: Regenerate.
1287 2015-08-24  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
1289         * configure.ac: Set have_mmap to no on spu-*-* targets.
1290         * configure: Regenerate.
1292 2015-08-13  Ian Lance Taylor  <iant@google.com>
1294         * dwarf.c (read_function_entry): Add vec_inlined parameter.
1295         Change all callers.
1297 2015-06-11  Martin Sebor  <msebor@redhat.com>
1299         PR sanitizer/65479
1300         * dwarf.c (struct line): Add new field idx.
1301         (line_compare): Use it.
1302         (add_line): Set it.
1303         (read_line_info): Reset it.
1305 2015-05-29  Tristan Gingold  <gingold@adacore.com>
1307         * pecoff.c: New file.
1308         * Makefile.am (FORMAT_FILES): Add pecoff.c and dependencies.
1309         * Makefile.in: Regenerate.
1310         * filetype.awk: Detect pecoff.
1311         * configure.ac: Define BACKTRACE_SUPPORTS_DATA on elf platforms.
1312         Add pecoff.
1313         * btest.c (test5): Test enabled only if BACKTRACE_SUPPORTS_DATA is
1314         true.
1315         * backtrace-supported.h.in (BACKTRACE_SUPPORTS_DATA): Define.
1316         * configure: Regenerate.
1317         * pecoff.c: New file.
1319 2015-05-13  Michael Haubenwallner  <michael.haubenwallner@ssi-schaefer.com>
1321         * Makefile.in: Regenerated with automake-1.11.6.
1322         * aclocal.m4: Likewise.
1323         * configure: Likewise.
1325 2015-01-24  Matthias Klose  <doko@ubuntu.com>
1327         * configure.ac: Move AM_ENABLE_MULTILIB before AC_PROG_CC.
1328         * configure: Regenerate.
1330 2015-01-05  Jakub Jelinek  <jakub@redhat.com>
1332         Update copyright years.
1334 2014-11-21  H.J. Lu  <hongjiu.lu@intel.com>
1336         PR bootstrap/63784
1337         * configure: Regenerated.
1339 2014-11-11  David Malcolm  <dmalcolm@redhat.com>
1341         * ChangeLog.jit: New.
1343 2014-11-11  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
1345         PR target/63610
1346         * configure: Regenerate.
1348 2014-10-23  Ian Lance Taylor  <iant@google.com>
1350         * internal.h (backtrace_atomic_load_pointer) [no atomic or sync]:
1351         Fix to return void *.
1353 2014-05-08  Ian Lance Taylor  <iant@google.com>
1355         * mmap.c (backtrace_free): If freeing a large aligned block of
1356         memory, call munmap rather than holding onto it.
1357         (backtrace_vector_grow): When growing a vector, double the number
1358         of pages requested.  When releasing the old version of a grown
1359         vector, pass the correct size to backtrace_free.
1361 2014-03-07  Ian Lance Taylor  <iant@google.com>
1363         * sort.c (backtrace_qsort): Use middle element as pivot.
1365 2014-03-06  Ian Lance Taylor  <iant@google.com>
1367         * sort.c: New file.
1368         * stest.c: New file.
1369         * internal.h (backtrace_qsort): Declare.
1370         * dwarf.c (read_abbrevs): Call backtrace_qsort instead of qsort.
1371         (read_line_info, read_function_entry): Likewise.
1372         (read_function_info, build_dwarf_data): Likewise.
1373         * elf.c (elf_initialize_syminfo): Likewise.
1374         * Makefile.am (libbacktrace_la_SOURCES): Add sort.c.
1375         (stest_SOURCES, stest_LDADD): Define.
1376         (check_PROGRAMS): Add stest.
1378 2014-02-07  Misty De Meo  <misty@brew.sh>
1380         PR target/58710
1381         * configure.ac: Use AC_LINK_IFELSE in check for
1382         _Unwind_GetIPInfo.
1383         * configure: Regenerate.
1385 2014-01-02  Richard Sandiford  <rdsandiford@googlemail.com>
1387         Update copyright years
1389 2013-12-06  Jakub Jelinek  <jakub@redhat.com>
1391         * elf.c (ET_DYN): Undefine and define again.
1392         (elf_add): Add exe argument, if true and ehdr.e_type is ET_DYN,
1393         return early -1 without closing the descriptor.
1394         (struct phdr_data): Add exe_descriptor.
1395         (phdr_callback): If pd->exe_descriptor is not -1, for very first
1396         call if dlpi_name is NULL just call elf_add with the exe_descriptor,
1397         otherwise backtrace_close the exe_descriptor if not -1.  Adjust
1398         call to elf_add.
1399         (backtrace_initialize): Adjust call to elf_add.  If it returns
1400         -1, set pd.exe_descriptor to descriptor, otherwise set it to -1.
1402 2013-12-05  Ian Lance Taylor  <iant@google.com>
1404         * alloc.c (backtrace_vector_finish): Add error_callback and data
1405         parameters.  Call backtrace_vector_release.  Return address base.
1406         * mmap.c (backtrace_vector_finish): Add error_callback and data
1407         parameters.  Return address base.
1408         * dwarf.c (read_function_info): Get new address base from
1409         backtrace_vector_finish.
1410         * internal.h (backtrace_vector_finish): Update declaration.
1412 2013-11-27  Ian Lance Taylor  <iant@google.com>
1414         * dwarf.c (find_address_ranges): New static function, broken out
1415         of build_address_map.
1416         (build_address_map): Call it.
1417         * btest.c (check): Check for missing filename or function, rather
1418         than crashing.
1419         (f3): Check that enough frames were returned.
1421 2013-11-19  Jakub Jelinek  <jakub@redhat.com>
1423         * backtrace.h (backtrace_syminfo_callback): Add symsize argument.
1424         * elf.c (elf_syminfo): Pass 0 or sym->size to the callback as
1425         last argument.
1426         * btest.c (struct symdata): Add size field.
1427         (callback_three): Add symsize argument.  Copy it to the data->size
1428         field.
1429         (f23): Set symdata.size to 0.
1430         (test5): Likewise.  If sizeof (int) > 1, lookup address of
1431         ((uintptr_t) &global) + 1.  Verify symdata.val and symdata.size
1432         values.
1434         * atomic.c: Include sys/types.h.
1436 2013-11-18  Ian Lance Taylor  <iant@google.com>
1438         * configure.ac: Check for support of __atomic extensions.
1439         * internal.h: Declare or #define atomic functions for use in
1440         backtrace code.
1441         * atomic.c: New file.
1442         * dwarf.c (dwarf_lookup_pc): Use atomic functions.
1443         (dwarf_fileline, backtrace_dwarf_add): Likewise.
1444         * elf.c (elf_add_syminfo_data, elf_syminfo): Likewise.
1445         (backtrace_initialize): Likewise.
1446         * fileline.c (fileline_initialize): Likewise.
1447         * Makefile.am (libbacktrace_la_SOURCES): Add atomic.c.
1448         * configure, config.h.in, Makefile.in: Rebuild.
1450 2013-11-18  Jakub Jelinek  <jakub@redhat.com>
1452         * elf.c (SHN_UNDEF): Define.
1453         (elf_initialize_syminfo): Add base_address argument.  Ignore symbols
1454         with st_shndx == SHN_UNDEF.  Add base_address to address fields.
1455         (elf_add): Adjust caller.
1457         * elf.c (phdr_callback): Process info->dlpi_addr == 0 normally.
1459 2013-11-16  Ian Lance Taylor  <iant@google.com>
1461         * backtrace.h (backtrace_create_state): Correct comment about
1462         threading.
1464 2013-11-15  Ian Lance Taylor  <iant@google.com>
1466         * backtrace.h (backtrace_syminfo): Update comment and parameter
1467         name to take any address, not just a PC value.
1468         * elf.c (STT_OBJECT): Define.
1469         (elf_nosyms): Rename parameter pc to addr.
1470         (elf_symbol_search): Rename local variable pc to addr.
1471         (elf_initialize_syminfo): Add STT_OBJECT symbols to elf_symbols.
1472         (elf_syminfo): Rename parameter pc to addr.
1473         * btest.c (global): New global variable.
1474         (test5): New test.
1475         (main): Call test5.
1477 2013-10-17  Ian Lance Taylor  <iant@google.com>
1479         * elf.c (elf_add): Don't get the wrong offsets if a debug section
1480         is missing.
1482 2013-10-15  David Malcolm  <dmalcolm@redhat.com>
1484         * configure.ac: Add --enable-host-shared, setting up
1485         pre-existing PIC_FLAG variable within Makefile.am et al.
1486         * configure: Regenerate.
1488 2013-09-20  Alan Modra  <amodra@gmail.com>
1490         * configure: Regenerate.
1492 2013-07-23  Alexander Monakov  <amonakov@ispras.ru>
1494         * elf.c (elf_syminfo): Loop over the elf_syminfo_data chain.
1496 2013-07-23  Alexander Monakov  <amonakov@ispras.ru>
1498         * elf.c (backtrace_initialize): Pass elf_fileline_fn to
1499         dl_iterate_phdr callbacks.
1501 2013-03-25  Ian Lance Taylor  <iant@google.com>
1503         * alloc.c: #include <sys/types.h>.
1504         * mmap.c: Likewise.
1506 2013-01-31  Ian Lance Taylor  <iant@google.com>
1508         * dwarf.c (read_function_info): Permit fvec parameter to be NULL.
1509         (dwarf_lookup_pc): Don't use ddata->fvec if threaded.
1511 2013-01-25  Jakub Jelinek  <jakub@redhat.com>
1513         PR other/56076
1514         * dwarf.c (read_line_header): Don't crash if DW_AT_comp_dir
1515         attribute was not seen.
1517 2013-01-16  Ian Lance Taylor  <iant@google.com>
1519         * dwarf.c (struct unit): Add filename and abs_filename fields.
1520         (build_address_map): Set new fields when reading unit.
1521         (dwarf_lookup_pc): If we don't find an entry in the line table,
1522         just return the main file name.
1524 2013-01-14  Richard Sandiford  <rdsandiford@googlemail.com>
1526         Update copyright years.
1528 2013-01-01  Ian Lance Taylor  <iant@google.com>
1530         PR bootstrap/54834
1531         * Makefile.am (AM_CPPFLAGS): Remove -I ../gcc/include and -I
1532         $(MULTIBUILDTOP)/../../gcc/include.
1533         * Makefile.in: Rebuild.
1535 2013-01-01  Ian Lance Taylor  <iant@google.com>
1537         PR other/55536
1538         * mmap.c (backtrace_alloc): Don't call sync functions if not
1539         threaded.
1540         (backtrace_free): Likewise.
1542 2012-12-12  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
1544         * mmapio.c: Define MAP_FAILED if not defined.
1546 2012-12-11  Jakub Jelinek  <jakub@redhat.com>
1548         PR bootstrap/54926
1549         * Makefile.am (AM_CFLAGS): Remove -frandom-seed=$@.
1550         * configure.ac: If --with-target-subdir, add -frandom-seed=$@
1551         to EXTRA_FLAGS unconditionally, otherwise check whether the compiler
1552         accepts it.
1553         * Makefile.in: Regenerated.
1554         * configure: Regenerated.
1556 2012-12-07  Jakub Jelinek  <jakub@redhat.com>
1558         PR bootstrap/54926
1559         * Makefile.am (AM_CFLAGS): Add -frandom-seed=$@.
1560         * Makefile.in: Regenerated.
1562 2012-11-20  Ian Lance Taylor  <iant@google.com>
1564         * dwarf.c (read_attribute): Always clear val.
1566 2012-11-13  Ian Lance Taylor  <iant@google.com>
1568         PR other/55312
1569         * configure.ac: Only add -Werror if building a target library.
1570         * configure: Rebuild.
1572 2012-11-12  Ian Lance Taylor  <iant@google.com>
1573             Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
1574             Gerald Pfeifer  <gerald@pfeifer.com>
1576         * configure.ac: Check for getexecname.
1577         * fileline.c: #include <errno.h>.  Define getexecname if not
1578         available.
1579         (fileline_initialize): Try to find the executable in a few
1580         different ways.
1581         * print.c (error_callback): Only print the filename if it came
1582         from the backtrace state.
1583         * configure, config.h.in: Rebuild.
1585 2012-10-29  Ian Lance Taylor  <iant@google.com>
1587         * mmap.c (backtrace_vector_release): Correct last patch: add
1588         aligned, not size.
1590 2012-10-29  Ian Lance Taylor  <iant@google.com>
1592         * mmap.c (backtrace_vector_release): Make sure freed block is
1593         aligned on 8-byte boundary.
1595 2012-10-26  Ian Lance Taylor  <iant@google.com>
1597         PR other/55087
1598         * posix.c (backtrace_open): Add does_not_exist parameter.
1599         * elf.c (phdr_callback): Do not warn if shared library could not
1600         be opened.
1601         * fileline.c (fileline_initialize): Update calls to
1602         backtrace_open.
1603         * internal.h (backtrace_open): Update declaration.
1605 2012-10-26  Jack Howarth  <howarth@bromo.med.uc.edu>
1607         PR target/55061
1608         * configure.ac: Check for _Unwind_GetIPInfo function declaration.
1609         * configure: Regenerate.
1611 2012-10-24  Ian Lance Taylor  <iant@google.com>
1613         PR target/55061
1614         * configure.ac: Check whether -funwind-tables option works.
1615         * configure: Rebuild.
1617 2012-10-11  Ian Lance Taylor  <iant@google.com>
1619         * configure.ac: Do not use dl_iterate_phdr on Solaris 10.
1620         * configure: Rebuild.
1622 2012-10-10  Ian Lance Taylor  <iant@google.com>
1624         * elf.c: Rename all Elf typedefs to start with b_elf, and be all
1625         lower case.
1627 2012-10-10  Hans-Peter Nilsson  <hp@bitrange.com>
1629         * elf.c (elf_add_syminfo_data): Add casts to avoid warning.
1631 2012-10-09  Ian Lance Taylor  <iant@google.com>
1633         * dwarf.c (dwarf_fileline): Add cast to avoid warning.
1634         (backtrace_dwarf_add): Likewise.
1636 2012-10-09  Ian Lance Taylor  <iant@google.com>
1638         Add support for tracing through shared libraries.
1639         * configure.ac: Check for link.h and dl_iterate_phdr.
1640         * elf.c: #include <link.h> if system has dl_iterate_phdr.  #undef
1641         ELF macros before #defining them.
1642         (dl_phdr_info, dl_iterate_phdr): Define if system does not have
1643         dl_iterate_phdr.
1644         (struct elf_syminfo_data): Add next field.
1645         (elf_initialize_syminfo): Initialize next field.
1646         (elf_add_syminfo_data): New static function.
1647         (elf_add): New static function, broken out of
1648         backtrace_initialize.  Call backtrace_dwarf_add instead of
1649         backtrace_dwarf_initialize.
1650         (struct phdr_data): Define.
1651         (phdr_callback): New static function.
1652         (backtrace_initialize): Call elf_add.
1653         * dwarf.c (struct dwarf_data): Add next and base_address fields.
1654         (add_unit_addr): Add base_address parameter.  Change all callers.
1655         (add_unit_ranges, build_address_map): Likewise.
1656         (add_line): Add ddata parameter.  Change all callers.
1657         (read_line_program, add_function_range): Likewise.
1658         (dwarf_lookup_pc): New static function, broken out of
1659         dwarf_fileline.
1660         (dwarf_fileline): Call dwarf_lookup_pc.
1661         (build_dwarf_data): New static function.
1662         (backtrace_dwarf_add): New function.
1663         (backtrace_dwarf_initialize): Remove.
1664         * internal.h (backtrace_dwarf_initialize): Don't declare.
1665         (backtrace_dwarf_add): Declare.
1666         * configure, config.h.in: Rebuild.
1668 2012-10-04  Gerald Pfeifer  <gerald@pfeifer.com>
1670         * btest.c (f23): Avoid uninitialized variable warning.
1672 2012-10-04  Ian Lance Taylor  <iant@google.com>
1674         * dwarf.c: If the system header files do not declare strnlen,
1675         provide our own version.
1677 2012-10-03  Ian Lance Taylor  <iant@google.com>
1679         * dwarf.c (read_uleb128): Fix overflow test.
1680         (read_sleb128): Likewise.
1681         (build_address_map): Don't change unit_buf.start.
1683 2012-10-02  Uros Bizjak  <ubizjak@gmail.com>
1685         PR other/54761
1686         * configure.ac (EXTRA_FLAGS): New.
1687         * Makefile.am (AM_FLAGS): Add $(EXTRA_FLAGS).
1688         * configure, Makefile.in: Regenerate.
1690 2012-09-29  Ian Lance Taylor  <iant@google.com>
1692         PR other/54749
1693         * fileline.c (fileline_initialize): Pass errnum as -1 when
1694         reporting that we could not read executable information after a
1695         previous failure.
1697 2012-09-27  Ian Lance Taylor  <iant@google.com>
1699         PR bootstrap/54732
1700         * configure.ac: Add no-dependencies to AM_INIT_AUTOMAKE.
1701         * Makefile.am: Add dependencies for all objects.
1702         * configure, aclocal.m4, Makefile.in: Rebuild.
1704 2012-09-27  Ian Lance Taylor  <iant@google.com>
1706         PR other/54726
1707         * elf.c (backtrace_initialize): Set *fileln_fn, not
1708         state->fileln_fn.
1710 2012-09-19  Ian Lance Taylor  <iant@google.com>
1712         * configure.ac: Only use GCC_CHECK_UNWIND_GETIPINFO when compiled
1713         as a target library.
1714         * configure: Rebuild.
1716 2012-09-19  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
1717             Ian Lance Taylor  <iant@google.com>
1719         * configure.ac (GCC_HEADER_STDINT): Invoke.
1720         * backtrace.h: If we can't find <stdint.h>, use "gstdint.h".
1721         * btest.c: Don't include <stdint.h>.
1722         * dwarf.c: Likewise.
1723         * configure, aclocal.m4, Makefile.in, config.h.in: Rebuild.
1725 2012-09-18  Ian Lance Taylor  <iant@google.com>
1727         PR bootstrap/54623
1728         * Makefile.am (AM_CPPFLAGS): Define.
1729         (AM_CFLAGS): Remove -I options.
1730         * Makefile.in: Rebuild.
1732 2012-09-18  Ian Lance Taylor  <iant@google.com>
1734         * posix.c (O_BINARY): Define if not defined.
1735         (backtrace_open): Pass O_BINARY to open.  Only call fcntl if
1736         HAVE_FCNTL is defined.
1737         * configure.ac: Test for the fcntl function.
1738         * configure, config.h.in: Rebuild.
1740 2012-09-18  Ian Lance Taylor  <iant@google.com>
1742         * btest.c (test1, test2, test3, test4): Add the unused attribute.
1744 2012-09-18  Ian Lance Taylor  <iant@google.com>
1746         * dwarf.c: Correct test of HAVE_DECL_STRNLEN.
1748 2012-09-18  Ian Lance Taylor  <iant@google.com>
1750         * configure.ac: Add AC_USE_SYSTEM_EXTENSIONS.
1751         * mmapio.c: Don't define _GNU_SOURCE.
1752         * configure, config.h.in: Rebuild.
1754 2012-09-18  Ian Lance Taylor  <iant@google.com>
1756         * configure.ac: Check whether strnlen is declared.
1757         * dwarf.c: Declare strnlen if not declared.
1758         * configure, config.h.in: Rebuild.
1760 2012-09-18  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
1762         * fileline.c: Include <stdlib.h>.
1763         * mmap.c: Likewise.
1765 2012-09-17  Ian Lance Taylor  <iant@google.com>
1767         PR bootstrap/54611
1768         * nounwind.c (backtrace_full): Rename from backtrace.  Add state
1769         parameter.
1771 2012-09-17  Gerald Pfeifer  <gerald@pfeifer.com>
1773         PR bootstrap/54611
1774         * nounwind.c (backtrace_simple): Add state parameter.
1776 2012-09-17  Ian Lance Taylor  <iant@google.com>
1778         PR bootstrap/54609
1779         * unknown.c (unknown_fileline): Add state parameter, remove
1780         fileline_data parameter, name error_callback parameter.
1781         (backtrace_initialize): Add state parameter.
1783 2012-09-17  Ian Lance Taylor  <iant@google.com>
1785         * Initial implementation.
1787 Copyright (C) 2012-2021 Free Software Foundation, Inc.
1789 Copying and distribution of this file, with or without modification,
1790 are permitted in any medium without royalty provided the copyright
1791 notice and this notice are preserved.