Update copyright years.
[gcc.git] / libbacktrace / ChangeLog
1 2020-01-01 Jakub Jelinek <jakub@redhat.com>
2
3 Update copyright years.
4
5 2019-12-13 Ian Lance Taylor <iant@golang.org>
6
7 Add DWARF 5 support.
8 * dwarf.c (struct attr): Add val field.
9 (enum attr_val_encoding): Add ATTR_VAL_ADDDRESS_INDEX,
10 ATTR_VAL_STRING_INDEX, ATTR_VAL_RNGLISTS_INDEX.
11 (struct line_header): Add addrsize field.
12 (struct line_header_format): Define.
13 (struct unit): Add str_offsets_base, addr_base, and rnglists_base
14 fields.
15 (read_uint24): New static function.
16 (read_attribute): Add implicit_val parameter. Replace dwarf_str
17 and dwarf_str_size parameters with dwarf_sections parameter. Add
18 support for new DWARF 5 forms. Change all callers.
19 (resolve_string): New static function.
20 (resolve_addr_index): Likewise.
21 (read_abbrevs): Support DW_FORM_implicit_const.
22 (struct pcrange): Add lowpc_is_addr_index, highpc_is_addr_Index,
23 and ranges_is_index fields.
24 (update_pcrange): Support DWARF 5 encodings.
25 (add_high_low_range): New static function, split out of
26 add_ranges.
27 (add_ranges_from_ranges): Likewise.
28 (add_ranges_from_rnglists): New static function.
29 (add_ranges): Just call new helper functions.
30 (find_address_ranges): Use resolve_string for strings, after
31 reading all attributes. Handle new DWARF 5 attributes.
32 (build_address_map): Support DWARF 5 compilation units.
33 (read_v2_paths): New static function, split out of
34 read_line_header.
35 (read_lnct): New static function.
36 (read_line_header_format_entries): Likewise.
37 (read_line_header): Add ddata parameter. Support DWARF 5 line
38 headers. Call new helper functions. Change all callers.
39 (read_line_program): Use addrsize from line program header. Don't
40 special case directory index 0 for DWARF 5.
41 (read_referenced_name): Use resolve_string.
42 (read_function_entry): Handle DWARF 5 encodings. Use
43 resolve_string.
44 * internal.h (enum dwarf_section): Add DEBUG_ADDR,
45 DEBUG_STR_OFFSETS, DEBUG_LINE_STR, DEBUG_RNGLISTS.
46 * elf.c (dwarf_section_names): Add new section names.
47 * pecoff.c (dwarf_section_names): Likewise.
48 * xcoff.c (xcoff_add): Clear dwarf_sections before setting
49 fields.
50 * configure.ac: Define HAVE_DWARF5 automake conditional.
51 * Makefile.am (dwarf5_SOURCES): New variable if HAVE_DWARF5.
52 (dwarf5_CFLAGS, dwarf5_LDADD): Likewise.
53 (dwarf5_alloc_SOURCES, dwarf5_alloc_CFLAGS): Likewise.
54 (dwarf5_alloc_LDADD): Likewise.
55 (BUILDTESTS): Add dwarf5 tests if HAVE_DWARF5.
56 (CLEANFILES, clean-local): Define.
57
58 2019-12-08 Ian Lance Taylor <iant@golang.org>
59
60 * dwarf.c (struct pcrange): Define.
61 (update_pcrange, add_ranges): New static functions.
62 (add_unit_addr): Change signature to work with add_ranges. Don't
63 add base_address here.
64 (add_unit_ranges): Remove.
65 (find_address_ranges): Replace str/ranges parameters with
66 dwarf_sections. Use update_pcrange and add_ranges. Change all
67 callers.
68 (add_function_range): Change signature to work with add_ranges.
69 Don't add base_address here.
70 (add_function_ranges): Remove.
71 (read_function_entry): Use update_pcrange and add_ranges.
72
73 2019-12-04 Ian Lance Taylor <iant@golang.org>
74
75 * edtest.c (test1): Add noclone attribute.
76
77 2019-12-04 Ian Lance Taylor <iant@golang.org>
78
79 * internal.h (enum dwarf_section): Define.
80 (struct dwarf_sections): Define.
81 (backtrace_dwarf_add): Update declaration to replace specific
82 section parameters with dwarf_sections parameter.
83 * dwarf.c (struct dwarf_data): Replace specific section fields
84 with dwarf_sections field.
85 (read_attribute): Use dwarf_sections with altlink.
86 (build_address_map): Replace specific section parameters with
87 dwarf_sections parameter. Change all callers.
88 (read_line_info): Use dwarf_sections with ddata.
89 (read_referenced_name): Likewise.
90 (add_function_ranges): Likewise.
91 (read_function_entry): Likewise.
92 (read_function_info): Likewise.
93 (build_dwarf_data): Replace specific section parameters with
94 dwarf_sections parameter. Change all callers.
95 (backtrace_dwarf_add): Likewise.
96 * elf.c (enum debug_section): Remove.
97 (dwarf_section_names): Remove .zdebug names.
98 (elf_add): Track zsections separately. Build dwarf_sections.
99 * pecoff.c (enum debug_section): Remove.
100 (struct debug_section_info): Remove data field.
101 (coff_add): Build dwarf_sections.
102 * xcoff.c (enum dwarf_section): Remove. Replace DWSECT_xxx
103 references with DEBUG_xxx references.
104 (xcoff_add): Build dwarf_sections.
105
106 2019-09-27 Maciej W. Rozycki <macro@wdc.com>
107
108 * configure: Regenerate.
109
110 2019-09-26 Ian Lance Taylor <iant@golang.org>
111
112 PR libbacktrace/91908
113 * pecoff.c (backtrace_initialize): Explicitly cast unchecked
114 __sync_bool_compare_and_swap to void.
115 * xcoff.c (backtrace_initialize): Likewise.
116
117 2019-09-03 Ulrich Weigand <uweigand@de.ibm.com>
118
119 * configure.ac: Remove references to spu.
120 * configure: Regenerate.
121
122 2019-05-24 Clement Chigot <clement.chigot@atos.net>
123
124 * Makefile.am (BUILDTESTS): Remove test_elf, add test_elf_32 and
125 test_elf_64.
126 * Makefile.in: Regenerate.
127
128 2019-05-14 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
129
130 * configure.ac (have_dl_iterate_phdr): Remove *-*-solaris2.10*
131 handling.
132 * configure: Regenerate.
133
134 2019-03-11 Ian Lance Taylor <iant@golang.org>
135
136 PR libbacktrace/89669
137 * Makefile.am (BUILDTESTS): Only add ztest and ztest_alloc if
138 HAVE_ELF.
139 * Makefile.in: Regenerate.
140
141 2019-02-26 Tom de Vries <tdevries@suse.de>
142
143 * btest.c (test5): Allow global.* as minimal symbol name for global.
144
145 2019-02-26 Tom de Vries <tdevries@suse.de>
146
147 * Makefile.am (TESTS): Only add b3test_dwz_buildid if HAVE_DWZ.
148 * Makefile.in: Regenerate.
149
150 2019-02-12 Tom de Vries <tdevries@suse.de>
151
152 PR libbacktrace/81983
153 * dwarf.c (dwarf_lookup_pc): Don't call bsearch if nmemb == 0.
154
155 2019-02-10 Tom de Vries <tdevries@suse.de>
156
157 * Makefile.am (BUILDTESTS): Add btest_lto.
158 * Makefile.in: Regenerate.
159 * btest.c (test1, f2, f3, test3, f22, f23): Declare with
160 __attribute__((noclone)).
161
162 2019-02-08 Tom de Vries <tdevries@suse.de>
163
164 * backtrace.c (backtrace_full): Declare with __attribute__((noinline)).
165 * print.c (backtrace_print): Same.
166 * simple.c (backtrace_simple): Same.
167
168 2019-02-08 Tom de Vries <tdevries@suse.de>
169
170 PR libbacktrace/78063
171 * dwarf.c (build_address_map): Keep all parsed units.
172 (read_referenced_name_from_attr): Handle DW_FORM_ref_addr.
173
174 2019-01-31 Tom de Vries <tdevries@suse.de>
175
176 PR libbacktrace/89136
177 * elf.c (elf_add): Read build-id if with_buildid_data. Fix
178 'debugaltlink_name_len =+ 1'.
179
180 2019-01-29 Tom de Vries <tdevries@suse.de>
181
182 * install-debuginfo-for-buildid.sh.in: New script.
183 * Makefile.am (check_PROGRAMS): Add b2test and b3test.
184 (TESTS): Add b2test_buildid and b3test_dwz_buildid.
185 * Makefile.in: Regenerate.
186 * configure.ac (HAVE_ELF): Set with AM_CONDITIONAL.
187 (READELF): Set with AC_CHECK_PROG.
188 (install-debuginfo-for-buildid.sh): Generate with AC_CONFIG_FILES.
189 * configure: Regenerate.
190 * elf.c (SYSTEM_BUILD_ID_DIR): Factor out of ...
191 (elf_open_debugfile_by_buildid): ... here.
192
193 2019-01-29 Tom de Vries <tdevries@suse.de>
194
195 * Makefile.am: Replace check_PROGRAMS with BUILDTESTS, except for
196 allocfail.
197 (TESTS): Don't add check_PROGRAMS. Add BUILDTESTS.
198 (check_PROGRAMS): Add BUILDTESTS.
199 * Makefile.in: Regenerate.
200
201 2019-01-28 Tom de Vries <tdevries@suse.de>
202
203 * Makefile.am (xcoff_%.c): Generate sed result into temporary file.
204 Use $< to access prerequisite.
205 * Makefile.in: Regenerate.
206
207 2019-01-25 Nathan Sidwell <nathan@acm.org>
208
209 * elf.c (elf_add): Pass "" filename to recursive call with
210 separated debug.
211
212 2019-01-25 Tom de Vries <tdevries@suse.de>
213
214 * elf.c (elf_add): When handling .gnu_debugaltlink, call elf_add with
215 filename == "".
216 * Makefile.am (TESTS): Add btest_dwz_gnudebuglink.
217 * Makefile.in: Regenerate.
218
219 2019-01-25 Tom de Vries <tdevries@suse.de>
220
221 * Makefile.am: Rewrite dtest rule into "%_gnudebuglink" pattern rule.
222 (TESTS): Rename dtest to btest_gnudebuglink.
223 * Makefile.in: Regenerate.
224
225 2019-01-23 Tom de Vries <tdevries@suse.de>
226
227 * dwarf.c (struct unit): Use size_t for low_offset/high_offset fields.
228 (units_search, find_unit): Use size_t for offset.
229 (build_address_map): Use size_t for unit_offset.
230
231 2019-01-20 Gerald Pfeifer <gerald@pfeifer.com>
232
233 * allocfail.c (main): Increase portability of printf statement.
234
235 2019-01-18 Ian Lance Taylor <iant@golang.org>
236
237 PR libbacktrace/88890
238 * mmapio.c (backtrace_get_view): Change size parameter to
239 uint64_t. Check that value fits in size_t.
240 * read.c (backtrace_get_view): Likewise.
241 * internal.h (backtrace_get_view): Update declaration.
242 * elf.c (elf_add): Pass shstrhdr->sh_size to backtrace_get_view.
243
244 2019-01-17 Tom de Vries <tdevries@suse.de>
245
246 PR libbacktrace/82857
247 * configure.ac (DWZ): Set with AC_CHECK_PROG.
248 (HAVE_DWZ): Set with AM_CONDITIONAL.
249 * configure: Regenerate.
250 * Makefile.am (TESTS): Add btest_dwz.
251 * Makefile.in: Regenerate.
252
253 2019-01-17 Tom de Vries <tdevries@suse.de>
254
255 PR libbacktrace/82857
256 * dwarf.c (enum attr_val_encoding): Add ATTR_VAL_REF_ALT_INFO.
257 (read_attribute): Handle DW_FORM_GNU_ref_alt using
258 ATTR_VAL_REF_ALT_INFO.
259 (read_referenced_name_from_attr): Handle DW_FORM_GNU_ref_alt.
260
261 2019-01-17 Tom de Vries <tdevries@suse.de>
262
263 * dwarf.c (struct unit): Add low_offset and high_offset fields.
264 (struct unit_vector): New type.
265 (struct dwarf_data): Add units and units_counts fields.
266 (find_unit): New function.
267 (find_address_ranges): Add and handle unit_tag parameter.
268 (build_address_map): Add and handle units_vec parameter.
269 (build_dwarf_data): Pass units_vec to build_address_map. Store resulting
270 units vector.
271
272 2019-01-17 Tom de Vries <tdevries@suse.de>
273
274 PR libbacktrace/82857
275 * dwarf.c (read_attribute): Handle DW_FORM_GNU_strp_alt
276 using altlink.
277
278 2019-01-17 Tom de Vries <tdevries@suse.de>
279
280 * dwarf.c (enum attr_val_encoding): Add ATTR_VAL_NONE.
281 (read_attribute): Add altlink parameter. Handle missing altlink for
282 DW_FORM_GNU_strp_alt and DW_FORM_GNU_ref_alt.
283 (find_address_ranges, build_address_map, build_dwarf_data): Add and
284 handle altlink parameter.
285 (read_referenced_name, read_function_entry): Add argument to
286 read_attribute call.
287
288 2019-01-17 Tom de Vries <tdevries@suse.de>
289
290 * dwarf.c (struct dwarf_data): Add altlink field.
291 (backtrace_dwarf_add): Add and handle fileline_altlink parameter.
292 * elf.c (elf_add): Add argument to backtrace_dwarf_add call.
293 (phdr_callback, backtrace_initialize): Add argument to elf_add calls.
294 * internal.h (backtrace_dwarf_add): Add fileline_altlink parameter.
295 * pecoff.c (coff_add): Add argument to backtrace_dwarf_add call.
296 * xcoff.c (xcoff_add): Same.
297
298 2019-01-17 Tom de Vries <tdevries@suse.de>
299
300 * internal.h (backtrace_dwarf_add): Add fileline_entry parameter.
301 * dwarf.c (backtrace_dwarf_add): Add and handle fileline_entry parameter.
302 * elf.c (elf_add): Add and handle fileline_entry parameter. Add
303 argument to backtrace_dwarf_add call.
304 (phdr_callback, backtrace_initialize): Add argument to elf_add calls.
305 * pecoff.c (coff_add): Add argument to backtrace_dwarf_add call.
306 * xcoff.c (xcoff_add): Same.
307
308 2019-01-17 Tom de Vries <tdevries@suse.de>
309
310 * elf.c (elf_add): Add and handle with_buildid_data and
311 with_buildid_size parameters. Handle .gnu_debugaltlink section.
312 (phdr_callback, backtrace_initialize): Add arguments to elf_add calls.
313
314 2019-01-16 Tom de Vries <tdevries@suse.de>
315
316 * dwarf.c (read_referenced_name_from_attr): New function. Factor out
317 of ...
318 (read_referenced_name): ... here, and ...
319 (read_function_entry): ... here.
320
321 2019-01-16 Tom de Vries <tdevries@suse.de>
322
323 * dwarf.c (read_referenced_name): Don't allow DW_AT_name to override any
324 name.
325 (read_function_entry): Same. Don't allow name found via
326 DW_AT_abstract_origin or case DW_AT_specification to override linkage
327 name.
328
329 2019-01-09 Sandra Loosemore <sandra@codesourcery.com>
330
331 PR other/16615
332
333 * backtrace.h: Mechanically replace "can not" with "cannot".
334
335 2019-01-01 Jakub Jelinek <jakub@redhat.com>
336
337 Update copyright years.
338
339 2018-12-29 Gerald Pfeifer <gerald@pfeifer.com>
340
341 * Makefile.am (xcoff_%.c): Use an actual newline instead of \n
342 in sed pattern.
343 * Makefile.in: Regenerate.
344
345 2018-12-28 Tom de Vries <tdevries@suse.de>
346
347 * dwarf.c (build_address_map): Reuse unused units.
348
349 2018-12-28 Tom de Vries <tdevries@suse.de>
350
351 * dwarf.c (build_address_map): Simplify by removing local variable
352 abbrevs.
353
354 2018-12-28 Ian Lance Taylor <iant@golang.org>
355 Tom de Vries <tdevries@suse.de>
356
357 PR libbacktrace/88063
358 * dwarf.c (free_unit_addrs_vector): Remove.
359 (build_address_map): Keep track of allocated units in vector. Free
360 allocated units and corresponding abbrevs upon failure. Remove now
361 redundant call to free_unit_addrs_vector. Free addrs vector upon
362 failure. Free allocated unit vector.
363
364 2018-12-28 Tom de Vries <tdevries@suse.de>
365
366 * dwarf.c (build_address_map): Free addrs vector upon failure.
367
368 2018-12-14 Tom de Vries <tdevries@suse.de>
369
370 PR testsuite/88491
371 * allocfail.sh: Remove "set -o pipefail".
372
373 2018-12-12 Tom de Vries <tdevries@suse.de>
374
375 * Makefile.am (TESTS): Add allocfail.sh.
376 (check_PROGRAMS): Add allocfail.
377 * Makefile.in: Regenerate.
378 * instrumented_alloc.c: New file. Redefine malloc and realloc.
379 Include alloc.c.
380 * allocfail.c: New file.
381 * allocfail.sh: New file.
382
383 2018-11-30 Tom de Vries <tdevries@suse.de>
384
385 * Makefile.am (check_PROGRAMS): Add test_elf, test_xcoff_32,
386 test_xcoff_64, test_pecoff and test_unknown.
387 * Makefile.in: Regenerate.
388 * test_format.c: New file.
389
390 2018-11-30 Tom de Vries <tdevries@suse.de>
391
392 * Makefile.am : Add _with_alloc version for each test in
393 check_PROGRAMS.
394 * Makefile.in: Regenerate.
395
396 2018-11-30 Tom de Vries <tdevries@suse.de>
397
398 * internal.h (backtrace_vector_free): New static inline fuction,
399 factored out of ...
400 * dwarf.c (read_line_info): ... here.
401
402 2018-11-28 Tom de Vries <tdevries@suse.de>
403
404 * dwarf.c (read_abbrevs): Fix handling of abbrevs->abbrevs allocation
405 failure.
406
407 2018-11-27 Tom de Vries <tdevries@suse.de>
408
409 * mmap.c (backtrace_vector_release): Same.
410 * unittest.c (test1): Add check.
411
412 2018-11-27 Tom de Vries <tdevries@suse.de>
413
414 * alloc.c (backtrace_vector_release): Handle vec->size == 0 using free
415 instead of realloc.
416 * Makefile.am (check_PROGRAMS): Add unittest.
417 * Makefile.in: Regenerate.
418 * unittest.c: New file.
419
420 2018-11-22 Tom de Vries <tdevries@suse.de>
421
422 * dwarf.c (read_initial_length): Factor out of ...
423 (build_address_map, read_line_info): ... here.
424
425 2018-11-21 Tom de Vries <tdevries@suse.de>
426
427 * dwarf.c (read_string): Factor out of ...
428 (read_attribute, read_line_header, read_line_program): ... here.
429
430 2018-10-31 Joseph Myers <joseph@codesourcery.com>
431
432 PR bootstrap/82856
433 * Makefile.am: Include multilib.am.
434 * configure.ac: Remove AC_PREREQ. Use AC_LANG_SOURCE.
435 * Makefile.in, aclocal.m4, config.h.in, configure: Regenerate.
436
437 2018-10-05 Ian Lance Taylor <iant@golang.org>
438
439 PR libbacktrace/87529
440 * backtrace.h: Document that backtrace_create_state should be
441 called only once.
442
443 2018-08-05 Iain Buclaw <ibuclaw@gdcproject.org>
444
445 * configure.ac: Move define of HAVE_ZLIB into check for -lz.
446 * Makefile.in: Regenerate.
447 * config.h.in: Likewise.
448 * configure: Likewise.
449
450 2018-08-01 Tony Reix <tony.reix@atos.net>
451
452 * xcoff.c (struct xcoff_line, struct xcoff_line_vector): Remove.
453 (struct xcoff_func, struct xcoff_func_vector): New structs.
454 (xcoff_syminfo): Drop leading dot from symbol name.
455 (xcoff_line_compare, xcoff_line_search): Remove.
456 (xcoff_func_compare, xcoff_func_search): New static functions.
457 (xcoff_lookup_pc): Search function table.
458 (xcoff_add_line, xcoff_process_linenos): Remove.
459 (xcoff_initialize_fileline): Build function table.
460
461 2018-06-21 Denis Khalikov <d.khalikov@partner.samsung.com>
462
463 PR other/86198
464 * elf.c (elf_add): Increase ".note.gnu.build-id" section size
465 checking up to 36 bytes.
466
467 2018-04-24 H.J. Lu <hongjiu.lu@intel.com>
468
469 * configure: Regenerated.
470
471 2018-04-19 Jakub Jelinek <jakub@redhat.com>
472
473 * configure: Regenerated.
474
475 2018-04-17 Ian Lance Taylor <iant@golang.org>
476
477 * backtrace.c: Revert last two changes. Don't call mmap
478 directly.
479
480 2018-04-17 Ian Lance Taylor <iant@golang.org>
481
482 * backtrace.c: Include backtrace-supported.h before checking
483 BACKTRACE_USES_MALLOC.
484
485 2018-04-17 Ian Lance Taylor <iant@golang.org>
486
487 * backtrace.c (backtrace_full): When testing whether we can
488 allocate memory, call mmap directly, and munmap the memory.
489
490 2018-04-04 Jakub Jelinek <jakub@redhat.com>
491
492 PR other/85161
493 * elf.c (elf_zlib_fetch): Fix up predefined macro names in test for
494 big endian, only use 32-bit loads if endianity macros are predefined
495 and indicate big or little endian.
496
497 2018-02-14 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
498
499 PR target/84148
500 * configure: Regenerate.
501
502 2018-02-15 Jakub Jelinek <jakub@redhat.com>
503
504 PR other/82368
505 * elf.c (SHT_PROGBITS): Undefine and define.
506
507 2018-02-14 Jakub Jelinek <jakub@redhat.com>
508
509 PR other/82368
510 * elf.c (EM_PPC64, EF_PPC64_ABI): Undefine and define.
511 (struct elf_ppc64_opd_data): New type.
512 (elf_initialize_syminfo): Add opd argument, handle symbols
513 pointing into the PowerPC64 ELFv1 .opd section.
514 (elf_add): Read .opd section on PowerPC64 ELFv1, pass pointer
515 to structure with .opd data to elf_initialize_syminfo.
516
517 2018-01-31 Ian Lance Taylor <iant@golang.org>
518
519 * elf.c (elf_add): Close descriptor if we use a debugfile.
520 * btest.c (check_open_files): New static function.
521 (main): Call check_open_files.
522
523 2018-01-25 Ian Lance Taylor <iant@golang.org>
524
525 * elf.c (elf_open_debugfile_by_debuglink): Don't check CRC if the
526 desired CRC is zero.
527 (elf_add): Don't clear *found_sym and *found_dwarf if debuginfo.
528
529 2018-01-25 Ian Lance Taylor <iant@golang.org>
530
531 * pecoff.c (coff_add): Only release syms_view if it is valid.
532
533 2018-01-25 Ian Lance Taylor <iant@golang.org>
534
535 * pecoff.c (coff_add): Another memcpy -> coff_read4 fix.
536
537 2018-01-24 Ian Lance Taylor <iant@golang.org>
538
539 * pecoff.c (coff_add): Use coff_read4, not memcpy.
540
541 2018-01-24 Ian Lance Taylor <iant@golang.org>
542
543 PR other/68239
544 * mmap.c (backtrace_free_locked): Don't put more than 16 entries
545 on the free list.
546
547 2018-01-19 Tony Reix <tony.reix@atos.net>
548
549 * xcoff.c (xcoff_incl_compare): New function.
550 (xcoff_incl_search): New function.
551 (xcoff_process_linenos): Use bsearch to find include file.
552 (xcoff_initialize_fileline): Sort include file information.
553
554 2018-01-16 Ian Lance Taylor <iant@golang.org>
555
556 * elf.c (codes) [GENERATE_FIXED_HUFFMAN_TABLE]: Fix size to be
557 288.
558 (main) [GENERATE_FIXED_HUFFMAN_TABLE]: Pass 288 to
559 elf_zlib_inflate_table. Generate elf_zlib_default_dist_table.
560 (elf_zlib_default_table): Update.
561 (elf_zlib_default_dist_table): New static array.
562 (elf_zlib_inflate): Use elf_zlib_default_dist_table for dist table
563 for block type 1.
564 * ztest.c (struct zlib_test): Add uncompressed_len.
565 (tests): Initialize uncompressed_len field. Add new test case.
566 (test_samples): Use uncompressed_len field.
567
568 2018-01-03 Jakub Jelinek <jakub@redhat.com>
569
570 Update copyright years.
571
572 2017-11-17 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
573
574 * configure.ac: Add CET_FLAGS to EXTRA_FLAGS.
575 * aclocal.m4: Regenerate.
576 * Makefile.in: Likewise.
577 * configure: Likewise.
578
579 2017-10-06 Ian Lance Taylor <iant@golang.org>
580
581 * ztest.c (test_large): Pass unsigned long *, not size_t *, to
582 zlib uncompress function.
583
584 2017-10-05 Ian Lance Taylor <iant@golang.org>
585
586 * elf.c (elf_zlib_fetch): Change pval argument to uint64_t *.
587 Read a four byte integer.
588 (elf_zlib_inflate): Change val to uint64_t. Align pin to a 32-bit
589 boundary before ever calling elf_zlib_fetch.
590 * ztest.c (test_large): Simplify print statements a bit.
591
592 2017-10-02 Ian Lance Taylor <iant@golang.org>
593
594 * ztest.c: #include <errno.h>.
595 (TEST_TIMING): Don't define, don't test.
596 (xclock_gettime, xclockid_t): Define if !HAVE_CLOCK_GETTIME.
597 (clockid_t, clock_gettime, CLOCK_REALTIME): Likewise.
598 (ZLIB_CLOCK_GETTIME_ARG): Define.
599 * configure.ac: Change clock_gettime_link to CLOCK_GETTIME_LINK.
600 * Makefile.am: Likewise.
601 * configure, Makefile.in: Rebuild.
602
603 2017-10-02 Thomas Schwinge <thomas@codesourcery.com>
604
605 PR other/67165
606 * Makefile.am: Append the content of clock_gettime_link to
607 ztest_LDADD.
608 * configure.ac: Test for the case that clock_gettime is in librt.
609 * Makefile.in: Regenerate.
610 * configure: Likewise.
611
612 PR other/67165
613 * configure.ac: Check for clock_gettime.
614 * config.h.in: Regenerate.
615 * configure: Likewise.
616 * ztest.c (average_time, test_large): Conditionalize test timing
617 on clock_gettime availability.
618
619 2017-09-29 Tony Reix <tony.reix@atos.net>
620
621 * xcoff.c: Initial support for DWARF debug sections in XCOFF.
622 (STYP_DWARF, SSUBTYP_DW*): Define.
623 (enum dwarf_section): Define.
624 (struct dwsect_info): Define.
625 (xcoff_add): Look for DWARF sections, pass them to
626 backtrace_dwarf_add.
627
628 2017-09-28 Ian Lance Taylor <iant@golang.org>
629
630 PR other/67165
631 * elf.c (__builtin_prefetch): Define if not __GNUC__.
632 (unlikely): Define.
633 (SHF_UNCOMPRESSED, ELFCOMPRESS_ZLIB): Define.
634 (b_elf_chdr): Define type.
635 (enum debug_section): Add ZDEBUG_xxx values.
636 (debug_section_names): Add names for new sections.
637 (struct debug_section_info): Add compressed field.
638 (elf_zlib_failed, elf_zlib_fetch): New static functions.
639 (HUFFMAN_TABLE_SIZE, HUFFMAN_VALUE_MASK): Define.
640 (HUFFMAN_BITS_SHIFT, HUFFMAN_BITS_MASK): Define.
641 (HUFFMAN_SECONDARY_SHIFT): Define.
642 (ZDEBUG_TABLE_SIZE): Define.
643 (ZDEBUG_TABLE_CODELEN_OFFSET, ZDEBUG_TABLE_WORK_OFFSET): Define.
644 (final_next_secondary): New static variable if
645 BACKTRACE_GENERATE_FIXED_HUFFMAN_TABLE.
646 (elf_zlib_inflate_table): New static function.
647 (BACKTRACE_GENERATE_FIXED_HUFFMAN_TABLE): If define, define main
648 function to produce fixed Huffman table.
649 (elf_zlib_default_table): New static variable.
650 (elf_zlib_inflate): New static function.
651 (elf_zlib_verify_checksum): Likewise.
652 (elf_zlib_inflate_and_verify): Likewise.
653 (elf_uncompress_zdebug): Likewise.
654 (elf_uncompress_chdr): Likewise.
655 (backtrace_uncompress_zdebug): New extern function.
656 (elf_add): Look for .zdebug sections and SHF_COMPRESSED debug
657 sections, and uncompress them.
658 * internal.h (backtrace_compress_zdebug): Declare.
659 * ztest.c: New file.
660 * configure.ac: Check for -lz and check whether the linker
661 supports --compress-debug-sections.
662 * Makefile.am (ztest_SOURCES): New variable.
663 (ztest_CFLAGS, ztest_LDADD): New variables.
664 (check_PROGRAMS): Add ztest.
665 (ctestg_SOURCES): New variable.
666 (ctestg_CFLAGS, ctestg_LDFLAGS, ctestg_LDADD): New variables.
667 (ctesta_SOURCES): New variable.
668 (ctesta_CFLAGS, ctesta_LDFLAGS, ctesta_LDADD): New variables.
669 (check_PROGRAMS): Add ctestg and ctesta.
670 * configure, config.h.in, Makefile.in: Rebuild.
671
672 2017-09-22 Ian Lance Taylor <iant@golang.org>
673
674 PR sanitizer/77631
675 * configure.ac: Check for lstat and readlink.
676 * elf.c (lstat, readlink): Provide dummy versions if real versions
677 are not available.
678 * configure, config.h.in: Rebuild.
679
680 2017-09-21 Ian Lance Taylor <iant@google.com>
681
682 PR go/82284
683 * elf.c (backtrace_initialize): Set pd.exe_filename.
684
685 2017-09-20 Ian Lance Taylor <iant@golang.org>
686 Denis Khalikov <d.khalikov@partner.samsung.com>
687
688 PR sanitizer/77631
689 Support for external debug info.
690 * elf.c: Include <errno.h>, <sys/stat.h>, <unistd.h>.
691 (S_ISLNK): Define if not defined.
692 (xstrnlen): Define if strnlen is not available.
693 (b_elf_note): Define type.
694 (NT_GNU_BUILD_ID): Define macro.
695 (elf_crc32, elf_crc32_file): New static functions.
696 (elf_is_symlink, elf_readlink): New static functions.
697 (elf_open_debugfile_by_buildid): New static function.
698 (elf_try_debugfile): New static function.
699 (elf_find_debugfile_by_debuglink): New static function.
700 (elf_open_debugfile_by_debuglink): New static function.
701 (elf_add): Add filename and debuginfo parameters. Adjust all
702 callers. Look for external debug info notes, and try to fetch
703 debug info from external file.
704 (struct phdr_data): Add exe_filename field.
705 (phdr_callback): Pass filename to elf_add.
706 (backtrace_initialize): Add filename parameter.
707 * internal.h (backtrace_initialize): Add filename parameter.
708 * fileline.c (fileline_initialize): Pass filename to
709 backtrace_initialize.
710 * pecoff.c (fileline_initialize): Add unused filename parameter.
711 * unknown.c (fileline_initialize): Likewise.
712 * xcoff.c (fileline_initialize): Likewise.
713 * configure.ac: Check for objcopy --add-gnu-debuglink.
714 * Makefile.am (dtest): New test target.
715 * configure, Makefile.in: Rebuild.
716
717 2017-09-12 Steve Ellcey <sellcey@cavium.com>
718
719 PR other/81096
720 * Makefile.am (ttest_CFLAGS): Add $(AM_CFLAGS)
721 * Makefile.in: Regenerate.
722
723 2017-09-12 Steve Ellcey <sellcey@cavium.com>
724
725 PR other/81096
726 * libbacktrace/Makefile.in
727 (HAVE_PTHREAD_TRUE@@NATIVE_TRUE@ttest_CFLAGS): Add $(AM_CFLAGS)
728
729 2017-08-02 David Edelsohn <dje.gcc@gmail.com>
730
731 PR bootstrap/81638
732 * xcoff.c (xcoff_process_linenos): Initialize incl to NULL.
733
734 2017-07-28 Tony Reix <tony.reix@atos.net>
735
736 * xcoff.c: Don't leak a file descriptor if an archive is malformed.
737
738 2017-07-28 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
739
740 * fileline.c (fileline_initialize): Print pid_t as long.
741
742 2017-07-26 Tony Reix <tony.reix@atos.net>
743
744 * configure.ac: Check for XCOFF32/XCOFF64. Check for loadquery.
745 * filetype.awk: Separate AIX XCOFF32 and XCOFF64.
746 * xcoff.c: Add support for AIX XCOFF32 and XCOFF64 formats.
747 * configure, config.h.in: Regenerate.
748
749 2017-07-21 Tony Reix <tony.reix@atos.net>
750
751 * filetype.awk: Add AIX XCOFF type detection.
752 * configure.ac: Recognize xcoff format.
753 * Makefile.am (FORMAT_FILES): Add xcoff.c.
754 * fileline.c: Include <unistd.h>.
755 (fileline_initialize): Add case for AIX procfs.
756 * xcoff.c: New file.
757 * configure, Makefile.in: Rebuild.
758
759 2017-06-21 Richard Biener <rguenther@suse.de>
760
761 * configure.ac: Add AC_SYS_LARGEFILE.
762 * config.h.in: Regenerate.
763 * configure: Likewise.
764
765 2017-06-11 Ian Lance Taylor <iant@golang.org>
766
767 * elf.c (backtrace_initialize): Always set *fileline_fn.
768 * ttest.c: New file.
769 * btest.c: Move support functions into testlib.c. Change calls to
770 check to pass file name.
771 * testlib.c: New file, copied from (part of) btest.c.
772 * testlib.h: New file, declarations for testlib.c.
773 * edtest.c: Use testlib.h and testlib.c.
774 * configure.ac: Test for -pthread, set HAVE_PTHREAD conditional.
775 * Makefile.am (btest_SOURCES): Add testlib.c.
776 (edtest_SOURCES): Likewise.
777 (CHECK_PROGRAMS): Add ttest if HAVE_PTHREAD.
778 (ttest_SOURCES, ttest_CFLAGS, ttest_LDADD): Define.
779 * configure, Makefile.in: Rebuild.
780
781 2017-05-19 Than McIntosh <thanm@google.com>
782
783 * dwarf.c (free_line_header): Don't free dirs if dirs_count == 0.
784 (read_line_header): Don't allocate dirs if dirs_count == 0.
785 * edtest.c: New file.
786 * edtest2.c: New file.
787 * Makefile.am (edtest_SOURCES, edtest_LDADD): Define.
788 (check_PROGRAMS): Add edtest.
789 (edtest2_build.c, gen_edtest2_build): New targets.
790 * Makefile.in: Rebuild.
791
792 2017-03-08 Sam Thursfield <sam.thursfield@codethink.co.uk>
793
794 * btest.c (test5): Replace #ifdef guard with 'unused' attribute
795 to fix compile warning when BACKTRACE_SUPPORTED isn't defined.
796
797 2017-01-01 Jakub Jelinek <jakub@redhat.com>
798
799 Update copyright years.
800
801 2016-11-15 Matthias Klose <doko@ubuntu.com>
802
803 * configure: Regenerate.
804
805 2016-09-11 Carlos Liam <carlos@aarzee.me>
806
807 * all: Remove meaningless trailing whitespace.
808
809 2016-05-18 Uros Bizjak <ubizjak@gmail.com>
810
811 PR target/71161
812 * elf.c (phdr_callback) [__i386__]: Add
813 __attribute__((__force_align_arg_pointer__)).
814
815 2016-03-02 Maxim Ostapenko <m.ostapenko@partner.samsung.com>
816
817 * elf.c (backtrace_initialize): Properly initialize elf_fileline_fn to
818 avoid possible crash.
819 (elf_add): Don't set *fileline_fn to elf_nodebug value in case of
820 missing debug info anymore.
821
822 2016-02-06 John David Anglin <danglin@gcc.gnu.org>
823
824 * mmap.c (MAP_FAILED): Define if not defined.
825
826 2016-01-04 Jakub Jelinek <jakub@redhat.com>
827
828 Update copyright years.
829
830 2015-12-18 Andris Pavenis <andris.pavenis@iki.fi>
831
832 * configure.ac: Specify that DJGPP do not have mmap
833 even when sys/mman.h exists.
834 * configure: Regenerate
835
836 2015-12-09 John David Anglin <danglin@gcc.gnu.org>
837
838 PR libgfortran/68115
839 * configure.ac: Set libbacktrace_cv_sys_sync to no on hppa*-*-hpux*.
840 * configure: Regenerate.
841 * elf.c (backtrace_initialize): Cast __sync_bool_compare_and_swap call
842 to void.
843
844 2015-09-17 Ian Lance Taylor <iant@google.com>
845
846 * posix.c (backtrace_open): Cast second argument of open() to int.
847
848 2015-09-11 Ian Lance Taylor <iant@google.com>
849
850 * Makefile.am (backtrace.lo): Depend on internal.h.
851 (sort.lo, stest.lo): Add explicit dependencies.
852 * Makefile.in: Rebuild.
853
854 2015-09-09 Hans-Peter Nilsson <hp@axis.com>
855
856 * backtrace.c: #include <sys/types.h>.
857
858 2015-09-08 Ian Lance Taylor <iant@google.com>
859
860 PR other/67457
861 * backtrace.c: #include "internal.h".
862 (struct backtrace_data): Add can_alloc field.
863 (unwind): If can_alloc is false, don't try to get file/line
864 information.
865 (backtrace_full): Set can_alloc field in bdata.
866 * alloc.c (backtrace_alloc): Don't call error_callback if it is
867 NULL.
868 * mmap.c (backtrace_alloc): Likewise.
869 * internal.h: Update comments for backtrace_alloc and
870 backtrace_free.
871
872 2015-09-08 Ian Lance Taylor <iant@google.com>
873
874 PR other/67457
875 * mmap.c (backtrace_alloc): Correct test for mmap failure.
876
877 2015-08-31 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
878
879 * configure.ac: For spu-*-* targets, set have_fcntl to no.
880 * configure: Regenerate.
881
882 2015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
883
884 * configure.ac: Remove [disable-shared] argument to LT_INIT.
885 Remove setting PIC_FLAG when building as target library.
886 * configure: Regenerate.
887
888 2015-08-26 Hans-Peter Nilsson <hp@axis.com>
889
890 * configure.ac: Only compile with -fPIC if the target
891 supports it.
892 * configure: Regenerate.
893
894 2015-08-24 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
895
896 * configure.ac: Set have_mmap to no on spu-*-* targets.
897 * configure: Regenerate.
898
899 2015-08-13 Ian Lance Taylor <iant@google.com>
900
901 * dwarf.c (read_function_entry): Add vec_inlined parameter.
902 Change all callers.
903
904 2015-06-11 Martin Sebor <msebor@redhat.com>
905
906 PR sanitizer/65479
907 * dwarf.c (struct line): Add new field idx.
908 (line_compare): Use it.
909 (add_line): Set it.
910 (read_line_info): Reset it.
911
912 2015-05-29 Tristan Gingold <gingold@adacore.com>
913
914 * pecoff.c: New file.
915 * Makefile.am (FORMAT_FILES): Add pecoff.c and dependencies.
916 * Makefile.in: Regenerate.
917 * filetype.awk: Detect pecoff.
918 * configure.ac: Define BACKTRACE_SUPPORTS_DATA on elf platforms.
919 Add pecoff.
920 * btest.c (test5): Test enabled only if BACKTRACE_SUPPORTS_DATA is
921 true.
922 * backtrace-supported.h.in (BACKTRACE_SUPPORTS_DATA): Define.
923 * configure: Regenerate.
924 * pecoff.c: New file.
925
926 2015-05-13 Michael Haubenwallner <michael.haubenwallner@ssi-schaefer.com>
927
928 * Makefile.in: Regenerated with automake-1.11.6.
929 * aclocal.m4: Likewise.
930 * configure: Likewise.
931
932 2015-01-24 Matthias Klose <doko@ubuntu.com>
933
934 * configure.ac: Move AM_ENABLE_MULTILIB before AC_PROG_CC.
935 * configure: Regenerate.
936
937 2015-01-05 Jakub Jelinek <jakub@redhat.com>
938
939 Update copyright years.
940
941 2014-11-21 H.J. Lu <hongjiu.lu@intel.com>
942
943 PR bootstrap/63784
944 * configure: Regenerated.
945
946 2014-11-11 David Malcolm <dmalcolm@redhat.com>
947
948 * ChangeLog.jit: New.
949
950 2014-11-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
951
952 PR target/63610
953 * configure: Regenerate.
954
955 2014-10-23 Ian Lance Taylor <iant@google.com>
956
957 * internal.h (backtrace_atomic_load_pointer) [no atomic or sync]:
958 Fix to return void *.
959
960 2014-05-08 Ian Lance Taylor <iant@google.com>
961
962 * mmap.c (backtrace_free): If freeing a large aligned block of
963 memory, call munmap rather than holding onto it.
964 (backtrace_vector_grow): When growing a vector, double the number
965 of pages requested. When releasing the old version of a grown
966 vector, pass the correct size to backtrace_free.
967
968 2014-03-07 Ian Lance Taylor <iant@google.com>
969
970 * sort.c (backtrace_qsort): Use middle element as pivot.
971
972 2014-03-06 Ian Lance Taylor <iant@google.com>
973
974 * sort.c: New file.
975 * stest.c: New file.
976 * internal.h (backtrace_qsort): Declare.
977 * dwarf.c (read_abbrevs): Call backtrace_qsort instead of qsort.
978 (read_line_info, read_function_entry): Likewise.
979 (read_function_info, build_dwarf_data): Likewise.
980 * elf.c (elf_initialize_syminfo): Likewise.
981 * Makefile.am (libbacktrace_la_SOURCES): Add sort.c.
982 (stest_SOURCES, stest_LDADD): Define.
983 (check_PROGRAMS): Add stest.
984
985 2014-02-07 Misty De Meo <misty@brew.sh>
986
987 PR target/58710
988 * configure.ac: Use AC_LINK_IFELSE in check for
989 _Unwind_GetIPInfo.
990 * configure: Regenerate.
991
992 2014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
993
994 Update copyright years
995
996 2013-12-06 Jakub Jelinek <jakub@redhat.com>
997
998 * elf.c (ET_DYN): Undefine and define again.
999 (elf_add): Add exe argument, if true and ehdr.e_type is ET_DYN,
1000 return early -1 without closing the descriptor.
1001 (struct phdr_data): Add exe_descriptor.
1002 (phdr_callback): If pd->exe_descriptor is not -1, for very first
1003 call if dlpi_name is NULL just call elf_add with the exe_descriptor,
1004 otherwise backtrace_close the exe_descriptor if not -1. Adjust
1005 call to elf_add.
1006 (backtrace_initialize): Adjust call to elf_add. If it returns
1007 -1, set pd.exe_descriptor to descriptor, otherwise set it to -1.
1008
1009 2013-12-05 Ian Lance Taylor <iant@google.com>
1010
1011 * alloc.c (backtrace_vector_finish): Add error_callback and data
1012 parameters. Call backtrace_vector_release. Return address base.
1013 * mmap.c (backtrace_vector_finish): Add error_callback and data
1014 parameters. Return address base.
1015 * dwarf.c (read_function_info): Get new address base from
1016 backtrace_vector_finish.
1017 * internal.h (backtrace_vector_finish): Update declaration.
1018
1019 2013-11-27 Ian Lance Taylor <iant@google.com>
1020
1021 * dwarf.c (find_address_ranges): New static function, broken out
1022 of build_address_map.
1023 (build_address_map): Call it.
1024 * btest.c (check): Check for missing filename or function, rather
1025 than crashing.
1026 (f3): Check that enough frames were returned.
1027
1028 2013-11-19 Jakub Jelinek <jakub@redhat.com>
1029
1030 * backtrace.h (backtrace_syminfo_callback): Add symsize argument.
1031 * elf.c (elf_syminfo): Pass 0 or sym->size to the callback as
1032 last argument.
1033 * btest.c (struct symdata): Add size field.
1034 (callback_three): Add symsize argument. Copy it to the data->size
1035 field.
1036 (f23): Set symdata.size to 0.
1037 (test5): Likewise. If sizeof (int) > 1, lookup address of
1038 ((uintptr_t) &global) + 1. Verify symdata.val and symdata.size
1039 values.
1040
1041 * atomic.c: Include sys/types.h.
1042
1043 2013-11-18 Ian Lance Taylor <iant@google.com>
1044
1045 * configure.ac: Check for support of __atomic extensions.
1046 * internal.h: Declare or #define atomic functions for use in
1047 backtrace code.
1048 * atomic.c: New file.
1049 * dwarf.c (dwarf_lookup_pc): Use atomic functions.
1050 (dwarf_fileline, backtrace_dwarf_add): Likewise.
1051 * elf.c (elf_add_syminfo_data, elf_syminfo): Likewise.
1052 (backtrace_initialize): Likewise.
1053 * fileline.c (fileline_initialize): Likewise.
1054 * Makefile.am (libbacktrace_la_SOURCES): Add atomic.c.
1055 * configure, config.h.in, Makefile.in: Rebuild.
1056
1057 2013-11-18 Jakub Jelinek <jakub@redhat.com>
1058
1059 * elf.c (SHN_UNDEF): Define.
1060 (elf_initialize_syminfo): Add base_address argument. Ignore symbols
1061 with st_shndx == SHN_UNDEF. Add base_address to address fields.
1062 (elf_add): Adjust caller.
1063
1064 * elf.c (phdr_callback): Process info->dlpi_addr == 0 normally.
1065
1066 2013-11-16 Ian Lance Taylor <iant@google.com>
1067
1068 * backtrace.h (backtrace_create_state): Correct comment about
1069 threading.
1070
1071 2013-11-15 Ian Lance Taylor <iant@google.com>
1072
1073 * backtrace.h (backtrace_syminfo): Update comment and parameter
1074 name to take any address, not just a PC value.
1075 * elf.c (STT_OBJECT): Define.
1076 (elf_nosyms): Rename parameter pc to addr.
1077 (elf_symbol_search): Rename local variable pc to addr.
1078 (elf_initialize_syminfo): Add STT_OBJECT symbols to elf_symbols.
1079 (elf_syminfo): Rename parameter pc to addr.
1080 * btest.c (global): New global variable.
1081 (test5): New test.
1082 (main): Call test5.
1083
1084 2013-10-17 Ian Lance Taylor <iant@google.com>
1085
1086 * elf.c (elf_add): Don't get the wrong offsets if a debug section
1087 is missing.
1088
1089 2013-10-15 David Malcolm <dmalcolm@redhat.com>
1090
1091 * configure.ac: Add --enable-host-shared, setting up
1092 pre-existing PIC_FLAG variable within Makefile.am et al.
1093 * configure: Regenerate.
1094
1095 2013-09-20 Alan Modra <amodra@gmail.com>
1096
1097 * configure: Regenerate.
1098
1099 2013-07-23 Alexander Monakov <amonakov@ispras.ru>
1100
1101 * elf.c (elf_syminfo): Loop over the elf_syminfo_data chain.
1102
1103 2013-07-23 Alexander Monakov <amonakov@ispras.ru>
1104
1105 * elf.c (backtrace_initialize): Pass elf_fileline_fn to
1106 dl_iterate_phdr callbacks.
1107
1108 2013-03-25 Ian Lance Taylor <iant@google.com>
1109
1110 * alloc.c: #include <sys/types.h>.
1111 * mmap.c: Likewise.
1112
1113 2013-01-31 Ian Lance Taylor <iant@google.com>
1114
1115 * dwarf.c (read_function_info): Permit fvec parameter to be NULL.
1116 (dwarf_lookup_pc): Don't use ddata->fvec if threaded.
1117
1118 2013-01-25 Jakub Jelinek <jakub@redhat.com>
1119
1120 PR other/56076
1121 * dwarf.c (read_line_header): Don't crash if DW_AT_comp_dir
1122 attribute was not seen.
1123
1124 2013-01-16 Ian Lance Taylor <iant@google.com>
1125
1126 * dwarf.c (struct unit): Add filename and abs_filename fields.
1127 (build_address_map): Set new fields when reading unit.
1128 (dwarf_lookup_pc): If we don't find an entry in the line table,
1129 just return the main file name.
1130
1131 2013-01-14 Richard Sandiford <rdsandiford@googlemail.com>
1132
1133 Update copyright years.
1134
1135 2013-01-01 Ian Lance Taylor <iant@google.com>
1136
1137 PR bootstrap/54834
1138 * Makefile.am (AM_CPPFLAGS): Remove -I ../gcc/include and -I
1139 $(MULTIBUILDTOP)/../../gcc/include.
1140 * Makefile.in: Rebuild.
1141
1142 2013-01-01 Ian Lance Taylor <iant@google.com>
1143
1144 PR other/55536
1145 * mmap.c (backtrace_alloc): Don't call sync functions if not
1146 threaded.
1147 (backtrace_free): Likewise.
1148
1149 2012-12-12 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
1150
1151 * mmapio.c: Define MAP_FAILED if not defined.
1152
1153 2012-12-11 Jakub Jelinek <jakub@redhat.com>
1154
1155 PR bootstrap/54926
1156 * Makefile.am (AM_CFLAGS): Remove -frandom-seed=$@.
1157 * configure.ac: If --with-target-subdir, add -frandom-seed=$@
1158 to EXTRA_FLAGS unconditionally, otherwise check whether the compiler
1159 accepts it.
1160 * Makefile.in: Regenerated.
1161 * configure: Regenerated.
1162
1163 2012-12-07 Jakub Jelinek <jakub@redhat.com>
1164
1165 PR bootstrap/54926
1166 * Makefile.am (AM_CFLAGS): Add -frandom-seed=$@.
1167 * Makefile.in: Regenerated.
1168
1169 2012-11-20 Ian Lance Taylor <iant@google.com>
1170
1171 * dwarf.c (read_attribute): Always clear val.
1172
1173 2012-11-13 Ian Lance Taylor <iant@google.com>
1174
1175 PR other/55312
1176 * configure.ac: Only add -Werror if building a target library.
1177 * configure: Rebuild.
1178
1179 2012-11-12 Ian Lance Taylor <iant@google.com>
1180 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1181 Gerald Pfeifer <gerald@pfeifer.com>
1182
1183 * configure.ac: Check for getexecname.
1184 * fileline.c: #include <errno.h>. Define getexecname if not
1185 available.
1186 (fileline_initialize): Try to find the executable in a few
1187 different ways.
1188 * print.c (error_callback): Only print the filename if it came
1189 from the backtrace state.
1190 * configure, config.h.in: Rebuild.
1191
1192 2012-10-29 Ian Lance Taylor <iant@google.com>
1193
1194 * mmap.c (backtrace_vector_release): Correct last patch: add
1195 aligned, not size.
1196
1197 2012-10-29 Ian Lance Taylor <iant@google.com>
1198
1199 * mmap.c (backtrace_vector_release): Make sure freed block is
1200 aligned on 8-byte boundary.
1201
1202 2012-10-26 Ian Lance Taylor <iant@google.com>
1203
1204 PR other/55087
1205 * posix.c (backtrace_open): Add does_not_exist parameter.
1206 * elf.c (phdr_callback): Do not warn if shared library could not
1207 be opened.
1208 * fileline.c (fileline_initialize): Update calls to
1209 backtrace_open.
1210 * internal.h (backtrace_open): Update declaration.
1211
1212 2012-10-26 Jack Howarth <howarth@bromo.med.uc.edu>
1213
1214 PR target/55061
1215 * configure.ac: Check for _Unwind_GetIPInfo function declaration.
1216 * configure: Regenerate.
1217
1218 2012-10-24 Ian Lance Taylor <iant@google.com>
1219
1220 PR target/55061
1221 * configure.ac: Check whether -funwind-tables option works.
1222 * configure: Rebuild.
1223
1224 2012-10-11 Ian Lance Taylor <iant@google.com>
1225
1226 * configure.ac: Do not use dl_iterate_phdr on Solaris 10.
1227 * configure: Rebuild.
1228
1229 2012-10-10 Ian Lance Taylor <iant@google.com>
1230
1231 * elf.c: Rename all Elf typedefs to start with b_elf, and be all
1232 lower case.
1233
1234 2012-10-10 Hans-Peter Nilsson <hp@bitrange.com>
1235
1236 * elf.c (elf_add_syminfo_data): Add casts to avoid warning.
1237
1238 2012-10-09 Ian Lance Taylor <iant@google.com>
1239
1240 * dwarf.c (dwarf_fileline): Add cast to avoid warning.
1241 (backtrace_dwarf_add): Likewise.
1242
1243 2012-10-09 Ian Lance Taylor <iant@google.com>
1244
1245 Add support for tracing through shared libraries.
1246 * configure.ac: Check for link.h and dl_iterate_phdr.
1247 * elf.c: #include <link.h> if system has dl_iterate_phdr. #undef
1248 ELF macros before #defining them.
1249 (dl_phdr_info, dl_iterate_phdr): Define if system does not have
1250 dl_iterate_phdr.
1251 (struct elf_syminfo_data): Add next field.
1252 (elf_initialize_syminfo): Initialize next field.
1253 (elf_add_syminfo_data): New static function.
1254 (elf_add): New static function, broken out of
1255 backtrace_initialize. Call backtrace_dwarf_add instead of
1256 backtrace_dwarf_initialize.
1257 (struct phdr_data): Define.
1258 (phdr_callback): New static function.
1259 (backtrace_initialize): Call elf_add.
1260 * dwarf.c (struct dwarf_data): Add next and base_address fields.
1261 (add_unit_addr): Add base_address parameter. Change all callers.
1262 (add_unit_ranges, build_address_map): Likewise.
1263 (add_line): Add ddata parameter. Change all callers.
1264 (read_line_program, add_function_range): Likewise.
1265 (dwarf_lookup_pc): New static function, broken out of
1266 dwarf_fileline.
1267 (dwarf_fileline): Call dwarf_lookup_pc.
1268 (build_dwarf_data): New static function.
1269 (backtrace_dwarf_add): New function.
1270 (backtrace_dwarf_initialize): Remove.
1271 * internal.h (backtrace_dwarf_initialize): Don't declare.
1272 (backtrace_dwarf_add): Declare.
1273 * configure, config.h.in: Rebuild.
1274
1275 2012-10-04 Gerald Pfeifer <gerald@pfeifer.com>
1276
1277 * btest.c (f23): Avoid uninitialized variable warning.
1278
1279 2012-10-04 Ian Lance Taylor <iant@google.com>
1280
1281 * dwarf.c: If the system header files do not declare strnlen,
1282 provide our own version.
1283
1284 2012-10-03 Ian Lance Taylor <iant@google.com>
1285
1286 * dwarf.c (read_uleb128): Fix overflow test.
1287 (read_sleb128): Likewise.
1288 (build_address_map): Don't change unit_buf.start.
1289
1290 2012-10-02 Uros Bizjak <ubizjak@gmail.com>
1291
1292 PR other/54761
1293 * configure.ac (EXTRA_FLAGS): New.
1294 * Makefile.am (AM_FLAGS): Add $(EXTRA_FLAGS).
1295 * configure, Makefile.in: Regenerate.
1296
1297 2012-09-29 Ian Lance Taylor <iant@google.com>
1298
1299 PR other/54749
1300 * fileline.c (fileline_initialize): Pass errnum as -1 when
1301 reporting that we could not read executable information after a
1302 previous failure.
1303
1304 2012-09-27 Ian Lance Taylor <iant@google.com>
1305
1306 PR bootstrap/54732
1307 * configure.ac: Add no-dependencies to AM_INIT_AUTOMAKE.
1308 * Makefile.am: Add dependencies for all objects.
1309 * configure, aclocal.m4, Makefile.in: Rebuild.
1310
1311 2012-09-27 Ian Lance Taylor <iant@google.com>
1312
1313 PR other/54726
1314 * elf.c (backtrace_initialize): Set *fileln_fn, not
1315 state->fileln_fn.
1316
1317 2012-09-19 Ian Lance Taylor <iant@google.com>
1318
1319 * configure.ac: Only use GCC_CHECK_UNWIND_GETIPINFO when compiled
1320 as a target library.
1321 * configure: Rebuild.
1322
1323 2012-09-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1324 Ian Lance Taylor <iant@google.com>
1325
1326 * configure.ac (GCC_HEADER_STDINT): Invoke.
1327 * backtrace.h: If we can't find <stdint.h>, use "gstdint.h".
1328 * btest.c: Don't include <stdint.h>.
1329 * dwarf.c: Likewise.
1330 * configure, aclocal.m4, Makefile.in, config.h.in: Rebuild.
1331
1332 2012-09-18 Ian Lance Taylor <iant@google.com>
1333
1334 PR bootstrap/54623
1335 * Makefile.am (AM_CPPFLAGS): Define.
1336 (AM_CFLAGS): Remove -I options.
1337 * Makefile.in: Rebuild.
1338
1339 2012-09-18 Ian Lance Taylor <iant@google.com>
1340
1341 * posix.c (O_BINARY): Define if not defined.
1342 (backtrace_open): Pass O_BINARY to open. Only call fcntl if
1343 HAVE_FCNTL is defined.
1344 * configure.ac: Test for the fcntl function.
1345 * configure, config.h.in: Rebuild.
1346
1347 2012-09-18 Ian Lance Taylor <iant@google.com>
1348
1349 * btest.c (test1, test2, test3, test4): Add the unused attribute.
1350
1351 2012-09-18 Ian Lance Taylor <iant@google.com>
1352
1353 * dwarf.c: Correct test of HAVE_DECL_STRNLEN.
1354
1355 2012-09-18 Ian Lance Taylor <iant@google.com>
1356
1357 * configure.ac: Add AC_USE_SYSTEM_EXTENSIONS.
1358 * mmapio.c: Don't define _GNU_SOURCE.
1359 * configure, config.h.in: Rebuild.
1360
1361 2012-09-18 Ian Lance Taylor <iant@google.com>
1362
1363 * configure.ac: Check whether strnlen is declared.
1364 * dwarf.c: Declare strnlen if not declared.
1365 * configure, config.h.in: Rebuild.
1366
1367 2012-09-18 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1368
1369 * fileline.c: Include <stdlib.h>.
1370 * mmap.c: Likewise.
1371
1372 2012-09-17 Ian Lance Taylor <iant@google.com>
1373
1374 PR bootstrap/54611
1375 * nounwind.c (backtrace_full): Rename from backtrace. Add state
1376 parameter.
1377
1378 2012-09-17 Gerald Pfeifer <gerald@pfeifer.com>
1379
1380 PR bootstrap/54611
1381 * nounwind.c (backtrace_simple): Add state parameter.
1382
1383 2012-09-17 Ian Lance Taylor <iant@google.com>
1384
1385 PR bootstrap/54609
1386 * unknown.c (unknown_fileline): Add state parameter, remove
1387 fileline_data parameter, name error_callback parameter.
1388 (backtrace_initialize): Add state parameter.
1389
1390 2012-09-17 Ian Lance Taylor <iant@google.com>
1391
1392 * Initial implementation.
1393 \f
1394 Copyright (C) 2012-2020 Free Software Foundation, Inc.
1395
1396 Copying and distribution of this file, with or without modification,
1397 are permitted in any medium without royalty provided the copyright
1398 notice and this notice are preserved.