PR c++/83897
[official-gcc.git] / libbacktrace / ChangeLog
blob955ff8d47abbaef0f865d9b8511f82e02f32bd97
1 2018-01-16  Ian Lance Taylor  <iant@golang.org>
3         * elf.c (codes) [GENERATE_FIXED_HUFFMAN_TABLE]: Fix size to be
4         288.
5         (main) [GENERATE_FIXED_HUFFMAN_TABLE]: Pass 288 to
6         elf_zlib_inflate_table.  Generate elf_zlib_default_dist_table.
7         (elf_zlib_default_table): Update.
8         (elf_zlib_default_dist_table): New static array.
9         (elf_zlib_inflate): Use elf_zlib_default_dist_table for dist table
10         for block type 1.
11         * ztest.c (struct zlib_test): Add uncompressed_len.
12         (tests): Initialize uncompressed_len field.  Add new test case.
13         (test_samples): Use uncompressed_len field.
15 2018-01-03  Jakub Jelinek  <jakub@redhat.com>
17         Update copyright years.
19 2017-11-17  Igor Tsimbalist  <igor.v.tsimbalist@intel.com>
21         * configure.ac: Add CET_FLAGS to EXTRA_FLAGS.
22         * aclocal.m4: Regenerate.
23         * Makefile.in: Likewise.
24         * configure: Likewise.
26 2017-10-06  Ian Lance Taylor  <iant@golang.org>
28         * ztest.c (test_large): Pass unsigned long *, not size_t *, to
29         zlib uncompress function.
31 2017-10-05  Ian Lance Taylor  <iant@golang.org>
33         * elf.c (elf_zlib_fetch): Change pval argument to uint64_t *.
34         Read a four byte integer.
35         (elf_zlib_inflate): Change val to uint64_t.  Align pin to a 32-bit
36         boundary before ever calling elf_zlib_fetch.
37         * ztest.c (test_large): Simplify print statements a bit.
39 2017-10-02  Ian Lance Taylor  <iant@golang.org>
41         * ztest.c: #include <errno.h>.
42         (TEST_TIMING): Don't define, don't test.
43         (xclock_gettime, xclockid_t): Define if !HAVE_CLOCK_GETTIME.
44         (clockid_t, clock_gettime, CLOCK_REALTIME): Likewise.
45         (ZLIB_CLOCK_GETTIME_ARG): Define.
46         * configure.ac: Change clock_gettime_link to CLOCK_GETTIME_LINK.
47         * Makefile.am: Likewise.
48         * configure, Makefile.in: Rebuild.
50 2017-10-02  Thomas Schwinge  <thomas@codesourcery.com>
52         PR other/67165
53         * Makefile.am: Append the content of clock_gettime_link to
54         ztest_LDADD.
55         * configure.ac: Test for the case that clock_gettime is in librt.
56         * Makefile.in: Regenerate.
57         * configure: Likewise.
59         PR other/67165
60         * configure.ac: Check for clock_gettime.
61         * config.h.in: Regenerate.
62         * configure: Likewise.
63         * ztest.c (average_time, test_large): Conditionalize test timing
64         on clock_gettime availability.
66 2017-09-29  Tony Reix  <tony.reix@atos.net>
68         * xcoff.c: Initial support for DWARF debug sections in XCOFF.
69         (STYP_DWARF, SSUBTYP_DW*): Define.
70         (enum dwarf_section): Define.
71         (struct dwsect_info): Define.
72         (xcoff_add): Look for DWARF sections, pass them to
73         backtrace_dwarf_add.
75 2017-09-28  Ian Lance Taylor  <iant@golang.org>
77         PR other/67165
78         * elf.c (__builtin_prefetch): Define if not __GNUC__.
79         (unlikely): Define.
80         (SHF_UNCOMPRESSED, ELFCOMPRESS_ZLIB): Define.
81         (b_elf_chdr): Define type.
82         (enum debug_section): Add ZDEBUG_xxx values.
83         (debug_section_names): Add names for new sections.
84         (struct debug_section_info): Add compressed field.
85         (elf_zlib_failed, elf_zlib_fetch): New static functions.
86         (HUFFMAN_TABLE_SIZE, HUFFMAN_VALUE_MASK): Define.
87         (HUFFMAN_BITS_SHIFT, HUFFMAN_BITS_MASK): Define.
88         (HUFFMAN_SECONDARY_SHIFT): Define.
89         (ZDEBUG_TABLE_SIZE): Define.
90         (ZDEBUG_TABLE_CODELEN_OFFSET, ZDEBUG_TABLE_WORK_OFFSET): Define.
91         (final_next_secondary): New static variable if
92         BACKTRACE_GENERATE_FIXED_HUFFMAN_TABLE.
93         (elf_zlib_inflate_table): New static function.
94         (BACKTRACE_GENERATE_FIXED_HUFFMAN_TABLE): If define, define main
95         function to produce fixed Huffman table.
96         (elf_zlib_default_table): New static variable.
97         (elf_zlib_inflate): New static function.
98         (elf_zlib_verify_checksum): Likewise.
99         (elf_zlib_inflate_and_verify): Likewise.
100         (elf_uncompress_zdebug): Likewise.
101         (elf_uncompress_chdr): Likewise.
102         (backtrace_uncompress_zdebug): New extern function.
103         (elf_add): Look for .zdebug sections and SHF_COMPRESSED debug
104         sections, and uncompress them.
105         * internal.h (backtrace_compress_zdebug): Declare.
106         * ztest.c: New file.
107         * configure.ac: Check for -lz and check whether the linker
108         supports --compress-debug-sections.
109         * Makefile.am (ztest_SOURCES): New variable.
110         (ztest_CFLAGS, ztest_LDADD): New variables.
111         (check_PROGRAMS): Add ztest.
112         (ctestg_SOURCES): New variable.
113         (ctestg_CFLAGS, ctestg_LDFLAGS, ctestg_LDADD): New variables.
114         (ctesta_SOURCES): New variable.
115         (ctesta_CFLAGS, ctesta_LDFLAGS, ctesta_LDADD): New variables.
116         (check_PROGRAMS): Add ctestg and ctesta.
117         * configure, config.h.in, Makefile.in: Rebuild.
119 2017-09-22  Ian Lance Taylor  <iant@golang.org>
121         PR sanitizer/77631
122         * configure.ac: Check for lstat and readlink.
123         * elf.c (lstat, readlink): Provide dummy versions if real versions
124         are not available.
125         * configure, config.h.in: Rebuild.
127 2017-09-21  Ian Lance Taylor  <iant@google.com>
129         PR go/82284
130         * elf.c (backtrace_initialize): Set pd.exe_filename.
132 2017-09-20  Ian Lance Taylor  <iant@golang.org>
133             Denis Khalikov  <d.khalikov@partner.samsung.com>
135         PR sanitizer/77631
136         Support for external debug info.
137         * elf.c: Include <errno.h>, <sys/stat.h>, <unistd.h>.
138         (S_ISLNK): Define if not defined.
139         (xstrnlen): Define if strnlen is not available.
140         (b_elf_note): Define type.
141         (NT_GNU_BUILD_ID): Define macro.
142         (elf_crc32, elf_crc32_file): New static functions.
143         (elf_is_symlink, elf_readlink): New static functions.
144         (elf_open_debugfile_by_buildid): New static function.
145         (elf_try_debugfile): New static function.
146         (elf_find_debugfile_by_debuglink): New static function.
147         (elf_open_debugfile_by_debuglink): New static function.
148         (elf_add): Add filename and debuginfo parameters.  Adjust all
149         callers.  Look for external debug info notes, and try to fetch
150         debug info from external file.
151         (struct phdr_data): Add exe_filename field.
152         (phdr_callback): Pass filename to elf_add.
153         (backtrace_initialize): Add filename parameter.
154         * internal.h (backtrace_initialize): Add filename parameter.
155         * fileline.c (fileline_initialize): Pass filename to
156         backtrace_initialize.
157         * pecoff.c (fileline_initialize): Add unused filename parameter.
158         * unknown.c (fileline_initialize): Likewise.
159         * xcoff.c (fileline_initialize): Likewise.
160         * configure.ac: Check for objcopy --add-gnu-debuglink.
161         * Makefile.am (dtest): New test target.
162         * configure, Makefile.in: Rebuild.
164 2017-09-12  Steve Ellcey  <sellcey@cavium.com>
166         PR other/81096
167         * Makefile.am (ttest_CFLAGS): Add $(AM_CFLAGS)
168         * Makefile.in: Regenerate.
170 2017-09-12  Steve Ellcey  <sellcey@cavium.com>
172         PR other/81096
173         * libbacktrace/Makefile.in
174         (HAVE_PTHREAD_TRUE@@NATIVE_TRUE@ttest_CFLAGS): Add $(AM_CFLAGS)
176 2017-08-02  David Edelsohn  <dje.gcc@gmail.com>
178         PR bootstrap/81638
179         * xcoff.c (xcoff_process_linenos): Initialize incl to NULL.
181 2017-07-28  Tony Reix  <tony.reix@atos.net>
183         * xcoff.c: Don't leak a file descriptor if an archive is malformed.
185 2017-07-28  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
187         * fileline.c (fileline_initialize): Print pid_t as long.
189 2017-07-26  Tony Reix  <tony.reix@atos.net>
191         * configure.ac: Check for XCOFF32/XCOFF64.  Check for loadquery.
192         * filetype.awk: Separate AIX XCOFF32 and XCOFF64.
193         * xcoff.c: Add support for AIX XCOFF32 and XCOFF64 formats.
194         * configure, config.h.in: Regenerate.
196 2017-07-21  Tony Reix  <tony.reix@atos.net>
198         * filetype.awk: Add AIX XCOFF type detection.
199         * configure.ac: Recognize xcoff format.
200         * Makefile.am (FORMAT_FILES): Add xcoff.c.
201         * fileline.c: Include <unistd.h>.
202         (fileline_initialize): Add case for AIX procfs.
203         * xcoff.c: New file.
204         * configure, Makefile.in: Rebuild.
206 2017-06-21  Richard Biener  <rguenther@suse.de>
208         * configure.ac: Add AC_SYS_LARGEFILE.
209         * config.h.in: Regenerate.
210         * configure: Likewise.
212 2017-06-11  Ian Lance Taylor  <iant@golang.org>
214         * elf.c (backtrace_initialize): Always set *fileline_fn.
215         * ttest.c: New file.
216         * btest.c: Move support functions into testlib.c.  Change calls to
217         check to pass file name.
218         * testlib.c: New file, copied from (part of) btest.c.
219         * testlib.h: New file, declarations for testlib.c.
220         * edtest.c: Use testlib.h and testlib.c.
221         * configure.ac: Test for -pthread, set HAVE_PTHREAD conditional.
222         * Makefile.am (btest_SOURCES): Add testlib.c.
223         (edtest_SOURCES): Likewise.
224         (CHECK_PROGRAMS): Add ttest if HAVE_PTHREAD.
225         (ttest_SOURCES, ttest_CFLAGS, ttest_LDADD): Define.
226         * configure, Makefile.in: Rebuild.
228 2017-05-19  Than McIntosh  <thanm@google.com>
230         * dwarf.c (free_line_header): Don't free dirs if dirs_count == 0.
231         (read_line_header): Don't allocate dirs if dirs_count == 0.
232         * edtest.c: New file.
233         * edtest2.c: New file.
234         * Makefile.am (edtest_SOURCES, edtest_LDADD): Define.
235         (check_PROGRAMS): Add edtest.
236         (edtest2_build.c, gen_edtest2_build): New targets.
237         * Makefile.in: Rebuild.
239 2017-03-08  Sam Thursfield  <sam.thursfield@codethink.co.uk>
241         * btest.c (test5): Replace #ifdef guard with 'unused' attribute
242         to fix compile warning when BACKTRACE_SUPPORTED isn't defined.
244 2017-01-01  Jakub Jelinek  <jakub@redhat.com>
246         Update copyright years.
248 2016-11-15  Matthias Klose  <doko@ubuntu.com>
250         * configure: Regenerate.
252 2016-09-11  Carlos Liam  <carlos@aarzee.me>
254         * all: Remove meaningless trailing whitespace.
256 2016-05-18  Uros Bizjak  <ubizjak@gmail.com>
258         PR target/71161
259         * elf.c (phdr_callback) [__i386__]: Add
260         __attribute__((__force_align_arg_pointer__)).
262 2016-03-02  Maxim Ostapenko  <m.ostapenko@partner.samsung.com>
264         * elf.c (backtrace_initialize): Properly initialize elf_fileline_fn to
265         avoid possible crash.
266         (elf_add): Don't set *fileline_fn to elf_nodebug value in case of
267         missing debug info anymore.
269 2016-02-06  John David Anglin  <danglin@gcc.gnu.org>
271         * mmap.c (MAP_FAILED): Define if not defined.
273 2016-01-04  Jakub Jelinek  <jakub@redhat.com>
275         Update copyright years.
277 2015-12-18  Andris Pavenis  <andris.pavenis@iki.fi>
279         * configure.ac: Specify that DJGPP do not have mmap
280         even when sys/mman.h exists.
281         * configure: Regenerate
283 2015-12-09  John David Anglin  <danglin@gcc.gnu.org>
285         PR libgfortran/68115
286         * configure.ac: Set libbacktrace_cv_sys_sync to no on hppa*-*-hpux*.
287         * configure: Regenerate.
288         * elf.c (backtrace_initialize): Cast __sync_bool_compare_and_swap call
289         to void.
291 2015-09-17  Ian Lance Taylor  <iant@google.com>
293         * posix.c (backtrace_open): Cast second argument of open() to int.
295 2015-09-11  Ian Lance Taylor  <iant@google.com>
297         * Makefile.am (backtrace.lo): Depend on internal.h.
298         (sort.lo, stest.lo): Add explicit dependencies.
299         * Makefile.in: Rebuild.
301 2015-09-09  Hans-Peter Nilsson  <hp@axis.com>
303         * backtrace.c: #include <sys/types.h>.
305 2015-09-08  Ian Lance Taylor  <iant@google.com>
307         PR other/67457
308         * backtrace.c: #include "internal.h".
309         (struct backtrace_data): Add can_alloc field.
310         (unwind): If can_alloc is false, don't try to get file/line
311         information.
312         (backtrace_full): Set can_alloc field in bdata.
313         * alloc.c (backtrace_alloc): Don't call error_callback if it is
314         NULL.
315         * mmap.c (backtrace_alloc): Likewise.
316         * internal.h: Update comments for backtrace_alloc and
317         backtrace_free.
319 2015-09-08  Ian Lance Taylor  <iant@google.com>
321         PR other/67457
322         * mmap.c (backtrace_alloc): Correct test for mmap failure.
324 2015-08-31  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
326         * configure.ac: For spu-*-* targets, set have_fcntl to no.
327         * configure: Regenerate.
329 2015-08-27  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
331         * configure.ac: Remove [disable-shared] argument to LT_INIT.
332         Remove setting PIC_FLAG when building as target library.
333         * configure: Regenerate.
335 2015-08-26  Hans-Peter Nilsson  <hp@axis.com>
337         * configure.ac: Only compile with -fPIC if the target
338         supports it.
339         * configure: Regenerate.
341 2015-08-24  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
343         * configure.ac: Set have_mmap to no on spu-*-* targets.
344         * configure: Regenerate.
346 2015-08-13  Ian Lance Taylor  <iant@google.com>
348         * dwarf.c (read_function_entry): Add vec_inlined parameter.
349         Change all callers.
351 2015-06-11  Martin Sebor  <msebor@redhat.com>
353         PR sanitizer/65479
354         * dwarf.c (struct line): Add new field idx.
355         (line_compare): Use it.
356         (add_line): Set it.
357         (read_line_info): Reset it.
359 2015-05-29  Tristan Gingold  <gingold@adacore.com>
361         * pecoff.c: New file.
362         * Makefile.am (FORMAT_FILES): Add pecoff.c and dependencies.
363         * Makefile.in: Regenerate.
364         * filetype.awk: Detect pecoff.
365         * configure.ac: Define BACKTRACE_SUPPORTS_DATA on elf platforms.
366         Add pecoff.
367         * btest.c (test5): Test enabled only if BACKTRACE_SUPPORTS_DATA is
368         true.
369         * backtrace-supported.h.in (BACKTRACE_SUPPORTS_DATA): Define.
370         * configure: Regenerate.
371         * pecoff.c: New file.
373 2015-05-13  Michael Haubenwallner  <michael.haubenwallner@ssi-schaefer.com>
375         * Makefile.in: Regenerated with automake-1.11.6.
376         * aclocal.m4: Likewise.
377         * configure: Likewise.
379 2015-01-24  Matthias Klose  <doko@ubuntu.com>
381         * configure.ac: Move AM_ENABLE_MULTILIB before AC_PROG_CC.
382         * configure: Regenerate.
384 2015-01-05  Jakub Jelinek  <jakub@redhat.com>
386         Update copyright years.
388 2014-11-21  H.J. Lu  <hongjiu.lu@intel.com>
390         PR bootstrap/63784
391         * configure: Regenerated.
393 2014-11-11  David Malcolm  <dmalcolm@redhat.com>
395         * ChangeLog.jit: New.
397 2014-11-11  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
399         PR target/63610
400         * configure: Regenerate.
402 2014-10-23  Ian Lance Taylor  <iant@google.com>
404         * internal.h (backtrace_atomic_load_pointer) [no atomic or sync]:
405         Fix to return void *.
407 2014-05-08  Ian Lance Taylor  <iant@google.com>
409         * mmap.c (backtrace_free): If freeing a large aligned block of
410         memory, call munmap rather than holding onto it.
411         (backtrace_vector_grow): When growing a vector, double the number
412         of pages requested.  When releasing the old version of a grown
413         vector, pass the correct size to backtrace_free.
415 2014-03-07  Ian Lance Taylor  <iant@google.com>
417         * sort.c (backtrace_qsort): Use middle element as pivot.
419 2014-03-06  Ian Lance Taylor  <iant@google.com>
421         * sort.c: New file.
422         * stest.c: New file.
423         * internal.h (backtrace_qsort): Declare.
424         * dwarf.c (read_abbrevs): Call backtrace_qsort instead of qsort.
425         (read_line_info, read_function_entry): Likewise.
426         (read_function_info, build_dwarf_data): Likewise.
427         * elf.c (elf_initialize_syminfo): Likewise.
428         * Makefile.am (libbacktrace_la_SOURCES): Add sort.c.
429         (stest_SOURCES, stest_LDADD): Define.
430         (check_PROGRAMS): Add stest.
432 2014-02-07  Misty De Meo  <misty@brew.sh>
434         PR target/58710
435         * configure.ac: Use AC_LINK_IFELSE in check for
436         _Unwind_GetIPInfo.
437         * configure: Regenerate.
439 2014-01-02  Richard Sandiford  <rdsandiford@googlemail.com>
441         Update copyright years
443 2013-12-06  Jakub Jelinek  <jakub@redhat.com>
445         * elf.c (ET_DYN): Undefine and define again.
446         (elf_add): Add exe argument, if true and ehdr.e_type is ET_DYN,
447         return early -1 without closing the descriptor.
448         (struct phdr_data): Add exe_descriptor.
449         (phdr_callback): If pd->exe_descriptor is not -1, for very first
450         call if dlpi_name is NULL just call elf_add with the exe_descriptor,
451         otherwise backtrace_close the exe_descriptor if not -1.  Adjust
452         call to elf_add.
453         (backtrace_initialize): Adjust call to elf_add.  If it returns
454         -1, set pd.exe_descriptor to descriptor, otherwise set it to -1.
456 2013-12-05  Ian Lance Taylor  <iant@google.com>
458         * alloc.c (backtrace_vector_finish): Add error_callback and data
459         parameters.  Call backtrace_vector_release.  Return address base.
460         * mmap.c (backtrace_vector_finish): Add error_callback and data
461         parameters.  Return address base.
462         * dwarf.c (read_function_info): Get new address base from
463         backtrace_vector_finish.
464         * internal.h (backtrace_vector_finish): Update declaration.
466 2013-11-27  Ian Lance Taylor  <iant@google.com>
468         * dwarf.c (find_address_ranges): New static function, broken out
469         of build_address_map.
470         (build_address_map): Call it.
471         * btest.c (check): Check for missing filename or function, rather
472         than crashing.
473         (f3): Check that enough frames were returned.
475 2013-11-19  Jakub Jelinek  <jakub@redhat.com>
477         * backtrace.h (backtrace_syminfo_callback): Add symsize argument.
478         * elf.c (elf_syminfo): Pass 0 or sym->size to the callback as
479         last argument.
480         * btest.c (struct symdata): Add size field.
481         (callback_three): Add symsize argument.  Copy it to the data->size
482         field.
483         (f23): Set symdata.size to 0.
484         (test5): Likewise.  If sizeof (int) > 1, lookup address of
485         ((uintptr_t) &global) + 1.  Verify symdata.val and symdata.size
486         values.
488         * atomic.c: Include sys/types.h.
490 2013-11-18  Ian Lance Taylor  <iant@google.com>
492         * configure.ac: Check for support of __atomic extensions.
493         * internal.h: Declare or #define atomic functions for use in
494         backtrace code.
495         * atomic.c: New file.
496         * dwarf.c (dwarf_lookup_pc): Use atomic functions.
497         (dwarf_fileline, backtrace_dwarf_add): Likewise.
498         * elf.c (elf_add_syminfo_data, elf_syminfo): Likewise.
499         (backtrace_initialize): Likewise.
500         * fileline.c (fileline_initialize): Likewise.
501         * Makefile.am (libbacktrace_la_SOURCES): Add atomic.c.
502         * configure, config.h.in, Makefile.in: Rebuild.
504 2013-11-18  Jakub Jelinek  <jakub@redhat.com>
506         * elf.c (SHN_UNDEF): Define.
507         (elf_initialize_syminfo): Add base_address argument.  Ignore symbols
508         with st_shndx == SHN_UNDEF.  Add base_address to address fields.
509         (elf_add): Adjust caller.
511         * elf.c (phdr_callback): Process info->dlpi_addr == 0 normally.
513 2013-11-16  Ian Lance Taylor  <iant@google.com>
515         * backtrace.h (backtrace_create_state): Correct comment about
516         threading.
518 2013-11-15  Ian Lance Taylor  <iant@google.com>
520         * backtrace.h (backtrace_syminfo): Update comment and parameter
521         name to take any address, not just a PC value.
522         * elf.c (STT_OBJECT): Define.
523         (elf_nosyms): Rename parameter pc to addr.
524         (elf_symbol_search): Rename local variable pc to addr.
525         (elf_initialize_syminfo): Add STT_OBJECT symbols to elf_symbols.
526         (elf_syminfo): Rename parameter pc to addr.
527         * btest.c (global): New global variable.
528         (test5): New test.
529         (main): Call test5.
531 2013-10-17  Ian Lance Taylor  <iant@google.com>
533         * elf.c (elf_add): Don't get the wrong offsets if a debug section
534         is missing.
536 2013-10-15  David Malcolm  <dmalcolm@redhat.com>
538         * configure.ac: Add --enable-host-shared, setting up
539         pre-existing PIC_FLAG variable within Makefile.am et al.
540         * configure: Regenerate.
542 2013-09-20  Alan Modra  <amodra@gmail.com>
544         * configure: Regenerate.
546 2013-07-23  Alexander Monakov  <amonakov@ispras.ru>
548         * elf.c (elf_syminfo): Loop over the elf_syminfo_data chain.
550 2013-07-23  Alexander Monakov  <amonakov@ispras.ru>
552         * elf.c (backtrace_initialize): Pass elf_fileline_fn to
553         dl_iterate_phdr callbacks.
555 2013-03-25  Ian Lance Taylor  <iant@google.com>
557         * alloc.c: #include <sys/types.h>.
558         * mmap.c: Likewise.
560 2013-01-31  Ian Lance Taylor  <iant@google.com>
562         * dwarf.c (read_function_info): Permit fvec parameter to be NULL.
563         (dwarf_lookup_pc): Don't use ddata->fvec if threaded.
565 2013-01-25  Jakub Jelinek  <jakub@redhat.com>
567         PR other/56076
568         * dwarf.c (read_line_header): Don't crash if DW_AT_comp_dir
569         attribute was not seen.
571 2013-01-16  Ian Lance Taylor  <iant@google.com>
573         * dwarf.c (struct unit): Add filename and abs_filename fields.
574         (build_address_map): Set new fields when reading unit.
575         (dwarf_lookup_pc): If we don't find an entry in the line table,
576         just return the main file name.
578 2013-01-14  Richard Sandiford  <rdsandiford@googlemail.com>
580         Update copyright years.
582 2013-01-01  Ian Lance Taylor  <iant@google.com>
584         PR bootstrap/54834
585         * Makefile.am (AM_CPPFLAGS): Remove -I ../gcc/include and -I
586         $(MULTIBUILDTOP)/../../gcc/include.
587         * Makefile.in: Rebuild.
589 2013-01-01  Ian Lance Taylor  <iant@google.com>
591         PR other/55536
592         * mmap.c (backtrace_alloc): Don't call sync functions if not
593         threaded.
594         (backtrace_free): Likewise.
596 2012-12-12  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
598         * mmapio.c: Define MAP_FAILED if not defined.
600 2012-12-11  Jakub Jelinek  <jakub@redhat.com>
602         PR bootstrap/54926
603         * Makefile.am (AM_CFLAGS): Remove -frandom-seed=$@.
604         * configure.ac: If --with-target-subdir, add -frandom-seed=$@
605         to EXTRA_FLAGS unconditionally, otherwise check whether the compiler
606         accepts it.
607         * Makefile.in: Regenerated.
608         * configure: Regenerated.
610 2012-12-07  Jakub Jelinek  <jakub@redhat.com>
612         PR bootstrap/54926
613         * Makefile.am (AM_CFLAGS): Add -frandom-seed=$@.
614         * Makefile.in: Regenerated.
616 2012-11-20  Ian Lance Taylor  <iant@google.com>
618         * dwarf.c (read_attribute): Always clear val.
620 2012-11-13  Ian Lance Taylor  <iant@google.com>
622         PR other/55312
623         * configure.ac: Only add -Werror if building a target library.
624         * configure: Rebuild.
626 2012-11-12  Ian Lance Taylor  <iant@google.com>
627             Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
628             Gerald Pfeifer  <gerald@pfeifer.com>
630         * configure.ac: Check for getexecname.
631         * fileline.c: #include <errno.h>.  Define getexecname if not
632         available.
633         (fileline_initialize): Try to find the executable in a few
634         different ways.
635         * print.c (error_callback): Only print the filename if it came
636         from the backtrace state.
637         * configure, config.h.in: Rebuild.
639 2012-10-29  Ian Lance Taylor  <iant@google.com>
641         * mmap.c (backtrace_vector_release): Correct last patch: add
642         aligned, not size.
644 2012-10-29  Ian Lance Taylor  <iant@google.com>
646         * mmap.c (backtrace_vector_release): Make sure freed block is
647         aligned on 8-byte boundary.
649 2012-10-26  Ian Lance Taylor  <iant@google.com>
651         PR other/55087
652         * posix.c (backtrace_open): Add does_not_exist parameter.
653         * elf.c (phdr_callback): Do not warn if shared library could not
654         be opened.
655         * fileline.c (fileline_initialize): Update calls to
656         backtrace_open.
657         * internal.h (backtrace_open): Update declaration.
659 2012-10-26  Jack Howarth  <howarth@bromo.med.uc.edu>
661         PR target/55061
662         * configure.ac: Check for _Unwind_GetIPInfo function declaration.
663         * configure: Regenerate.
665 2012-10-24  Ian Lance Taylor  <iant@google.com>
667         PR target/55061
668         * configure.ac: Check whether -funwind-tables option works.
669         * configure: Rebuild.
671 2012-10-11  Ian Lance Taylor  <iant@google.com>
673         * configure.ac: Do not use dl_iterate_phdr on Solaris 10.
674         * configure: Rebuild.
676 2012-10-10  Ian Lance Taylor  <iant@google.com>
678         * elf.c: Rename all Elf typedefs to start with b_elf, and be all
679         lower case.
681 2012-10-10  Hans-Peter Nilsson  <hp@bitrange.com>
683         * elf.c (elf_add_syminfo_data): Add casts to avoid warning.
685 2012-10-09  Ian Lance Taylor  <iant@google.com>
687         * dwarf.c (dwarf_fileline): Add cast to avoid warning.
688         (backtrace_dwarf_add): Likewise.
690 2012-10-09  Ian Lance Taylor  <iant@google.com>
692         Add support for tracing through shared libraries.
693         * configure.ac: Check for link.h and dl_iterate_phdr.
694         * elf.c: #include <link.h> if system has dl_iterate_phdr.  #undef
695         ELF macros before #defining them.
696         (dl_phdr_info, dl_iterate_phdr): Define if system does not have
697         dl_iterate_phdr.
698         (struct elf_syminfo_data): Add next field.
699         (elf_initialize_syminfo): Initialize next field.
700         (elf_add_syminfo_data): New static function.
701         (elf_add): New static function, broken out of
702         backtrace_initialize.  Call backtrace_dwarf_add instead of
703         backtrace_dwarf_initialize.
704         (struct phdr_data): Define.
705         (phdr_callback): New static function.
706         (backtrace_initialize): Call elf_add.
707         * dwarf.c (struct dwarf_data): Add next and base_address fields.
708         (add_unit_addr): Add base_address parameter.  Change all callers.
709         (add_unit_ranges, build_address_map): Likewise.
710         (add_line): Add ddata parameter.  Change all callers.
711         (read_line_program, add_function_range): Likewise.
712         (dwarf_lookup_pc): New static function, broken out of
713         dwarf_fileline.
714         (dwarf_fileline): Call dwarf_lookup_pc.
715         (build_dwarf_data): New static function.
716         (backtrace_dwarf_add): New function.
717         (backtrace_dwarf_initialize): Remove.
718         * internal.h (backtrace_dwarf_initialize): Don't declare.
719         (backtrace_dwarf_add): Declare.
720         * configure, config.h.in: Rebuild.
722 2012-10-04  Gerald Pfeifer  <gerald@pfeifer.com>
724         * btest.c (f23): Avoid uninitialized variable warning.
726 2012-10-04  Ian Lance Taylor  <iant@google.com>
728         * dwarf.c: If the system header files do not declare strnlen,
729         provide our own version.
731 2012-10-03  Ian Lance Taylor  <iant@google.com>
733         * dwarf.c (read_uleb128): Fix overflow test.
734         (read_sleb128): Likewise.
735         (build_address_map): Don't change unit_buf.start.
737 2012-10-02  Uros Bizjak  <ubizjak@gmail.com>
739         PR other/54761
740         * configure.ac (EXTRA_FLAGS): New.
741         * Makefile.am (AM_FLAGS): Add $(EXTRA_FLAGS).
742         * configure, Makefile.in: Regenerate.
744 2012-09-29  Ian Lance Taylor  <iant@google.com>
746         PR other/54749
747         * fileline.c (fileline_initialize): Pass errnum as -1 when
748         reporting that we could not read executable information after a
749         previous failure.
751 2012-09-27  Ian Lance Taylor  <iant@google.com>
753         PR bootstrap/54732
754         * configure.ac: Add no-dependencies to AM_INIT_AUTOMAKE.
755         * Makefile.am: Add dependencies for all objects.
756         * configure, aclocal.m4, Makefile.in: Rebuild.
758 2012-09-27  Ian Lance Taylor  <iant@google.com>
760         PR other/54726
761         * elf.c (backtrace_initialize): Set *fileln_fn, not
762         state->fileln_fn.
764 2012-09-19  Ian Lance Taylor  <iant@google.com>
766         * configure.ac: Only use GCC_CHECK_UNWIND_GETIPINFO when compiled
767         as a target library.
768         * configure: Rebuild.
770 2012-09-19  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
771             Ian Lance Taylor  <iant@google.com>
773         * configure.ac (GCC_HEADER_STDINT): Invoke.
774         * backtrace.h: If we can't find <stdint.h>, use "gstdint.h".
775         * btest.c: Don't include <stdint.h>.
776         * dwarf.c: Likewise.
777         * configure, aclocal.m4, Makefile.in, config.h.in: Rebuild.
779 2012-09-18  Ian Lance Taylor  <iant@google.com>
781         PR bootstrap/54623
782         * Makefile.am (AM_CPPFLAGS): Define.
783         (AM_CFLAGS): Remove -I options.
784         * Makefile.in: Rebuild.
786 2012-09-18  Ian Lance Taylor  <iant@google.com>
788         * posix.c (O_BINARY): Define if not defined.
789         (backtrace_open): Pass O_BINARY to open.  Only call fcntl if
790         HAVE_FCNTL is defined.
791         * configure.ac: Test for the fcntl function.
792         * configure, config.h.in: Rebuild.
794 2012-09-18  Ian Lance Taylor  <iant@google.com>
796         * btest.c (test1, test2, test3, test4): Add the unused attribute.
798 2012-09-18  Ian Lance Taylor  <iant@google.com>
800         * dwarf.c: Correct test of HAVE_DECL_STRNLEN.
802 2012-09-18  Ian Lance Taylor  <iant@google.com>
804         * configure.ac: Add AC_USE_SYSTEM_EXTENSIONS.
805         * mmapio.c: Don't define _GNU_SOURCE.
806         * configure, config.h.in: Rebuild.
808 2012-09-18  Ian Lance Taylor  <iant@google.com>
810         * configure.ac: Check whether strnlen is declared.
811         * dwarf.c: Declare strnlen if not declared.
812         * configure, config.h.in: Rebuild.
814 2012-09-18  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
816         * fileline.c: Include <stdlib.h>.
817         * mmap.c: Likewise.
819 2012-09-17  Ian Lance Taylor  <iant@google.com>
821         PR bootstrap/54611
822         * nounwind.c (backtrace_full): Rename from backtrace.  Add state
823         parameter.
825 2012-09-17  Gerald Pfeifer  <gerald@pfeifer.com>
827         PR bootstrap/54611
828         * nounwind.c (backtrace_simple): Add state parameter.
830 2012-09-17  Ian Lance Taylor  <iant@google.com>
832         PR bootstrap/54609
833         * unknown.c (unknown_fileline): Add state parameter, remove
834         fileline_data parameter, name error_callback parameter.
835         (backtrace_initialize): Add state parameter.
837 2012-09-17  Ian Lance Taylor  <iant@google.com>
839         * Initial implementation.
841 Copyright (C) 2012-2018 Free Software Foundation, Inc.
843 Copying and distribution of this file, with or without modification,
844 are permitted in any medium without royalty provided the copyright
845 notice and this notice are preserved.