]> git.ipfire.org Git - thirdparty/gcc.git/blame - libbacktrace/ChangeLog
Daily bump.
[thirdparty/gcc.git] / libbacktrace / ChangeLog
CommitLineData
ef1b7885
GA
12024-03-02 Ian Lance Taylor <iant@golang.org>
2
3 * Makefile.am (libbacktrace_testing_ldflags): Define.
4 (*_LDFLAGS): Add $(libbacktrace_testing_ldflags) for test
5 programs.
6 * Makefile.in: Regenerate
7
82024-03-02 Ian Lance Taylor <iant@golang.org>
9
10 * elf.c (elf_uncompress_lzma_block): Skip all header padding bytes
11 and verify that they are zero.
12
132024-03-02 Ian Lance Taylor <iant@golang.org>
14
15 PR libbacktrace/114201
16 * elf.c (elf_add): Add caller_opd parameter. Change all callers.
17 Release opd data after all recursive calls.
18
306a4c32
GA
192024-03-01 Ian Lance Taylor <iant@golang.org>
20
21 * elf.c (elf_add): Add the symbol table from a debuginfo file.
22 * Makefile.am (MAKETESTS): Add buildidfull and gnudebuglinkfull
23 variants of buildid and gnudebuglink tests.
24 (%_gnudebuglinkfull, %_buildidfull): New patterns.
25 * Makefile.in: Regenerate.
26
8428bcd7
GA
272023-11-30 Ian Lance Taylor <iant@golang.org>
28
29 * pecoff.c: Include <windows.h> if available.
30 (coff_add): On Windows call GetModuleHandle to get base address.
31
31d8cf17
GA
322023-11-29 Ian Lance Taylor <iant@golang.org>
33
34 * fileline.c: Include <windows.h> if available.
35 (windows_get_executable_path): New static function.
36 (fileline_initialize): Call windows_get_executable_path.
37 * configure.ac: Checked for windows.h
38 * configure: Regenerate.
39 * config.h.in: Regenerate.
40
3b632746
GA
412023-10-22 Iain Sandoe <iain@sandoe.co.uk>
42
43 * configure: Regenerate.
44 * configure.ac: Handle Darwin rpaths.
45
4b92dba7
GA
462023-08-07 Nick Alcock <nick.alcock@oracle.com>
47
48 * configure: Regenerate.
49
502023-08-07 Alexander von Gluck IV <kallisti5@unixzen.com>
51
52 * configure: Regenerate.
53
542023-08-07 Nick Alcock <nick.alcock@oracle.com>
55
56 * configure: Regenerate.
57
582023-08-07 Nick Alcock <nick.alcock@oracle.com>
59
60 * configure: Regenerate.
61
622023-08-07 H.J. Lu <hjl.tools@gmail.com>
63
64 * configure: Regenerate.
65
662023-08-07 H.J. Lu <hjl.tools@gmail.com>
67
68 * configure: Regenerate.
69
86fa4433
GA
702023-08-03 Richard Biener <rguenther@suse.de>
71
72 * zstdtest.c (test_samples): Properly compute the allocation
73 size for the uncompressed data.
74
a2f31d79
GA
752023-07-31 Ian Lance Taylor <iant@golang.org>
76
77 * configure.ac: Check for _pgmptr declaration.
78 * fileline.c (fileline_initialize): Check for _pgmfptr before
79 /proc/self/exec.
80 * configure, config.h.in: Regenerate.
81
579cdc1e
GA
822023-03-28 Ian Lance Taylor <iant@golang.org>
83
84 * elf.c (elf_zstd_read_fse): Call elf_fetch_bits after reading
85 bits, not before. Add unlikely for error case.
86 (elf_zstd_offset_table): Regenerate.
87 (elf_zstd_read_huff): Clear 13 entries in weight_mark, not 12.
88 (elf_zstd_read_literals): For a single stream adjust by
89 total_streams_size, not compressed_size.
90
1bdb1768
GA
912023-01-20 Ian Lance Taylor <iant@golang.org>
92
93 * dwarf.c (struct function_addrs): Change low and high fields to
94 uintptr_t.
95 (struct unit_addrs): Likewise.
96 (resolve_addr_index): Change address parameter to uintptr_t*.
97 (add_unit_addr): Change lowpc and highpc parameters to uintptr_t.
98 (add_function_range): Likewise.
99 (struct pcrange): Change lowpc and highpc fields to uintptr_t.
100 (add_low_high_range): Change add_range lowpc and highpc parameters
101 to uintptr_t.
102 (add_ranges_from_ranges): Likewise.
103 (add_ranges_from_rnglists): Likewise.
104 (add_low_high_range): Chnage lowpc and highpc variables to
105 uintpr_t.
106 (add_ranges_from_rnglists): Change some local variables to
107 uintptr_t.
108 (add_ranges_from_ranges): Change base parameter to uintptr_t.
109 (add_ranges_from_rnglists): Likewise.
110 (read_function_entry): Likewise.
111 (resolve_addr_index): Add explicit casts to uintptr_t.
112 (update_pcrange): Likewise.
113 (add_ranges_from_ranges): Likewise.
114 (add_ranges_from_rnglists): Likewise.
115 (read_function_entry): Likewise.
116
8d07b193
GA
1172023-01-17 Martin Liska <mliska@suse.cz>
118
119 * Makefile.in: Regenerate.
120
d808db1f
GA
1212023-01-06 Ian Lance Taylor <iant@golang.org>
122
123 PR libbacktrace/108297
124 * configure.ac: Test whether linker supports --build-id.
125 * Makefile.am: Only run --build-id tests if supported.
126 * configure, Makefile.in: Regenerate.
127
92bc3617
GA
1282022-12-17 Ian Lance Taylor <iant@golang.org>
129
130 * elf.c (elf_fetch_backward_init): New static function.
131 (ZSTD_TABLE_SIZE): Use huffman scratch space size rather than
132 literal size.
133 (ZSTD_TABLE_WORK_LIT_SIZE): Don't define.
134 (elf_zstd_read_huff): Use elf_fetch_backward_init.
135 (elf_zstd_read_literals): New static function.
136 (ZSTD_LIT_RAW, ZSTD_LIT_RLE, ZSTD_LIT_HUFF): Don't define.
137 (struct elf_zstd_literals): Don't define.
138 (elf_zstd_literal_output): Remove static function.
139 (elf_zstd_decompress): Use elf_fetch_backward_init and
140 elf_zstd_read_literals. Rewrite literal copying.<
141
c6b12b80
GA
1422022-12-10 Ian Lance Taylor <iant@golang.org>
143
144 * elf.c (ZSTD_TABLE_*): Use elf_zstd_fse_baseline_entry.
145 (ZSTD_ENCODE_BASELINE_BITS): Define.
146 (ZSTD_DECODE_BASELINE, ZSTD_DECODE_BASEBITS): Define.
147 (elf_zstd_literal_length_base): New static const array.
148 (elf_zstd_match_length_base): Likewise.
149 (struct elf_zstd_fse_baseline_entry): Define.
150 (elf_zstd_make_literal_baseline_fse): New static function.
151 (elf_zstd_make_offset_baseline_fse): Likewise.
152 (elf_zstd_make_match_baseline_fse): Likewise.
153 (print_table, main): Use elf_zstd_fse_baseline_entry.
154 (elf_zstd_lit_table, elf_zstd_match_table): Likewise.
155 (elf_zstd_offset_table): Likewise.
156 (struct elf_zstd_seq_decode): Likewise. Remove use_rle and rle
157 fields.
158 (elf_zstd_unpack_seq_decode): Use elf_zstd_fse_baseline_entry,
159 taking a conversion function. Convert RLE to FSE.
160 (elf_zstd_literal_length_baseline): Remove.
161 (elf_zstd_literal_length_bits): Remove.
162 (elf_zstd_match_length_baseline): Remove.
163 (elf_zstd_match_length_bits): Remove.
164 (elf_zstd_decompress): Use elf_zstd_fse_baseline_entry. Rewrite
165 and simplify main loop.
166
e6110da4
GA
1672022-12-08 Ian Lance Taylor <iant@golang.org>
168
169 * configure.ac: Check for zstd library and
170 --compress-debug-sections=zstd linker option.
171 * Makefile.am (zstdtest_*): New targets.
172 (zstdtest_alloc_*, ctestzstd_*): New targets.
173 (BUILDTESTS): Add zstdtest, zstdtest_alloc, ctestzstd as
174 appropriate.
175 * elf.c (ELFCOMPRESS_ZSTD): Define.
176 (elf_fetch_bits): Rename from elf_zlib_fetch. Update uses.
177 (elf_fetch_bits_backward): New static function.
178 (ZLIB_HUFFMAN_*): Rename from HUFFMAN_*. Update uses.
179 (ZLIB_TABLE_*): Rename from ZDEBUG_TABLE_*. Update uses.
180 (ZSTD_TABLE_*): Define.
181 (struct elf_zstd_fse_entry): Define.
182 (elf_zstd_read_fse): New static function.
183 (elf_zstd_build_fse): Likewise.
184 (lit): Define if BACKTRACE_GENERATE_ZSTD_FSE_TABLES.
185 (match, offset, next, print_table, main): Likewise.
186 (elf_zstd_lit_table): New static const array.
187 (elf_zstd_match_table, elf_zstd_offset_table): Likewise.
188 (elf_zstd_read_huff): New static function.
189 (struct elf_zstd_seq_decode): Define.
190 (elf_zstd_unpack_seq_decode): New static function.
191 (ZSTD_LIT_*): Define.
192 (struct elf_zstd_literals): Define.
193 (elf_zstd_literal_output): New static function.
194 (ZSTD_LITERAL_LENGTH_BASELINE_OFFSET): Define.
195 (elf_zstd_literal_length_baseline): New static const array.
196 (elf_zstd_literal_length_bits): Likewise.
197 (ZSTD_MATCH_LENGTH_BASELINE_OFFSET): Define.
198 (elf_zstd_match_length_baseline): New static const array.
199 (elf_zstd_match_length_bits): Likewise.
200 (elf_zstd_decompress): New static function.
201 (ZDEBUG_TABLE_SIZE): New definition.
202 (elf_uncompress_chdr): Support ELF_COMPRESS_ZSTD.
203 (backtrace_uncompress_zstd): New function.
204 (elf_add): Use ZLIB_TABLE_SIZE for zlib-gnu sections.
205 * internal.h (backtrace_uncompress_zstd): Declare.
206 * zstdtest.c: New file.
207 * configure, config.h.in, Makefile.in: Regenerate.
208
781f477a
GA
2092022-10-12 Martin Liska <mliska@suse.cz>
210
211 * configure: Regenerate.
212
ab332cd7
GA
2132022-10-11 Olivier Hainque <hainque@adacore.com>
214 Olivier Hainque <hainque@adacore.com>
215
216 * configure: Regenerate.
217
0fe604a2
GA
2182022-07-08 Ian Lance Taylor <iant@golang.org>
219
220 * configure.ac: Check for sys/link.h. Use either link.h or
221 sys/link.h when checking for dl_iterate_phdr.
222 * elf.c: Include sys/link.h if available.
223 * configure, config.h.in: Regenerate.
224
6345c414
GA
2252022-07-07 Ian Lance Taylor <iant@golang.org>
226
227 * macho.c (backtrace_initialize) [HAVE_MACH_O_DYLD_H]: Don't exit
228 loop if we can't find debug info for one shared library.
229
2302022-07-07 Ian Lance Taylor <iant@golang.org>
231
232 * Makefile.am (MAKETESTS): New variable split out of TESTS.
233 (CLEANFILES): Replace TESTS with BUILDTESTS and MAKETESTS.
234 * Makefile.in: Regenerate.
235
9d3dd218
GA
2362022-06-27 Ian Lance Taylor <iant@golang.org>
237
238 * configure.ac: Use grep instead of fgrep.
239 * configure, Makefile.in: Regenerate.
240
37b3b5da
GA
2412022-05-28 Ian Lance Taylor <iant@golang.org>
242
243 PR libbacktrace/105721
244 * README: Update.
245
9d84ed68
GA
2462022-04-05 Ian Lance Taylor <iant@golang.org>
247
248 * elf.c (elf_zlib_inflate): Don't skip initial aligned byte in
249 uncompressed block.
250
0bdb0498
GA
2512022-02-17 Ian Lance Taylor <iant@golang.org>
252
253 * dwarf.c (find_address_ranges): Handle skeleton units.
254 (read_function_entry): Likewise.
255
cb3afcd2
GA
2562022-02-16 Ian Lance Taylor <iant@golang.org>
257
258 * dwarf.c (build_address_map): Initialize DWARF 5 fields of unit.
259
682ede39
GA
2602022-02-03 David Seifert <soap@gentoo.org>
261 Jakub Jelinek <jakub@redhat.com>
262
263 * configure.ac: Support --disable-werror.
264 * configure: Regenerate.
265
054e57e4
GA
2662021-12-28 Francois-Xavier Coudert <fxcoudert@gmail.com>
267
268 PR libbacktrace/103822
269 * Makefile.am: Fix newline.
270 * Makefile.in: Regenerate.
271
af2852b9
GA
2722021-11-12 Martin Liska <mliska@suse.cz>
273
274 PR libbacktrace/103167
275 * elf.c (elf_uncompress_lzma_block): Cast to unsigned int.
276 (elf_uncompress_lzma): Likewise.
277 * xztest.c (test_samples): memcpy only if v > 0.
278
c2bd5d8a
GA
2792021-10-22 Martin Liska <mliska@suse.cz>
280
281 PR testsuite/102742
282 * btest.c (MIN_DESCRIPTOR): New.
283 (MAX_DESCRIPTOR): Likewise.
284 (check_available_files): Likewise.
285 (check_open_files): Check only file descriptors that
286 were not available at the entry.
287 (main): Call check_available_files.
288
261512fa
GA
2892021-08-13 Sergei Trofimovich <siarheit@google.com>
290
291 * install-debuginfo-for-buildid.sh.in: Force non-localized readelf
292 output with LANG=C.
293
c8abc205
GA
2942021-06-28 Clément Chigot <clement.chigot@atos.net>
295
296 * xcoff.c (SSUBTYP_DWRNGES): New define.
297 (xcoff_add): Use correct XCOFF DWARF section subtype
298 for DEBUG_RANGES. Remove lineoff workaround.
299 Adjust base_address.
300 (xcoff_initialize_syminfo): Adapt to new base_address.
301 (xcoff_lookup_pc): Likewise.
302 (xcoff_initialize_fileline): Likewise.
303
e690396d
GA
3042021-05-03 H.J. Lu <hjl.tools@gmail.com>
305
306 PR bootstrap/99703
307 * configure: Regenerated.
308
f3641ac7
GA
3092021-03-03 Ian Lance Taylor <iant@golang.org>
310
311 * dwarf.c (read_line_program): Don't special case file 0.
312 (read_function_entry): Likewise.
313
d97a92dc
GA
3142021-03-02 Ian Lance Taylor <iant@golang.org>
315
316 PR libbacktrace/98818
317 * dwarf.c (dwarf_buf_error): Add errnum parameter. Change all
318 callers.
319 * backtrace.h: Update backtrace_error_callback comment.
320
fab095da
GA
3212021-02-12 Ian Lance Taylor <iant@golang.org>
322
323 * configure.ac: Check for objcopy --add-gnu-debuglink by using
324 objcopy --help.
325 * configure: Regenerate
326
ef1f8ee6
GA
3272021-01-18 Ian Lance Taylor <iant@golang.org>
328
329 * Makefile.am (%_dwz): If dwz fails, use uncompressed debug info.
330 * Makefile.in: Regenerate.
331 * configure: Regenerate.
332
3332021-01-18 Ian Lance Taylor <iant@golang.org>
334
335 PR debug/98716
336 * dwarf.c (read_v2_paths): Allocate zero entry for dirs and
337 filenames.
338 (read_line_program): Remove parameter u, change caller. Don't
339 subtract one from dirs and filenames index.
340 (read_function_entry): Don't subtract one from filenames index.
341
651b8a50
GA
3422021-01-05 Samuel Thibault <samuel.thibault@ens-lyon.org>
343
344 * configure: Re-generate.
345
6e1edf48
GA
3462020-12-05 Iain Sandoe <iain@sandoe.co.uk>
347
348 PR target/97865
349 * configure: Regenerate.
350
11860cf4
GA
3512020-12-02 Ian Lance Taylor <iant@golang.org>
352
353 * dwarf.c (resolve_string): Use > rather than >= to check whether
354 string index extends past buffer.
355 (resolve_addr_index): Similarly for address index.
356
a9625c50
GA
3572020-11-29 John David Anglin <danglin@gcc.gnu.org>
358
359 * configure: Regenerate.
360
e2e04288
GA
3612020-10-20 Ian Lance Taylor <iant@golang.org>
362
363 * internal.h (ATTRIBUTE_FALLTHROUGH): Define.
364 * elf.c (elf_zlib_inflate): Use ATTRIBUTE_FALLTHROUGH.
365
e84761c6
GA
3662020-09-28 Ian Lance Taylor <iant@golang.org>
367
368 PR libbacktrace/97082
369 * Makefile.am (check_DATA): Add mtest.dSYM if USE_DSYMUTIL.
370 * Makefile.in: Regenerate.
371
3722020-09-28 Ian Lance Taylor <iant@golang.org>
373
374 PR libbacktrace/97227
375 * configure.ac (USE_DSYMUTIL): Define instead of HAVE_DSYMUTIL.
376 * Makefile.am: Change all uses of HAVE_DSYMUTIL to USE_DSYMUTIL.
377 * configure: Regenerate.
378 * Makefile.in: Regenerate.
379
82b77dee
GA
3802020-09-23 Ian Lance Taylor <iant@golang.org>
381
382 * dwarf.c (report_inlined_functions): Handle PC == -1 and PC ==
383 p->low.
384 (dwarf_lookup_pc): Likewise.
385
ecde1b0a
GA
3862020-09-17 Ian Lance Taylor <iant@golang.org>
387
388 PR libbacktrace/97080
389 * fileline.c (backtrace_syminfo_to_full_callback): New function.
390 (backtrace_syminfo_to_full_error_callback): New function.
391 * elf.c (elf_nodebug): Call syminfo_fn if possible.
392 * internal.h (struct backtrace_call_full): Define.
393 (backtrace_syminfo_to_full_callback): Declare.
394 (backtrace_syminfo_to_full_error_callback): Declare.
395 * mtest.c (f3): Only check all[i] if data.index permits.
396
3972020-09-16 Iain Sandoe <iain@sandoe.co.uk>
398
399 * macho.c (MACH_O_CPU_TYPE_PPC): New.
400 (MACH_O_CPU_TYPE_PPC64): New.
401 Add compile-tests for powerpc to the Mach-O variants.
402
50a71cd0
GA
4032020-09-14 Ian Lance Taylor <iant@golang.org>
404
405 PR libbacktrace/93608
406 Add support for MiniDebugInfo.
407 * elf.c (struct elf_view): Define. Replace most uses of
408 backtrace_view with elf_view.
409 (elf_get_view): New static functions. Replace most calls of
410 backtrace_get_view with elf_get_view.
411 (elf_release_view): New static functions. Replace most calls of
412 backtrace_release_view with elf_release_view.
413 (elf_uncompress_failed): Rename from elf_zlib_failed. Change all
414 callers.
415 (LZMA_STATES, LZMA_POS_STATES, LZMA_DIST_STATES): Define.
416 (LZMA_DIST_SLOTS, LZMA_DIST_MODEL_START): Define.
417 (LZMA_DIST_MODEL_END, LZMA_FULL_DISTANCES): Define.
418 (LZMA_ALIGN_SIZE, LZMA_LEN_LOW_SYMBOLS): Define.
419 (LZMA_LEN_MID_SYMBOLS, LZMA_LEN_HIGH_SYMBOLS): Define.
420 (LZMA_LITERAL_CODERS_MAX, LZMA_LITERAL_CODER_SIZE): Define.
421 (LZMA_PROB_IS_MATCH_LEN, LZMA_PROB_IS_REP_LEN): Define.
422 (LZMA_PROB_IS_REP0_LEN, LZMA_PROB_IS_REP1_LEN): Define.
423 (LZMA_PROB_IS_REP2_LEN, LZMA_PROB_IS_REP0_LONG_LEN): Define.
424 (LZMA_PROB_DIST_SLOT_LEN, LZMA_PROB_DIST_SPECIAL_LEN): Define.
425 (LZMA_PROB_DIST_ALIGN_LEN): Define.
426 (LZMA_PROB_MATCH_LEN_CHOICE_LEN): Define.
427 (LZMA_PROB_MATCH_LEN_CHOICE2_LEN): Define.
428 (LZMA_PROB_MATCH_LEN_LOW_LEN): Define.
429 (LZMA_PROB_MATCH_LEN_MID_LEN): Define.
430 (LZMA_PROB_MATCH_LEN_HIGH_LEN): Define.
431 (LZMA_PROB_REP_LEN_CHOICE_LEN): Define.
432 (LZMA_PROB_REP_LEN_CHOICE2_LEN): Define.
433 (LZMA_PROB_REP_LEN_LOW_LEN): Define.
434 (LZMA_PROB_REP_LEN_MID_LEN): Define.
435 (LZMA_PROB_REP_LEN_HIGH_LEN): Define.
436 (LZMA_PROB_LITERAL_LEN): Define.
437 (LZMA_PROB_IS_MATCH_OFFSET, LZMA_PROB_IS_REP_OFFSET): Define.
438 (LZMA_PROB_IS_REP0_OFFSET, LZMA_PROB_IS_REP1_OFFSET): Define.
439 (LZMA_PROB_IS_REP2_OFFSET): Define.
440 (LZMA_PROB_IS_REP0_LONG_OFFSET): Define.
441 (LZMA_PROB_DIST_SLOT_OFFSET): Define.
442 (LZMA_PROB_DIST_SPECIAL_OFFSET): Define.
443 (LZMA_PROB_DIST_ALIGN_OFFSET): Define.
444 (LZMA_PROB_MATCH_LEN_CHOICE_OFFSET): Define.
445 (LZMA_PROB_MATCH_LEN_CHOICE2_OFFSET): Define.
446 (LZMA_PROB_MATCH_LEN_LOW_OFFSET): Define.
447 (LZMA_PROB_MATCH_LEN_MID_OFFSET): Define.
448 (LZMA_PROB_MATCH_LEN_HIGH_OFFSET): Define.
449 (LZMA_PROB_REP_LEN_CHOICE_OFFSET): Define.
450 (LZMA_PROB_REP_LEN_CHOICE2_OFFSET): Define.
451 (LZMA_PROB_REP_LEN_LOW_OFFSET): Define.
452 (LZMA_PROB_REP_LEN_MID_OFFSET): Define.
453 (LZMA_PROB_REP_LEN_HIGH_OFFSET): Define.
454 (LZMA_PROB_LITERAL_OFFSET): Define.
455 (LZMA_PROB_TOTAL_COUNT): Define.
456 (LZMA_IS_MATCH, LZMA_IS_REP, LZMA_IS_REP0): Define.
457 (LZMA_IS_REP1, LZMA_IS_REP2, LZMA_IS_REP0_LONG): Define.
458 (LZMA_DIST_SLOT, LZMA_DIST_SPECIAL, LZMA_DIST_ALIGN): Define.
459 (LZMA_MATCH_LEN_CHOICE, LZMA_MATCH_LEN_CHOICE2): Define.
460 (LZMA_MATCH_LEN_LOW, LZMA_MATCH_LEN_MID): Define.
461 (LZMA_MATCH_LEN_HIGH, LZMA_REP_LEN_CHOICE): Define.
462 (LZMA_REP_LEN_CHOICE2, LZMA_REP_LEN_LOW): Define.
463 (LZMA_REP_LEN_MID, LZMA_REP_LEN_HIGH, LZMA_LITERAL): Define.
464 (elf_lzma_varint): New static function.
465 (elf_lzma_range_normalize): New static function.
466 (elf_lzma_bit, elf_lzma_integer): New static functions.
467 (elf_lzma_reverse_integer): New static function.
468 (elf_lzma_len, elf_uncompress_lzma_block): New static functions.
469 (elf_uncompress_lzma): New static function.
470 (backtrace_uncompress_lzma): New function.
471 (elf_add): Add memory and memory_size parameters. Change all
472 callers. Look for .gnu_debugdata section, and, if found,
473 decompress it and use it for symbols and debug info. Permit the
474 descriptor parameter to be -1.
475 * internal.h (backtrace_uncompress_lzma): Declare.
476 * mtest.c: New file.
477 * xztest.c: New file.
478 * configure.ac: Check for nm, xz, and comm programs. Check for
479 liblzma library.
480 (HAVE_MINIDEBUG): Define.
481 * Makefile.am (mtest_SOURCES): Define.
482 (mtest_CFLAGS, mtest_LDADD): Define.
483 (TESTS): Add mtest_minidebug if HAVE_MINIDEBUG.
484 (%_minidebug): New pattern rule, if HAVE_MINIDEBUG.
485 (xztest_SOURCES, xztest_CFLAGS, xztest_LDADD): Define.
486 (xztest_alloc_SOURCES, xztest_alloc_CFLAGS): Define
487 (xztest_alloc_LDADD): Define.
488 (BUILDTESTS): Add mtest, xztest, xztest_alloc.
489 (CLEANFILES): Add files created by minidebug pattern.
490 (btest.lo): Correct INCDIR reference.
491 (mtest.lo, xztest.lo, ztest.lo): New targets.
492 * configure: Regenerate.
493 * config.h.in: Regenerate.
494 * Makefile.in: Regenerate.
495
80f86e78
GA
4962020-09-09 Ian Lance Taylor <iant@golang.org>
497
498 * pecoff.c (coff_initialize_syminfo): Add is_64 parameter.
499 (coff_add): Determine and pass is_64.
500
5012020-09-09 Ian Lance Taylor <iant@golang.org>
502
503 PR libbacktrace/96973
504 * fileline.c (macho_get_executable_path): New static function.
505 (fileline_initialize): Call macho_get_executable_path.
506
5072020-09-09 Ian Lance Taylor <iant@golang.org>
508
509 * dwarf.c (function_addrs_search): Compare against the next entry
510 low address, not the high address.
511 (unit_addrs_search): Likewise.
512 (build_address_map): Add a trailing unit_addrs.
513 (read_function_entry): Add a trailing function_addrs.
514 (read_function_info): Likewise.
515 (report_inlined_functions): Search backward for function_addrs
516 match.
517 (dwarf_lookup_pc): Search backward for unit_addrs and
518 function_addrs matches.
519
31a05046
GA
5202020-09-08 Ian Lance Taylor <iant@golang.org>
521
522 * simple.c (simple_unwind): Correct comment spelling.
523
5242020-09-08 Ian Lance Taylor <iant@golang.org>
525
526 * macho.c (macho_add_dsym): Make space for '/' in dsym. Use
527 correct length when freeing diralc.
528
5292020-09-08 Ian Lance Taylor <iant@golang.org>
530
531 PR libbacktrace/96973
532 * macho.c (macho_add_fat): Correctly swap 32-bit file offset.
533
5342020-09-08 Ian Lance Taylor <iant@golang.org>
535
536 PR libbacktrace/96971
537 * filetype.awk: Only match magic number at start of line.
538
b2b24d30
GA
5392020-08-24 Ian Lance Taylor <iant@golang.org>
540
541 * macho.c (MACH_O_MH_MAGIC_FAT_64): Define.
542 (MACH_O_MH_CIGAM_FAT_64): Define.
543 (struct macho_fat_arch_64): Define.
544 (macho_add_fat): Add and use is_64 parameter.
545 (macho_add): Recognize 64-bit fat files.
546
d48cca8f
GA
5472020-07-30 H.J. Lu <hjl.tools@gmail.com>
548
549 PR bootstrap/96202
550 * configure: Regenerated.
551
50873cc5
GA
5522020-07-08 Ian Lance Taylor <iant@golang.org>
553
554 * configure.ac: Test linker support for DWARF5
555 * configure: Regenerate
556
885ef72f
GA
5572020-05-29 H.J. Lu <hjl.tools@gmail.com>
558
559 PR bootstrap/95413
560 * configure: Regenerated.
561
4c1a5d8b
L
5622020-05-15 H.J. Lu <hongjiu.lu@intel.com>
563
564 PR bootstrap/95147
565 * configure: Regenerated.
566
8d286dd1
L
5672020-05-14 H.J. Lu <hongjiu.lu@intel.com>
568
569 * configure: Regenerated.
570
d2ec2786
ILT
5712020-05-13 Ian Lance Taylor <iant@golang.org>
572
573 * ztest.c (test_large): Mark state ATTRIBUTE_UNUSED.
574
702adbb2
ILT
5752020-05-13 Ian Lance Taylor <iant@golang.org>
576
577 PR go/95061
578 * posix.c (backtrace_open): Treat EACCESS like ENOENT.
579
5802020-05-12 H.J. Lu <hongjiu.lu@intel.com>
d2148648
L
581
582 * Makefile.am (AM_CFLAGS): Add $(CET_HOST_FLAGS).
583 * configure.ac: Add GCC_CET_HOST_FLAGS(CET_HOST_FLAGS) and
584 AC_SUBST(CET_HOST_FLAGS). Clear CET_HOST_FLAGS if jit isn't
585 enabled.
586 * Makefile.in: Regenerated.
587 * configure: Likewise.
588
47f4703c
ILT
5892020-05-11 Ian Lance Taylor <iant@golang.org>
590
591 PR libbacktrace/95012
592 * configure.ac: Check for getpagesize declaration.
593 * mmap.c: Declare getpagesize if necessary.
594 * mmapio.c: Likewise.
595 * configure: Regenerate.
596 * config.h.in: Regenerate.
597 * Makefile.in: Regenerate.
598
ef639420
ILT
5992020-05-09 Roland McGrath <mcgrathr@google.com>
600
601 * elf.c (elf_add): Bail early if there are no section headers at all.
602
8600440e
ILT
6032020-05-09 Ian Lance Taylor <iant@golang.org>
604
605 * elf.c (elf_add): Don't free strtab if an error occurs after
606 recording symbol information.
607
dea40c94
ILT
6082020-05-09 Ian Lance Taylor <iant@golang.org>
609
610 PR libbacktrace/88745
611 * macho.c: New file.
612 * filetype.awk: Recognize Mach-O files.
613 * Makefile.am (FORMAT_FILES): Add macho.c.
614 (check_DATA): New variable. Set to .dSYM if HAVE_DSYMUTIL.
615 (%.dSYM): New pattern target.
616 (test_macho_SOURCES, test_macho_CFLAGS): New targets.
617 (test_macho_LDADD): New target.
618 (BUILDTESTS): Add test_macho.
619 (macho.lo): Add dependencies.
620 * configure.ac: Recognize macho file type. Check for
621 mach-o/dyld.h. Don't try to run objcopy if we don't find it.
622 Look for dsymutil and define a HAVE_DSYMUTIL conditional.
623 * Makefile.in: Regenerate.
624 * configure: Regenerate.
625 * config.h.in: Regenerate.
626
4b26b138
ILT
6272020-05-09 Ian Lance Taylor <iant@golang.org>
628
629 * read.c (backtrace_get_view): Support short read.
630
31ae7b86
ILT
6312020-05-09 Ian Lance Taylor <iant@golang.org>
632
633 * elf.c (elf_add): If debug sections are very large or far apart,
634 read them individually rather than as a single view.
635
26135684
ILT
6362020-05-08 Ian Lance Taylor <iant@golang.org>
637
638 * fileline.c (sysctl_exec_name): New static function.
639 (sysctl_exec_name1): New macro or static function.
640 (sysctl_exec_name2): Likewise.
641 (fileline_initialize): Try sysctl_exec_name[12].
642 * configure.ac: Check for sysctl args to fetch executable name.
643 * configure: Regenerate.
644 * config.h.in: Regenerate.
645
9a3d019a
ILT
6462020-02-15 Ian Lance Taylor <iant@golang.org>
647
648 * ztest.c (test_large): Update file to current libgo test file.
649
628ee3c2
ILT
6502020-02-03 Ian Lance Taylor <iant@golang.org>
651
652 * Makefile.am (libbacktrace_TEST_CFLAGS): Define.
653 (test_elf32_CFLAGS): Use $(libbacktrace_test_CFLAGS).
654 (test_elf_64_CFLAGS, test_xcoff_32_CFLAGS): Likewise.
655 (test_xcoff_64_CFLAGS, test_pecoff_CFLAGS): Likewise.
656 (test_unknown_CFLAGS, unittest_CFLAGS): Likewise.
657 (unittest_alloc_CFLAGS, allocfail_CFLAGS): Likewise.
658 (b2test_CFLAGS, b3test_CFLAGS, btest_CFLAGS): Likewise.
659 (btest_lto_CFLAGS, btest_alloc_CFLAGS, stest_CFLAGS): Likewise.
660 (stest_alloc_CFLAGS): Likewise.
661 * Makefile.in: Regenerate.
662 * ztest.c (error_callback_compress): Mark vdata unused.
663 (test_large): Add casts to avoid warnings.
664
8d9254fc
JJ
6652020-01-01 Jakub Jelinek <jakub@redhat.com>
666
667 Update copyright years.
668
c926fd82
ILT
6692019-12-13 Ian Lance Taylor <iant@golang.org>
670
671 Add DWARF 5 support.
672 * dwarf.c (struct attr): Add val field.
673 (enum attr_val_encoding): Add ATTR_VAL_ADDDRESS_INDEX,
674 ATTR_VAL_STRING_INDEX, ATTR_VAL_RNGLISTS_INDEX.
675 (struct line_header): Add addrsize field.
676 (struct line_header_format): Define.
677 (struct unit): Add str_offsets_base, addr_base, and rnglists_base
678 fields.
679 (read_uint24): New static function.
680 (read_attribute): Add implicit_val parameter. Replace dwarf_str
681 and dwarf_str_size parameters with dwarf_sections parameter. Add
682 support for new DWARF 5 forms. Change all callers.
683 (resolve_string): New static function.
684 (resolve_addr_index): Likewise.
685 (read_abbrevs): Support DW_FORM_implicit_const.
686 (struct pcrange): Add lowpc_is_addr_index, highpc_is_addr_Index,
687 and ranges_is_index fields.
688 (update_pcrange): Support DWARF 5 encodings.
689 (add_high_low_range): New static function, split out of
690 add_ranges.
691 (add_ranges_from_ranges): Likewise.
692 (add_ranges_from_rnglists): New static function.
693 (add_ranges): Just call new helper functions.
694 (find_address_ranges): Use resolve_string for strings, after
695 reading all attributes. Handle new DWARF 5 attributes.
696 (build_address_map): Support DWARF 5 compilation units.
697 (read_v2_paths): New static function, split out of
698 read_line_header.
699 (read_lnct): New static function.
700 (read_line_header_format_entries): Likewise.
701 (read_line_header): Add ddata parameter. Support DWARF 5 line
702 headers. Call new helper functions. Change all callers.
703 (read_line_program): Use addrsize from line program header. Don't
704 special case directory index 0 for DWARF 5.
705 (read_referenced_name): Use resolve_string.
706 (read_function_entry): Handle DWARF 5 encodings. Use
707 resolve_string.
708 * internal.h (enum dwarf_section): Add DEBUG_ADDR,
709 DEBUG_STR_OFFSETS, DEBUG_LINE_STR, DEBUG_RNGLISTS.
710 * elf.c (dwarf_section_names): Add new section names.
711 * pecoff.c (dwarf_section_names): Likewise.
712 * xcoff.c (xcoff_add): Clear dwarf_sections before setting
713 fields.
714 * configure.ac: Define HAVE_DWARF5 automake conditional.
715 * Makefile.am (dwarf5_SOURCES): New variable if HAVE_DWARF5.
716 (dwarf5_CFLAGS, dwarf5_LDADD): Likewise.
717 (dwarf5_alloc_SOURCES, dwarf5_alloc_CFLAGS): Likewise.
718 (dwarf5_alloc_LDADD): Likewise.
719 (BUILDTESTS): Add dwarf5 tests if HAVE_DWARF5.
720 (CLEANFILES, clean-local): Define.
721
4b3fc188
ILT
7222019-12-08 Ian Lance Taylor <iant@golang.org>
723
724 * dwarf.c (struct pcrange): Define.
725 (update_pcrange, add_ranges): New static functions.
726 (add_unit_addr): Change signature to work with add_ranges. Don't
727 add base_address here.
728 (add_unit_ranges): Remove.
729 (find_address_ranges): Replace str/ranges parameters with
730 dwarf_sections. Use update_pcrange and add_ranges. Change all
731 callers.
732 (add_function_range): Change signature to work with add_ranges.
733 Don't add base_address here.
734 (add_function_ranges): Remove.
735 (read_function_entry): Use update_pcrange and add_ranges.
736
70bfe5a7
ILT
7372019-12-04 Ian Lance Taylor <iant@golang.org>
738
739 * edtest.c (test1): Add noclone attribute.
740
66ab5839
ILT
7412019-12-04 Ian Lance Taylor <iant@golang.org>
742
743 * internal.h (enum dwarf_section): Define.
744 (struct dwarf_sections): Define.
745 (backtrace_dwarf_add): Update declaration to replace specific
746 section parameters with dwarf_sections parameter.
747 * dwarf.c (struct dwarf_data): Replace specific section fields
748 with dwarf_sections field.
749 (read_attribute): Use dwarf_sections with altlink.
750 (build_address_map): Replace specific section parameters with
751 dwarf_sections parameter. Change all callers.
752 (read_line_info): Use dwarf_sections with ddata.
753 (read_referenced_name): Likewise.
754 (add_function_ranges): Likewise.
755 (read_function_entry): Likewise.
756 (read_function_info): Likewise.
757 (build_dwarf_data): Replace specific section parameters with
758 dwarf_sections parameter. Change all callers.
759 (backtrace_dwarf_add): Likewise.
760 * elf.c (enum debug_section): Remove.
761 (dwarf_section_names): Remove .zdebug names.
762 (elf_add): Track zsections separately. Build dwarf_sections.
763 * pecoff.c (enum debug_section): Remove.
764 (struct debug_section_info): Remove data field.
765 (coff_add): Build dwarf_sections.
766 * xcoff.c (enum dwarf_section): Remove. Replace DWSECT_xxx
767 references with DEBUG_xxx references.
768 (xcoff_add): Build dwarf_sections.
769
e9085da5
MR
7702019-09-27 Maciej W. Rozycki <macro@wdc.com>
771
772 * configure: Regenerate.
773
5fe5f75f
ILT
7742019-09-26 Ian Lance Taylor <iant@golang.org>
775
776 PR libbacktrace/91908
777 * pecoff.c (backtrace_initialize): Explicitly cast unchecked
778 __sync_bool_compare_and_swap to void.
779 * xcoff.c (backtrace_initialize): Likewise.
780
2f2aeda9
UW
7812019-09-03 Ulrich Weigand <uweigand@de.ibm.com>
782
783 * configure.ac: Remove references to spu.
784 * configure: Regenerate.
785
245254b8
CC
7862019-05-24 Clement Chigot <clement.chigot@atos.net>
787
788 * Makefile.am (BUILDTESTS): Remove test_elf, add test_elf_32 and
789 test_elf_64.
790 * Makefile.in: Regenerate.
791
ccd1242e
RO
7922019-05-14 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
793
794 * configure.ac (have_dl_iterate_phdr): Remove *-*-solaris2.10*
795 handling.
796 * configure: Regenerate.
797
7856fb45
ILT
7982019-03-11 Ian Lance Taylor <iant@golang.org>
799
800 PR libbacktrace/89669
801 * Makefile.am (BUILDTESTS): Only add ztest and ztest_alloc if
802 HAVE_ELF.
803 * Makefile.in: Regenerate.
804
067aef03
TV
8052019-02-26 Tom de Vries <tdevries@suse.de>
806
807 * btest.c (test5): Allow global.* as minimal symbol name for global.
808
d831b1ec
TV
8092019-02-26 Tom de Vries <tdevries@suse.de>
810
811 * Makefile.am (TESTS): Only add b3test_dwz_buildid if HAVE_DWZ.
812 * Makefile.in: Regenerate.
813
68641fb7
TV
8142019-02-12 Tom de Vries <tdevries@suse.de>
815
816 PR libbacktrace/81983
817 * dwarf.c (dwarf_lookup_pc): Don't call bsearch if nmemb == 0.
818
c51b2c8c
TV
8192019-02-10 Tom de Vries <tdevries@suse.de>
820
821 * Makefile.am (BUILDTESTS): Add btest_lto.
822 * Makefile.in: Regenerate.
823 * btest.c (test1, f2, f3, test3, f22, f23): Declare with
824 __attribute__((noclone)).
825
4af50e13
TV
8262019-02-08 Tom de Vries <tdevries@suse.de>
827
828 * backtrace.c (backtrace_full): Declare with __attribute__((noinline)).
829 * print.c (backtrace_print): Same.
830 * simple.c (backtrace_simple): Same.
831
2bd0a246
TV
8322019-02-08 Tom de Vries <tdevries@suse.de>
833
834 PR libbacktrace/78063
835 * dwarf.c (build_address_map): Keep all parsed units.
836 (read_referenced_name_from_attr): Handle DW_FORM_ref_addr.
837
3a3f5dd1
TV
8382019-01-31 Tom de Vries <tdevries@suse.de>
839
840 PR libbacktrace/89136
841 * elf.c (elf_add): Read build-id if with_buildid_data. Fix
842 'debugaltlink_name_len =+ 1'.
843
fddbc193
TV
8442019-01-29 Tom de Vries <tdevries@suse.de>
845
846 * install-debuginfo-for-buildid.sh.in: New script.
847 * Makefile.am (check_PROGRAMS): Add b2test and b3test.
848 (TESTS): Add b2test_buildid and b3test_dwz_buildid.
849 * Makefile.in: Regenerate.
850 * configure.ac (HAVE_ELF): Set with AM_CONDITIONAL.
851 (READELF): Set with AC_CHECK_PROG.
852 (install-debuginfo-for-buildid.sh): Generate with AC_CONFIG_FILES.
853 * configure: Regenerate.
854 * elf.c (SYSTEM_BUILD_ID_DIR): Factor out of ...
855 (elf_open_debugfile_by_buildid): ... here.
856
57f0d303
TV
8572019-01-29 Tom de Vries <tdevries@suse.de>
858
859 * Makefile.am: Replace check_PROGRAMS with BUILDTESTS, except for
860 allocfail.
861 (TESTS): Don't add check_PROGRAMS. Add BUILDTESTS.
862 (check_PROGRAMS): Add BUILDTESTS.
863 * Makefile.in: Regenerate.
864
62d4a355
TV
8652019-01-28 Tom de Vries <tdevries@suse.de>
866
867 * Makefile.am (xcoff_%.c): Generate sed result into temporary file.
868 Use $< to access prerequisite.
869 * Makefile.in: Regenerate.
870
4bfcd139
NS
8712019-01-25 Nathan Sidwell <nathan@acm.org>
872
873 * elf.c (elf_add): Pass "" filename to recursive call with
874 separated debug.
875
c75795fa
TV
8762019-01-25 Tom de Vries <tdevries@suse.de>
877
878 * elf.c (elf_add): When handling .gnu_debugaltlink, call elf_add with
879 filename == "".
880 * Makefile.am (TESTS): Add btest_dwz_gnudebuglink.
881 * Makefile.in: Regenerate.
882
37ab491d
TV
8832019-01-25 Tom de Vries <tdevries@suse.de>
884
885 * Makefile.am: Rewrite dtest rule into "%_gnudebuglink" pattern rule.
886 (TESTS): Rename dtest to btest_gnudebuglink.
887 * Makefile.in: Regenerate.
888
3f5d2012
TV
8892019-01-23 Tom de Vries <tdevries@suse.de>
890
891 * dwarf.c (struct unit): Use size_t for low_offset/high_offset fields.
892 (units_search, find_unit): Use size_t for offset.
893 (build_address_map): Use size_t for unit_offset.
894
5e2a7241
GP
8952019-01-20 Gerald Pfeifer <gerald@pfeifer.com>
896
897 * allocfail.c (main): Increase portability of printf statement.
898
8b248c17
ILT
8992019-01-18 Ian Lance Taylor <iant@golang.org>
900
901 PR libbacktrace/88890
902 * mmapio.c (backtrace_get_view): Change size parameter to
903 uint64_t. Check that value fits in size_t.
904 * read.c (backtrace_get_view): Likewise.
905 * internal.h (backtrace_get_view): Update declaration.
906 * elf.c (elf_add): Pass shstrhdr->sh_size to backtrace_get_view.
907
10f48858
TV
9082019-01-17 Tom de Vries <tdevries@suse.de>
909
910 PR libbacktrace/82857
911 * configure.ac (DWZ): Set with AC_CHECK_PROG.
912 (HAVE_DWZ): Set with AM_CONDITIONAL.
913 * configure: Regenerate.
914 * Makefile.am (TESTS): Add btest_dwz.
915 * Makefile.in: Regenerate.
916
1c2a9a37
TV
9172019-01-17 Tom de Vries <tdevries@suse.de>
918
919 PR libbacktrace/82857
920 * dwarf.c (enum attr_val_encoding): Add ATTR_VAL_REF_ALT_INFO.
921 (read_attribute): Handle DW_FORM_GNU_ref_alt using
922 ATTR_VAL_REF_ALT_INFO.
923 (read_referenced_name_from_attr): Handle DW_FORM_GNU_ref_alt.
924
9d576782
TV
9252019-01-17 Tom de Vries <tdevries@suse.de>
926
927 * dwarf.c (struct unit): Add low_offset and high_offset fields.
928 (struct unit_vector): New type.
929 (struct dwarf_data): Add units and units_counts fields.
930 (find_unit): New function.
931 (find_address_ranges): Add and handle unit_tag parameter.
932 (build_address_map): Add and handle units_vec parameter.
933 (build_dwarf_data): Pass units_vec to build_address_map. Store resulting
934 units vector.
935
f2f00d3a
TV
9362019-01-17 Tom de Vries <tdevries@suse.de>
937
938 PR libbacktrace/82857
939 * dwarf.c (read_attribute): Handle DW_FORM_GNU_strp_alt
940 using altlink.
941
944f59ff
TV
9422019-01-17 Tom de Vries <tdevries@suse.de>
943
944 * dwarf.c (enum attr_val_encoding): Add ATTR_VAL_NONE.
945 (read_attribute): Add altlink parameter. Handle missing altlink for
946 DW_FORM_GNU_strp_alt and DW_FORM_GNU_ref_alt.
947 (find_address_ranges, build_address_map, build_dwarf_data): Add and
948 handle altlink parameter.
949 (read_referenced_name, read_function_entry): Add argument to
950 read_attribute call.
951
9ad458d5
TV
9522019-01-17 Tom de Vries <tdevries@suse.de>
953
954 * dwarf.c (struct dwarf_data): Add altlink field.
955 (backtrace_dwarf_add): Add and handle fileline_altlink parameter.
956 * elf.c (elf_add): Add argument to backtrace_dwarf_add call.
957 (phdr_callback, backtrace_initialize): Add argument to elf_add calls.
958 * internal.h (backtrace_dwarf_add): Add fileline_altlink parameter.
959 * pecoff.c (coff_add): Add argument to backtrace_dwarf_add call.
960 * xcoff.c (xcoff_add): Same.
961
e6f00c83
TV
9622019-01-17 Tom de Vries <tdevries@suse.de>
963
964 * internal.h (backtrace_dwarf_add): Add fileline_entry parameter.
965 * dwarf.c (backtrace_dwarf_add): Add and handle fileline_entry parameter.
966 * elf.c (elf_add): Add and handle fileline_entry parameter. Add
967 argument to backtrace_dwarf_add call.
968 (phdr_callback, backtrace_initialize): Add argument to elf_add calls.
969 * pecoff.c (coff_add): Add argument to backtrace_dwarf_add call.
970 * xcoff.c (xcoff_add): Same.
971
a34c2a3d
TV
9722019-01-17 Tom de Vries <tdevries@suse.de>
973
974 * elf.c (elf_add): Add and handle with_buildid_data and
975 with_buildid_size parameters. Handle .gnu_debugaltlink section.
976 (phdr_callback, backtrace_initialize): Add arguments to elf_add calls.
977
07e1534f
TV
9782019-01-16 Tom de Vries <tdevries@suse.de>
979
980 * dwarf.c (read_referenced_name_from_attr): New function. Factor out
981 of ...
982 (read_referenced_name): ... here, and ...
983 (read_function_entry): ... here.
984
df1de064
TV
9852019-01-16 Tom de Vries <tdevries@suse.de>
986
987 * dwarf.c (read_referenced_name): Don't allow DW_AT_name to override any
988 name.
989 (read_function_entry): Same. Don't allow name found via
990 DW_AT_abstract_origin or case DW_AT_specification to override linkage
991 name.
992
67914693
SL
9932019-01-09 Sandra Loosemore <sandra@codesourcery.com>
994
995 PR other/16615
996
997 * backtrace.h: Mechanically replace "can not" with "cannot".
998
a5544970
JJ
9992019-01-01 Jakub Jelinek <jakub@redhat.com>
1000
1001 Update copyright years.
1002
4b420b27
GP
10032018-12-29 Gerald Pfeifer <gerald@pfeifer.com>
1004
1005 * Makefile.am (xcoff_%.c): Use an actual newline instead of \n
1006 in sed pattern.
1007 * Makefile.in: Regenerate.
1008
eb33bf0a
TV
10092018-12-28 Tom de Vries <tdevries@suse.de>
1010
1011 * dwarf.c (build_address_map): Reuse unused units.
1012
d9aa0961
TV
10132018-12-28 Tom de Vries <tdevries@suse.de>
1014
1015 * dwarf.c (build_address_map): Simplify by removing local variable
1016 abbrevs.
1017
40b8d3b2
ILT
10182018-12-28 Ian Lance Taylor <iant@golang.org>
1019 Tom de Vries <tdevries@suse.de>
1020
1021 PR libbacktrace/88063
1022 * dwarf.c (free_unit_addrs_vector): Remove.
1023 (build_address_map): Keep track of allocated units in vector. Free
1024 allocated units and corresponding abbrevs upon failure. Remove now
1025 redundant call to free_unit_addrs_vector. Free addrs vector upon
1026 failure. Free allocated unit vector.
1027
53a52133
TV
10282018-12-28 Tom de Vries <tdevries@suse.de>
1029
1030 * dwarf.c (build_address_map): Free addrs vector upon failure.
1031
a37a52e5
TV
10322018-12-14 Tom de Vries <tdevries@suse.de>
1033
1034 PR testsuite/88491
1035 * allocfail.sh: Remove "set -o pipefail".
1036
d665cd9b
TV
10372018-12-12 Tom de Vries <tdevries@suse.de>
1038
1039 * Makefile.am (TESTS): Add allocfail.sh.
1040 (check_PROGRAMS): Add allocfail.
1041 * Makefile.in: Regenerate.
1042 * instrumented_alloc.c: New file. Redefine malloc and realloc.
1043 Include alloc.c.
1044 * allocfail.c: New file.
1045 * allocfail.sh: New file.
1046
187b9e1d
TV
10472018-11-30 Tom de Vries <tdevries@suse.de>
1048
1049 * Makefile.am (check_PROGRAMS): Add test_elf, test_xcoff_32,
1050 test_xcoff_64, test_pecoff and test_unknown.
1051 * Makefile.in: Regenerate.
1052 * test_format.c: New file.
1053
9b7d1a97
TV
10542018-11-30 Tom de Vries <tdevries@suse.de>
1055
1056 * Makefile.am : Add _with_alloc version for each test in
1057 check_PROGRAMS.
1058 * Makefile.in: Regenerate.
1059
518a3a21
TV
10602018-11-30 Tom de Vries <tdevries@suse.de>
1061
1062 * internal.h (backtrace_vector_free): New static inline fuction,
1063 factored out of ...
1064 * dwarf.c (read_line_info): ... here.
1065
18c742b5
TV
10662018-11-28 Tom de Vries <tdevries@suse.de>
1067
1068 * dwarf.c (read_abbrevs): Fix handling of abbrevs->abbrevs allocation
1069 failure.
1070
6d760a01
TV
10712018-11-27 Tom de Vries <tdevries@suse.de>
1072
1073 * mmap.c (backtrace_vector_release): Same.
1074 * unittest.c (test1): Add check.
1075
0c155f24
TV
10762018-11-27 Tom de Vries <tdevries@suse.de>
1077
1078 * alloc.c (backtrace_vector_release): Handle vec->size == 0 using free
1079 instead of realloc.
1080 * Makefile.am (check_PROGRAMS): Add unittest.
1081 * Makefile.in: Regenerate.
1082 * unittest.c: New file.
1083
292592c5
TV
10842018-11-22 Tom de Vries <tdevries@suse.de>
1085
1086 * dwarf.c (read_initial_length): Factor out of ...
1087 (build_address_map, read_line_info): ... here.
1088
17112570
TV
10892018-11-21 Tom de Vries <tdevries@suse.de>
1090
1091 * dwarf.c (read_string): Factor out of ...
1092 (read_attribute, read_line_header, read_line_program): ... here.
1093
22e05272
JM
10942018-10-31 Joseph Myers <joseph@codesourcery.com>
1095
1096 PR bootstrap/82856
1097 * Makefile.am: Include multilib.am.
1098 * configure.ac: Remove AC_PREREQ. Use AC_LANG_SOURCE.
1099 * Makefile.in, aclocal.m4, config.h.in, configure: Regenerate.
1100
a2a86641
ILT
11012018-10-05 Ian Lance Taylor <iant@golang.org>
1102
1103 PR libbacktrace/87529
1104 * backtrace.h: Document that backtrace_create_state should be
1105 called only once.
1106
2206fb89
IB
11072018-08-05 Iain Buclaw <ibuclaw@gdcproject.org>
1108
1109 * configure.ac: Move define of HAVE_ZLIB into check for -lz.
1110 * Makefile.in: Regenerate.
1111 * config.h.in: Likewise.
1112 * configure: Likewise.
1113
ca9a1314
TR
11142018-08-01 Tony Reix <tony.reix@atos.net>
1115
1116 * xcoff.c (struct xcoff_line, struct xcoff_line_vector): Remove.
1117 (struct xcoff_func, struct xcoff_func_vector): New structs.
1118 (xcoff_syminfo): Drop leading dot from symbol name.
1119 (xcoff_line_compare, xcoff_line_search): Remove.
1120 (xcoff_func_compare, xcoff_func_search): New static functions.
1121 (xcoff_lookup_pc): Search function table.
1122 (xcoff_add_line, xcoff_process_linenos): Remove.
1123 (xcoff_initialize_fileline): Build function table.
1124
1ac6620a
DK
11252018-06-21 Denis Khalikov <d.khalikov@partner.samsung.com>
1126
1127 PR other/86198
1128 * elf.c (elf_add): Increase ".note.gnu.build-id" section size
1129 checking up to 36 bytes.
1130
7b47ecf2
L
11312018-04-24 H.J. Lu <hongjiu.lu@intel.com>
1132
1133 * configure: Regenerated.
1134
a0e1df88
JJ
11352018-04-19 Jakub Jelinek <jakub@redhat.com>
1136
1137 * configure: Regenerated.
1138
21070494
ILT
11392018-04-17 Ian Lance Taylor <iant@golang.org>
1140
1141 * backtrace.c: Revert last two changes. Don't call mmap
1142 directly.
1143
c36af1b4
ILT
11442018-04-17 Ian Lance Taylor <iant@golang.org>
1145
1146 * backtrace.c: Include backtrace-supported.h before checking
1147 BACKTRACE_USES_MALLOC.
1148
83a658ca
ILT
11492018-04-17 Ian Lance Taylor <iant@golang.org>
1150
1151 * backtrace.c (backtrace_full): When testing whether we can
1152 allocate memory, call mmap directly, and munmap the memory.
1153
c5c4b2ae
JJ
11542018-04-04 Jakub Jelinek <jakub@redhat.com>
1155
1156 PR other/85161
1157 * elf.c (elf_zlib_fetch): Fix up predefined macro names in test for
1158 big endian, only use 32-bit loads if endianity macros are predefined
1159 and indicate big or little endian.
1160
14e335ed
IT
11612018-02-14 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
1162
1163 PR target/84148
1164 * configure: Regenerate.
1165
bcc23586
JJ
11662018-02-15 Jakub Jelinek <jakub@redhat.com>
1167
1168 PR other/82368
1169 * elf.c (SHT_PROGBITS): Undefine and define.
1170
da07141f
JJ
11712018-02-14 Jakub Jelinek <jakub@redhat.com>
1172
1173 PR other/82368
1174 * elf.c (EM_PPC64, EF_PPC64_ABI): Undefine and define.
1175 (struct elf_ppc64_opd_data): New type.
1176 (elf_initialize_syminfo): Add opd argument, handle symbols
1177 pointing into the PowerPC64 ELFv1 .opd section.
1178 (elf_add): Read .opd section on PowerPC64 ELFv1, pass pointer
1179 to structure with .opd data to elf_initialize_syminfo.
1180
65d0b859
ILT
11812018-01-31 Ian Lance Taylor <iant@golang.org>
1182
1183 * elf.c (elf_add): Close descriptor if we use a debugfile.
1184 * btest.c (check_open_files): New static function.
1185 (main): Call check_open_files.
1186
96f7c2a9
ILT
11872018-01-25 Ian Lance Taylor <iant@golang.org>
1188
1189 * elf.c (elf_open_debugfile_by_debuglink): Don't check CRC if the
1190 desired CRC is zero.
1191 (elf_add): Don't clear *found_sym and *found_dwarf if debuginfo.
1192
a794e494
ILT
11932018-01-25 Ian Lance Taylor <iant@golang.org>
1194
1195 * pecoff.c (coff_add): Only release syms_view if it is valid.
1196
45f3ab19
ILT
11972018-01-25 Ian Lance Taylor <iant@golang.org>
1198
1199 * pecoff.c (coff_add): Another memcpy -> coff_read4 fix.
1200
017707ce
ILT
12012018-01-24 Ian Lance Taylor <iant@golang.org>
1202
1203 * pecoff.c (coff_add): Use coff_read4, not memcpy.
1204
3fe3c7d7
ILT
12052018-01-24 Ian Lance Taylor <iant@golang.org>
1206
1207 PR other/68239
1208 * mmap.c (backtrace_free_locked): Don't put more than 16 entries
1209 on the free list.
1210
47c699f5
TR
12112018-01-19 Tony Reix <tony.reix@atos.net>
1212
1213 * xcoff.c (xcoff_incl_compare): New function.
1214 (xcoff_incl_search): New function.
1215 (xcoff_process_linenos): Use bsearch to find include file.
1216 (xcoff_initialize_fileline): Sort include file information.
1217
566588f1
ILT
12182018-01-16 Ian Lance Taylor <iant@golang.org>
1219
1220 * elf.c (codes) [GENERATE_FIXED_HUFFMAN_TABLE]: Fix size to be
1221 288.
1222 (main) [GENERATE_FIXED_HUFFMAN_TABLE]: Pass 288 to
1223 elf_zlib_inflate_table. Generate elf_zlib_default_dist_table.
1224 (elf_zlib_default_table): Update.
1225 (elf_zlib_default_dist_table): New static array.
1226 (elf_zlib_inflate): Use elf_zlib_default_dist_table for dist table
1227 for block type 1.
1228 * ztest.c (struct zlib_test): Add uncompressed_len.
1229 (tests): Initialize uncompressed_len field. Add new test case.
1230 (test_samples): Use uncompressed_len field.
1231
85ec4feb
JJ
12322018-01-03 Jakub Jelinek <jakub@redhat.com>
1233
1234 Update copyright years.
1235
44685d37
IT
12362017-11-17 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
1237
1238 * configure.ac: Add CET_FLAGS to EXTRA_FLAGS.
1239 * aclocal.m4: Regenerate.
1240 * Makefile.in: Likewise.
1241 * configure: Likewise.
1242
549d24e9
ILT
12432017-10-06 Ian Lance Taylor <iant@golang.org>
1244
1245 * ztest.c (test_large): Pass unsigned long *, not size_t *, to
1246 zlib uncompress function.
1247
a978e26b
ILT
12482017-10-05 Ian Lance Taylor <iant@golang.org>
1249
1250 * elf.c (elf_zlib_fetch): Change pval argument to uint64_t *.
1251 Read a four byte integer.
1252 (elf_zlib_inflate): Change val to uint64_t. Align pin to a 32-bit
1253 boundary before ever calling elf_zlib_fetch.
1254 * ztest.c (test_large): Simplify print statements a bit.
1255
8398c1df
ILT
12562017-10-02 Ian Lance Taylor <iant@golang.org>
1257
1258 * ztest.c: #include <errno.h>.
1259 (TEST_TIMING): Don't define, don't test.
1260 (xclock_gettime, xclockid_t): Define if !HAVE_CLOCK_GETTIME.
1261 (clockid_t, clock_gettime, CLOCK_REALTIME): Likewise.
1262 (ZLIB_CLOCK_GETTIME_ARG): Define.
1263 * configure.ac: Change clock_gettime_link to CLOCK_GETTIME_LINK.
1264 * Makefile.am: Likewise.
1265 * configure, Makefile.in: Rebuild.
1266
dbc31f20
TS
12672017-10-02 Thomas Schwinge <thomas@codesourcery.com>
1268
dd954c67
TS
1269 PR other/67165
1270 * Makefile.am: Append the content of clock_gettime_link to
1271 ztest_LDADD.
1272 * configure.ac: Test for the case that clock_gettime is in librt.
1273 * Makefile.in: Regenerate.
1274 * configure: Likewise.
1275
dbc31f20
TS
1276 PR other/67165
1277 * configure.ac: Check for clock_gettime.
1278 * config.h.in: Regenerate.
1279 * configure: Likewise.
1280 * ztest.c (average_time, test_large): Conditionalize test timing
1281 on clock_gettime availability.
1282
e90c74f5
TR
12832017-09-29 Tony Reix <tony.reix@atos.net>
1284
1285 * xcoff.c: Initial support for DWARF debug sections in XCOFF.
1286 (STYP_DWARF, SSUBTYP_DW*): Define.
1287 (enum dwarf_section): Define.
1288 (struct dwsect_info): Define.
1289 (xcoff_add): Look for DWARF sections, pass them to
1290 backtrace_dwarf_add.
1291
8da872d9
ILT
12922017-09-28 Ian Lance Taylor <iant@golang.org>
1293
1294 PR other/67165
1295 * elf.c (__builtin_prefetch): Define if not __GNUC__.
1296 (unlikely): Define.
1297 (SHF_UNCOMPRESSED, ELFCOMPRESS_ZLIB): Define.
1298 (b_elf_chdr): Define type.
1299 (enum debug_section): Add ZDEBUG_xxx values.
1300 (debug_section_names): Add names for new sections.
1301 (struct debug_section_info): Add compressed field.
1302 (elf_zlib_failed, elf_zlib_fetch): New static functions.
1303 (HUFFMAN_TABLE_SIZE, HUFFMAN_VALUE_MASK): Define.
1304 (HUFFMAN_BITS_SHIFT, HUFFMAN_BITS_MASK): Define.
1305 (HUFFMAN_SECONDARY_SHIFT): Define.
1306 (ZDEBUG_TABLE_SIZE): Define.
1307 (ZDEBUG_TABLE_CODELEN_OFFSET, ZDEBUG_TABLE_WORK_OFFSET): Define.
1308 (final_next_secondary): New static variable if
1309 BACKTRACE_GENERATE_FIXED_HUFFMAN_TABLE.
1310 (elf_zlib_inflate_table): New static function.
1311 (BACKTRACE_GENERATE_FIXED_HUFFMAN_TABLE): If define, define main
1312 function to produce fixed Huffman table.
1313 (elf_zlib_default_table): New static variable.
1314 (elf_zlib_inflate): New static function.
1315 (elf_zlib_verify_checksum): Likewise.
1316 (elf_zlib_inflate_and_verify): Likewise.
1317 (elf_uncompress_zdebug): Likewise.
1318 (elf_uncompress_chdr): Likewise.
1319 (backtrace_uncompress_zdebug): New extern function.
1320 (elf_add): Look for .zdebug sections and SHF_COMPRESSED debug
1321 sections, and uncompress them.
1322 * internal.h (backtrace_compress_zdebug): Declare.
1323 * ztest.c: New file.
1324 * configure.ac: Check for -lz and check whether the linker
1325 supports --compress-debug-sections.
1326 * Makefile.am (ztest_SOURCES): New variable.
1327 (ztest_CFLAGS, ztest_LDADD): New variables.
1328 (check_PROGRAMS): Add ztest.
1329 (ctestg_SOURCES): New variable.
1330 (ctestg_CFLAGS, ctestg_LDFLAGS, ctestg_LDADD): New variables.
1331 (ctesta_SOURCES): New variable.
1332 (ctesta_CFLAGS, ctesta_LDFLAGS, ctesta_LDADD): New variables.
1333 (check_PROGRAMS): Add ctestg and ctesta.
1334 * configure, config.h.in, Makefile.in: Rebuild.
1335
8c2ea6b2
ILT
13362017-09-22 Ian Lance Taylor <iant@golang.org>
1337
1338 PR sanitizer/77631
1339 * configure.ac: Check for lstat and readlink.
1340 * elf.c (lstat, readlink): Provide dummy versions if real versions
1341 are not available.
1342 * configure, config.h.in: Rebuild.
1343
f0de4542
ILT
13442017-09-21 Ian Lance Taylor <iant@google.com>
1345
1346 PR go/82284
1347 * elf.c (backtrace_initialize): Set pd.exe_filename.
1348
9283471b
ILT
13492017-09-20 Ian Lance Taylor <iant@golang.org>
1350 Denis Khalikov <d.khalikov@partner.samsung.com>
1351
1352 PR sanitizer/77631
1353 Support for external debug info.
1354 * elf.c: Include <errno.h>, <sys/stat.h>, <unistd.h>.
1355 (S_ISLNK): Define if not defined.
1356 (xstrnlen): Define if strnlen is not available.
1357 (b_elf_note): Define type.
1358 (NT_GNU_BUILD_ID): Define macro.
1359 (elf_crc32, elf_crc32_file): New static functions.
1360 (elf_is_symlink, elf_readlink): New static functions.
1361 (elf_open_debugfile_by_buildid): New static function.
1362 (elf_try_debugfile): New static function.
1363 (elf_find_debugfile_by_debuglink): New static function.
1364 (elf_open_debugfile_by_debuglink): New static function.
1365 (elf_add): Add filename and debuginfo parameters. Adjust all
1366 callers. Look for external debug info notes, and try to fetch
1367 debug info from external file.
1368 (struct phdr_data): Add exe_filename field.
1369 (phdr_callback): Pass filename to elf_add.
1370 (backtrace_initialize): Add filename parameter.
1371 * internal.h (backtrace_initialize): Add filename parameter.
1372 * fileline.c (fileline_initialize): Pass filename to
1373 backtrace_initialize.
1374 * pecoff.c (fileline_initialize): Add unused filename parameter.
1375 * unknown.c (fileline_initialize): Likewise.
1376 * xcoff.c (fileline_initialize): Likewise.
1377 * configure.ac: Check for objcopy --add-gnu-debuglink.
1378 * Makefile.am (dtest): New test target.
1379 * configure, Makefile.in: Rebuild.
1380
29788f90
SE
13812017-09-12 Steve Ellcey <sellcey@cavium.com>
1382
1383 PR other/81096
1384 * Makefile.am (ttest_CFLAGS): Add $(AM_CFLAGS)
1385 * Makefile.in: Regenerate.
1386
917a804c
SE
13872017-09-12 Steve Ellcey <sellcey@cavium.com>
1388
1389 PR other/81096
1390 * libbacktrace/Makefile.in
1391 (HAVE_PTHREAD_TRUE@@NATIVE_TRUE@ttest_CFLAGS): Add $(AM_CFLAGS)
1392
2e6af1b8
DE
13932017-08-02 David Edelsohn <dje.gcc@gmail.com>
1394
8a0e6224 1395 PR bootstrap/81638
2e6af1b8
DE
1396 * xcoff.c (xcoff_process_linenos): Initialize incl to NULL.
1397
afce7deb
TR
13982017-07-28 Tony Reix <tony.reix@atos.net>
1399
1400 * xcoff.c: Don't leak a file descriptor if an archive is malformed.
1401
cf311b03
RO
14022017-07-28 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1403
1404 * fileline.c (fileline_initialize): Print pid_t as long.
1405
7e2a8417
TR
14062017-07-26 Tony Reix <tony.reix@atos.net>
1407
1408 * configure.ac: Check for XCOFF32/XCOFF64. Check for loadquery.
1409 * filetype.awk: Separate AIX XCOFF32 and XCOFF64.
1410 * xcoff.c: Add support for AIX XCOFF32 and XCOFF64 formats.
1411 * configure, config.h.in: Regenerate.
1412
b3530b94
TR
14132017-07-21 Tony Reix <tony.reix@atos.net>
1414
1415 * filetype.awk: Add AIX XCOFF type detection.
1416 * configure.ac: Recognize xcoff format.
1417 * Makefile.am (FORMAT_FILES): Add xcoff.c.
1418 * fileline.c: Include <unistd.h>.
1419 (fileline_initialize): Add case for AIX procfs.
1420 * xcoff.c: New file.
1421 * configure, Makefile.in: Rebuild.
1422
e91a2ddc
RB
14232017-06-21 Richard Biener <rguenther@suse.de>
1424
1425 * configure.ac: Add AC_SYS_LARGEFILE.
1426 * config.h.in: Regenerate.
1427 * configure: Likewise.
1428
d1609a23
ILT
14292017-06-11 Ian Lance Taylor <iant@golang.org>
1430
1431 * elf.c (backtrace_initialize): Always set *fileline_fn.
1432 * ttest.c: New file.
1433 * btest.c: Move support functions into testlib.c. Change calls to
1434 check to pass file name.
1435 * testlib.c: New file, copied from (part of) btest.c.
1436 * testlib.h: New file, declarations for testlib.c.
1437 * edtest.c: Use testlib.h and testlib.c.
1438 * configure.ac: Test for -pthread, set HAVE_PTHREAD conditional.
1439 * Makefile.am (btest_SOURCES): Add testlib.c.
1440 (edtest_SOURCES): Likewise.
1441 (CHECK_PROGRAMS): Add ttest if HAVE_PTHREAD.
1442 (ttest_SOURCES, ttest_CFLAGS, ttest_LDADD): Define.
1443 * configure, Makefile.in: Rebuild.
1444
281161d1
TM
14452017-05-19 Than McIntosh <thanm@google.com>
1446
1447 * dwarf.c (free_line_header): Don't free dirs if dirs_count == 0.
1448 (read_line_header): Don't allocate dirs if dirs_count == 0.
1449 * edtest.c: New file.
1450 * edtest2.c: New file.
1451 * Makefile.am (edtest_SOURCES, edtest_LDADD): Define.
1452 (check_PROGRAMS): Add edtest.
1453 (edtest2_build.c, gen_edtest2_build): New targets.
1454 * Makefile.in: Rebuild.
1455
121eb024
ST
14562017-03-08 Sam Thursfield <sam.thursfield@codethink.co.uk>
1457
1458 * btest.c (test5): Replace #ifdef guard with 'unused' attribute
1459 to fix compile warning when BACKTRACE_SUPPORTED isn't defined.
1460
cbe34bb5
JJ
14612017-01-01 Jakub Jelinek <jakub@redhat.com>
1462
1463 Update copyright years.
1464
84c1b9d3
MK
14652016-11-15 Matthias Klose <doko@ubuntu.com>
1466
1467 * configure: Regenerate.
1468
84ebf639
CL
14692016-09-11 Carlos Liam <carlos@aarzee.me>
1470
1471 * all: Remove meaningless trailing whitespace.
1472
28644f75
UB
14732016-05-18 Uros Bizjak <ubizjak@gmail.com>
1474
1475 PR target/71161
1476 * elf.c (phdr_callback) [__i386__]: Add
1477 __attribute__((__force_align_arg_pointer__)).
1478
26ac52db
MO
14792016-03-02 Maxim Ostapenko <m.ostapenko@partner.samsung.com>
1480
1481 * elf.c (backtrace_initialize): Properly initialize elf_fileline_fn to
1482 avoid possible crash.
1483 (elf_add): Don't set *fileline_fn to elf_nodebug value in case of
1484 missing debug info anymore.
1485
09b08e17
JDA
14862016-02-06 John David Anglin <danglin@gcc.gnu.org>
1487
1488 * mmap.c (MAP_FAILED): Define if not defined.
1489
818ab71a
JJ
14902016-01-04 Jakub Jelinek <jakub@redhat.com>
1491
1492 Update copyright years.
1493
5b4bbc7d
AP
14942015-12-18 Andris Pavenis <andris.pavenis@iki.fi>
1495
28644f75
UB
1496 * configure.ac: Specify that DJGPP do not have mmap
1497 even when sys/mman.h exists.
5b4bbc7d
AP
1498 * configure: Regenerate
1499
2f401a8f
JDA
15002015-12-09 John David Anglin <danglin@gcc.gnu.org>
1501
28644f75 1502 PR libgfortran/68115
2f401a8f
JDA
1503 * configure.ac: Set libbacktrace_cv_sys_sync to no on hppa*-*-hpux*.
1504 * configure: Regenerate.
1505 * elf.c (backtrace_initialize): Cast __sync_bool_compare_and_swap call
1506 to void.
1507
750cdaf7
ILT
15082015-09-17 Ian Lance Taylor <iant@google.com>
1509
1510 * posix.c (backtrace_open): Cast second argument of open() to int.
1511
fc002444
ILT
15122015-09-11 Ian Lance Taylor <iant@google.com>
1513
1514 * Makefile.am (backtrace.lo): Depend on internal.h.
1515 (sort.lo, stest.lo): Add explicit dependencies.
1516 * Makefile.in: Rebuild.
1517
50809ff9
HPN
15182015-09-09 Hans-Peter Nilsson <hp@axis.com>
1519
1520 * backtrace.c: #include <sys/types.h>.
1521
c478516b
ILT
15222015-09-08 Ian Lance Taylor <iant@google.com>
1523
1524 PR other/67457
1525 * backtrace.c: #include "internal.h".
1526 (struct backtrace_data): Add can_alloc field.
1527 (unwind): If can_alloc is false, don't try to get file/line
1528 information.
1529 (backtrace_full): Set can_alloc field in bdata.
1530 * alloc.c (backtrace_alloc): Don't call error_callback if it is
1531 NULL.
1532 * mmap.c (backtrace_alloc): Likewise.
1533 * internal.h: Update comments for backtrace_alloc and
1534 backtrace_free.
1535
981d281f
ILT
15362015-09-08 Ian Lance Taylor <iant@google.com>
1537
1538 PR other/67457
1539 * mmap.c (backtrace_alloc): Correct test for mmap failure.
1540
8f5027bf
UW
15412015-08-31 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
1542
1543 * configure.ac: For spu-*-* targets, set have_fcntl to no.
1544 * configure: Regenerate.
1545
7e5c7547
UW
15462015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
1547
1548 * configure.ac: Remove [disable-shared] argument to LT_INIT.
1549 Remove setting PIC_FLAG when building as target library.
1550 * configure: Regenerate.
1551
7ce9cf39
HPN
15522015-08-26 Hans-Peter Nilsson <hp@axis.com>
1553
1554 * configure.ac: Only compile with -fPIC if the target
1555 supports it.
1556 * configure: Regenerate.
1557
1b533361
UW
15582015-08-24 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
1559
1560 * configure.ac: Set have_mmap to no on spu-*-* targets.
1561 * configure: Regenerate.
1562
d96fa208
ILT
15632015-08-13 Ian Lance Taylor <iant@google.com>
1564
1565 * dwarf.c (read_function_entry): Add vec_inlined parameter.
1566 Change all callers.
1567
d99a7b4d
MS
15682015-06-11 Martin Sebor <msebor@redhat.com>
1569
1570 PR sanitizer/65479
1571 * dwarf.c (struct line): Add new field idx.
1572 (line_compare): Use it.
1573 (add_line): Set it.
1574 (read_line_info): Reset it.
1575
e24afc10
TG
15762015-05-29 Tristan Gingold <gingold@adacore.com>
1577
1578 * pecoff.c: New file.
1579 * Makefile.am (FORMAT_FILES): Add pecoff.c and dependencies.
1580 * Makefile.in: Regenerate.
1581 * filetype.awk: Detect pecoff.
1582 * configure.ac: Define BACKTRACE_SUPPORTS_DATA on elf platforms.
1583 Add pecoff.
1584 * btest.c (test5): Test enabled only if BACKTRACE_SUPPORTS_DATA is
1585 true.
1586 * backtrace-supported.h.in (BACKTRACE_SUPPORTS_DATA): Define.
1587 * configure: Regenerate.
1588 * pecoff.c: New file.
1589
df96c0f7
MH
15902015-05-13 Michael Haubenwallner <michael.haubenwallner@ssi-schaefer.com>
1591
1592 * Makefile.in: Regenerated with automake-1.11.6.
1593 * aclocal.m4: Likewise.
1594 * configure: Likewise.
1595
2b8fa469
MK
15962015-01-24 Matthias Klose <doko@ubuntu.com>
1597
1598 * configure.ac: Move AM_ENABLE_MULTILIB before AC_PROG_CC.
1599 * configure: Regenerate.
1600
5624e564
JJ
16012015-01-05 Jakub Jelinek <jakub@redhat.com>
1602
1603 Update copyright years.
1604
a699d672
L
16052014-11-21 H.J. Lu <hongjiu.lu@intel.com>
1606
1607 PR bootstrap/63784
1608 * configure: Regenerated.
1609
35485da9
DM
16102014-11-11 David Malcolm <dmalcolm@redhat.com>
1611
1612 * ChangeLog.jit: New.
1613
ebf6d33b
FXC
16142014-11-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1615
1616 PR target/63610
1617 * configure: Regenerate.
1618
c96601d2
ILT
16192014-10-23 Ian Lance Taylor <iant@google.com>
1620
1621 * internal.h (backtrace_atomic_load_pointer) [no atomic or sync]:
1622 Fix to return void *.
1623
d573fd89
ILT
16242014-05-08 Ian Lance Taylor <iant@google.com>
1625
1626 * mmap.c (backtrace_free): If freeing a large aligned block of
1627 memory, call munmap rather than holding onto it.
1628 (backtrace_vector_grow): When growing a vector, double the number
1629 of pages requested. When releasing the old version of a grown
1630 vector, pass the correct size to backtrace_free.
1631
dbe20842
ILT
16322014-03-07 Ian Lance Taylor <iant@google.com>
1633
1634 * sort.c (backtrace_qsort): Use middle element as pivot.
1635
c5604b48
ILT
16362014-03-06 Ian Lance Taylor <iant@google.com>
1637
1638 * sort.c: New file.
1639 * stest.c: New file.
1640 * internal.h (backtrace_qsort): Declare.
1641 * dwarf.c (read_abbrevs): Call backtrace_qsort instead of qsort.
1642 (read_line_info, read_function_entry): Likewise.
1643 (read_function_info, build_dwarf_data): Likewise.
1644 * elf.c (elf_initialize_syminfo): Likewise.
1645 * Makefile.am (libbacktrace_la_SOURCES): Add sort.c.
1646 (stest_SOURCES, stest_LDADD): Define.
1647 (check_PROGRAMS): Add stest.
1648
63fefb4b
MDM
16492014-02-07 Misty De Meo <misty@brew.sh>
1650
1651 PR target/58710
1652 * configure.ac: Use AC_LINK_IFELSE in check for
1653 _Unwind_GetIPInfo.
1654 * configure: Regenerate.
1655
afeba5cb
RS
16562014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
1657
1658 Update copyright years
1659
0284b52e
JJ
16602013-12-06 Jakub Jelinek <jakub@redhat.com>
1661
1662 * elf.c (ET_DYN): Undefine and define again.
1663 (elf_add): Add exe argument, if true and ehdr.e_type is ET_DYN,
1664 return early -1 without closing the descriptor.
1665 (struct phdr_data): Add exe_descriptor.
1666 (phdr_callback): If pd->exe_descriptor is not -1, for very first
1667 call if dlpi_name is NULL just call elf_add with the exe_descriptor,
1668 otherwise backtrace_close the exe_descriptor if not -1. Adjust
1669 call to elf_add.
1670 (backtrace_initialize): Adjust call to elf_add. If it returns
1671 -1, set pd.exe_descriptor to descriptor, otherwise set it to -1.
1672
bfd74f22
ILT
16732013-12-05 Ian Lance Taylor <iant@google.com>
1674
1675 * alloc.c (backtrace_vector_finish): Add error_callback and data
1676 parameters. Call backtrace_vector_release. Return address base.
1677 * mmap.c (backtrace_vector_finish): Add error_callback and data
1678 parameters. Return address base.
1679 * dwarf.c (read_function_info): Get new address base from
1680 backtrace_vector_finish.
1681 * internal.h (backtrace_vector_finish): Update declaration.
1682
b8ddd61b
ILT
16832013-11-27 Ian Lance Taylor <iant@google.com>
1684
1685 * dwarf.c (find_address_ranges): New static function, broken out
1686 of build_address_map.
1687 (build_address_map): Call it.
1688 * btest.c (check): Check for missing filename or function, rather
1689 than crashing.
1690 (f3): Check that enough frames were returned.
1691
64856e1e
JJ
16922013-11-19 Jakub Jelinek <jakub@redhat.com>
1693
1f96a712
JJ
1694 * backtrace.h (backtrace_syminfo_callback): Add symsize argument.
1695 * elf.c (elf_syminfo): Pass 0 or sym->size to the callback as
1696 last argument.
1697 * btest.c (struct symdata): Add size field.
1698 (callback_three): Add symsize argument. Copy it to the data->size
1699 field.
1700 (f23): Set symdata.size to 0.
1701 (test5): Likewise. If sizeof (int) > 1, lookup address of
1702 ((uintptr_t) &global) + 1. Verify symdata.val and symdata.size
1703 values.
1704
64856e1e
JJ
1705 * atomic.c: Include sys/types.h.
1706
49579c7e
ILT
17072013-11-18 Ian Lance Taylor <iant@google.com>
1708
1709 * configure.ac: Check for support of __atomic extensions.
1710 * internal.h: Declare or #define atomic functions for use in
1711 backtrace code.
1712 * atomic.c: New file.
1713 * dwarf.c (dwarf_lookup_pc): Use atomic functions.
1714 (dwarf_fileline, backtrace_dwarf_add): Likewise.
1715 * elf.c (elf_add_syminfo_data, elf_syminfo): Likewise.
1716 (backtrace_initialize): Likewise.
1717 * fileline.c (fileline_initialize): Likewise.
1718 * Makefile.am (libbacktrace_la_SOURCES): Add atomic.c.
1719 * configure, config.h.in, Makefile.in: Rebuild.
1720
582f5a2d
JJ
17212013-11-18 Jakub Jelinek <jakub@redhat.com>
1722
f1857815
JJ
1723 * elf.c (SHN_UNDEF): Define.
1724 (elf_initialize_syminfo): Add base_address argument. Ignore symbols
1725 with st_shndx == SHN_UNDEF. Add base_address to address fields.
1726 (elf_add): Adjust caller.
1727
582f5a2d
JJ
1728 * elf.c (phdr_callback): Process info->dlpi_addr == 0 normally.
1729
25e6253e
ILT
17302013-11-16 Ian Lance Taylor <iant@google.com>
1731
1732 * backtrace.h (backtrace_create_state): Correct comment about
1733 threading.
1734
cfa658e4
ILT
17352013-11-15 Ian Lance Taylor <iant@google.com>
1736
1737 * backtrace.h (backtrace_syminfo): Update comment and parameter
1738 name to take any address, not just a PC value.
1739 * elf.c (STT_OBJECT): Define.
1740 (elf_nosyms): Rename parameter pc to addr.
1741 (elf_symbol_search): Rename local variable pc to addr.
1742 (elf_initialize_syminfo): Add STT_OBJECT symbols to elf_symbols.
1743 (elf_syminfo): Rename parameter pc to addr.
1744 * btest.c (global): New global variable.
1745 (test5): New test.
1746 (main): Call test5.
1747
6c084a5b
ILT
17482013-10-17 Ian Lance Taylor <iant@google.com>
1749
1750 * elf.c (elf_add): Don't get the wrong offsets if a debug section
1751 is missing.
1752
459260ec
DM
17532013-10-15 David Malcolm <dmalcolm@redhat.com>
1754
1755 * configure.ac: Add --enable-host-shared, setting up
1756 pre-existing PIC_FLAG variable within Makefile.am et al.
1757 * configure: Regenerate.
1758
3cbe17f7
AM
17592013-09-20 Alan Modra <amodra@gmail.com>
1760
1761 * configure: Regenerate.
1762
78625ce6
AM
17632013-07-23 Alexander Monakov <amonakov@ispras.ru>
1764
1765 * elf.c (elf_syminfo): Loop over the elf_syminfo_data chain.
1766
0153887c
AM
17672013-07-23 Alexander Monakov <amonakov@ispras.ru>
1768
1769 * elf.c (backtrace_initialize): Pass elf_fileline_fn to
1770 dl_iterate_phdr callbacks.
1771
85d8c21e
ILT
17722013-03-25 Ian Lance Taylor <iant@google.com>
1773
1774 * alloc.c: #include <sys/types.h>.
1775 * mmap.c: Likewise.
1776
38811401
ILT
17772013-01-31 Ian Lance Taylor <iant@google.com>
1778
1779 * dwarf.c (read_function_info): Permit fvec parameter to be NULL.
1780 (dwarf_lookup_pc): Don't use ddata->fvec if threaded.
1781
1e678aed
JJ
17822013-01-25 Jakub Jelinek <jakub@redhat.com>
1783
1784 PR other/56076
1785 * dwarf.c (read_line_header): Don't crash if DW_AT_comp_dir
1786 attribute was not seen.
1787
6b514c53
ILT
17882013-01-16 Ian Lance Taylor <iant@google.com>
1789
1790 * dwarf.c (struct unit): Add filename and abs_filename fields.
1791 (build_address_map): Set new fields when reading unit.
1792 (dwarf_lookup_pc): If we don't find an entry in the line table,
1793 just return the main file name.
1794
f8a7e1a4
RS
17952013-01-14 Richard Sandiford <rdsandiford@googlemail.com>
1796
1797 Update copyright years.
1798
c3de1960
ILT
17992013-01-01 Ian Lance Taylor <iant@google.com>
1800
1801 PR bootstrap/54834
1802 * Makefile.am (AM_CPPFLAGS): Remove -I ../gcc/include and -I
1803 $(MULTIBUILDTOP)/../../gcc/include.
1804 * Makefile.in: Rebuild.
1805
2a5195d9
ILT
18062013-01-01 Ian Lance Taylor <iant@google.com>
1807
1808 PR other/55536
1809 * mmap.c (backtrace_alloc): Don't call sync functions if not
1810 threaded.
1811 (backtrace_free): Likewise.
1812
85619b6f
JDA
18132012-12-12 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
1814
1815 * mmapio.c: Define MAP_FAILED if not defined.
1816
36a58fb3
JJ
18172012-12-11 Jakub Jelinek <jakub@redhat.com>
1818
1819 PR bootstrap/54926
1820 * Makefile.am (AM_CFLAGS): Remove -frandom-seed=$@.
1821 * configure.ac: If --with-target-subdir, add -frandom-seed=$@
1822 to EXTRA_FLAGS unconditionally, otherwise check whether the compiler
1823 accepts it.
1824 * Makefile.in: Regenerated.
1825 * configure: Regenerated.
1826
a58dfde0
JJ
18272012-12-07 Jakub Jelinek <jakub@redhat.com>
1828
1829 PR bootstrap/54926
1830 * Makefile.am (AM_CFLAGS): Add -frandom-seed=$@.
1831 * Makefile.in: Regenerated.
1832
b20ade36
ILT
18332012-11-20 Ian Lance Taylor <iant@google.com>
1834
1835 * dwarf.c (read_attribute): Always clear val.
1836
73c3ed27
ILT
18372012-11-13 Ian Lance Taylor <iant@google.com>
1838
1839 PR other/55312
1840 * configure.ac: Only add -Werror if building a target library.
2a5195d9 1841 * configure: Rebuild.
73c3ed27 1842
33521509
ILT
18432012-11-12 Ian Lance Taylor <iant@google.com>
1844 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1845 Gerald Pfeifer <gerald@pfeifer.com>
1846
1847 * configure.ac: Check for getexecname.
1848 * fileline.c: #include <errno.h>. Define getexecname if not
1849 available.
1850 (fileline_initialize): Try to find the executable in a few
1851 different ways.
1852 * print.c (error_callback): Only print the filename if it came
1853 from the backtrace state.
1854 * configure, config.h.in: Rebuild.
1855
8fe91dea
ILT
18562012-10-29 Ian Lance Taylor <iant@google.com>
1857
1858 * mmap.c (backtrace_vector_release): Correct last patch: add
1859 aligned, not size.
1860
8277de34
ILT
18612012-10-29 Ian Lance Taylor <iant@google.com>
1862
1863 * mmap.c (backtrace_vector_release): Make sure freed block is
1864 aligned on 8-byte boundary.
1865
73f41491
ILT
18662012-10-26 Ian Lance Taylor <iant@google.com>
1867
1868 PR other/55087
1869 * posix.c (backtrace_open): Add does_not_exist parameter.
1870 * elf.c (phdr_callback): Do not warn if shared library could not
1871 be opened.
1872 * fileline.c (fileline_initialize): Update calls to
1873 backtrace_open.
1874 * internal.h (backtrace_open): Update declaration.
1875
385710cf
JH
18762012-10-26 Jack Howarth <howarth@bromo.med.uc.edu>
1877
1878 PR target/55061
1879 * configure.ac: Check for _Unwind_GetIPInfo function declaration.
1880 * configure: Regenerate.
1881
32061319
ILT
18822012-10-24 Ian Lance Taylor <iant@google.com>
1883
1884 PR target/55061
1885 * configure.ac: Check whether -funwind-tables option works.
1886 * configure: Rebuild.
1887
5551b12c
ILT
18882012-10-11 Ian Lance Taylor <iant@google.com>
1889
1890 * configure.ac: Do not use dl_iterate_phdr on Solaris 10.
1891 * configure: Rebuild.
1892
40d15b5b
ILT
18932012-10-10 Ian Lance Taylor <iant@google.com>
1894
1895 * elf.c: Rename all Elf typedefs to start with b_elf, and be all
1896 lower case.
1897
74f80620
HPN
18982012-10-10 Hans-Peter Nilsson <hp@bitrange.com>
1899
1900 * elf.c (elf_add_syminfo_data): Add casts to avoid warning.
1901
ce8aa074
ILT
19022012-10-09 Ian Lance Taylor <iant@google.com>
1903
1904 * dwarf.c (dwarf_fileline): Add cast to avoid warning.
1905 (backtrace_dwarf_add): Likewise.
1906
e561a992
ILT
19072012-10-09 Ian Lance Taylor <iant@google.com>
1908
1909 Add support for tracing through shared libraries.
1910 * configure.ac: Check for link.h and dl_iterate_phdr.
1911 * elf.c: #include <link.h> if system has dl_iterate_phdr. #undef
1912 ELF macros before #defining them.
1913 (dl_phdr_info, dl_iterate_phdr): Define if system does not have
1914 dl_iterate_phdr.
1915 (struct elf_syminfo_data): Add next field.
1916 (elf_initialize_syminfo): Initialize next field.
1917 (elf_add_syminfo_data): New static function.
1918 (elf_add): New static function, broken out of
1919 backtrace_initialize. Call backtrace_dwarf_add instead of
1920 backtrace_dwarf_initialize.
1921 (struct phdr_data): Define.
1922 (phdr_callback): New static function.
1923 (backtrace_initialize): Call elf_add.
1924 * dwarf.c (struct dwarf_data): Add next and base_address fields.
1925 (add_unit_addr): Add base_address parameter. Change all callers.
1926 (add_unit_ranges, build_address_map): Likewise.
1927 (add_line): Add ddata parameter. Change all callers.
1928 (read_line_program, add_function_range): Likewise.
1929 (dwarf_lookup_pc): New static function, broken out of
1930 dwarf_fileline.
1931 (dwarf_fileline): Call dwarf_lookup_pc.
1932 (build_dwarf_data): New static function.
1933 (backtrace_dwarf_add): New function.
1934 (backtrace_dwarf_initialize): Remove.
1935 * internal.h (backtrace_dwarf_initialize): Don't declare.
1936 (backtrace_dwarf_add): Declare.
1937 * configure, config.h.in: Rebuild.
1938
068ef6d1
GP
19392012-10-04 Gerald Pfeifer <gerald@pfeifer.com>
1940
1941 * btest.c (f23): Avoid uninitialized variable warning.
e561a992 1942
244e2d9c
ILT
19432012-10-04 Ian Lance Taylor <iant@google.com>
1944
1945 * dwarf.c: If the system header files do not declare strnlen,
1946 provide our own version.
1947
be4ba8ae
ILT
19482012-10-03 Ian Lance Taylor <iant@google.com>
1949
1950 * dwarf.c (read_uleb128): Fix overflow test.
1951 (read_sleb128): Likewise.
1952 (build_address_map): Don't change unit_buf.start.
1953
56195009
UB
19542012-10-02 Uros Bizjak <ubizjak@gmail.com>
1955
faf86a02
UB
1956 PR other/54761
1957 * configure.ac (EXTRA_FLAGS): New.
56195009 1958 * Makefile.am (AM_FLAGS): Add $(EXTRA_FLAGS).
faf86a02 1959 * configure, Makefile.in: Regenerate.
56195009 1960
8a447b3d
ILT
19612012-09-29 Ian Lance Taylor <iant@google.com>
1962
1963 PR other/54749
1964 * fileline.c (fileline_initialize): Pass errnum as -1 when
1965 reporting that we could not read executable information after a
1966 previous failure.
1967
af710874
ILT
19682012-09-27 Ian Lance Taylor <iant@google.com>
1969
1970 PR bootstrap/54732
1971 * configure.ac: Add no-dependencies to AM_INIT_AUTOMAKE.
1972 * Makefile.am: Add dependencies for all objects.
1973 * configure, aclocal.m4, Makefile.in: Rebuild.
1974
588f4f8f
ILT
19752012-09-27 Ian Lance Taylor <iant@google.com>
1976
1977 PR other/54726
1978 * elf.c (backtrace_initialize): Set *fileln_fn, not
1979 state->fileln_fn.
1980
64b89453
ILT
19812012-09-19 Ian Lance Taylor <iant@google.com>
1982
1983 * configure.ac: Only use GCC_CHECK_UNWIND_GETIPINFO when compiled
1984 as a target library.
1985 * configure: Rebuild.
1986
76850556
RO
19872012-09-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1988 Ian Lance Taylor <iant@google.com>
1989
92a285c1
ML
1990 * configure.ac (GCC_HEADER_STDINT): Invoke.
1991 * backtrace.h: If we can't find <stdint.h>, use "gstdint.h".
1992 * btest.c: Don't include <stdint.h>.
1993 * dwarf.c: Likewise.
1994 * configure, aclocal.m4, Makefile.in, config.h.in: Rebuild.
76850556 1995
9425c00b
ILT
19962012-09-18 Ian Lance Taylor <iant@google.com>
1997
1998 PR bootstrap/54623
1999 * Makefile.am (AM_CPPFLAGS): Define.
2000 (AM_CFLAGS): Remove -I options.
2001 * Makefile.in: Rebuild.
2002
3319ef17
ILT
20032012-09-18 Ian Lance Taylor <iant@google.com>
2004
2005 * posix.c (O_BINARY): Define if not defined.
2006 (backtrace_open): Pass O_BINARY to open. Only call fcntl if
2007 HAVE_FCNTL is defined.
2008 * configure.ac: Test for the fcntl function.
2009 * configure, config.h.in: Rebuild.
2010
bd3e497d
ILT
20112012-09-18 Ian Lance Taylor <iant@google.com>
2012
2013 * btest.c (test1, test2, test3, test4): Add the unused attribute.
2014
30e15876
ILT
20152012-09-18 Ian Lance Taylor <iant@google.com>
2016
2017 * dwarf.c: Correct test of HAVE_DECL_STRNLEN.
2018
d4c059d5
ILT
20192012-09-18 Ian Lance Taylor <iant@google.com>
2020
2021 * configure.ac: Add AC_USE_SYSTEM_EXTENSIONS.
2022 * mmapio.c: Don't define _GNU_SOURCE.
2023 * configure, config.h.in: Rebuild.
2024
772a71a9
ILT
20252012-09-18 Ian Lance Taylor <iant@google.com>
2026
2027 * configure.ac: Check whether strnlen is declared.
2028 * dwarf.c: Declare strnlen if not declared.
2029 * configure, config.h.in: Rebuild.
2030
c0558468
RO
20312012-09-18 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2032
2033 * fileline.c: Include <stdlib.h>.
2034 * mmap.c: Likewise.
2035
c5812e0b
ILT
20362012-09-17 Ian Lance Taylor <iant@google.com>
2037
2038 PR bootstrap/54611
2039 * nounwind.c (backtrace_full): Rename from backtrace. Add state
2040 parameter.
2041
e8f4008a
GP
20422012-09-17 Gerald Pfeifer <gerald@pfeifer.com>
2043
2044 PR bootstrap/54611
2045 * nounwind.c (backtrace_simple): Add state parameter.
2046
f588eb27
ILT
20472012-09-17 Ian Lance Taylor <iant@google.com>
2048
2049 PR bootstrap/54609
2050 * unknown.c (unknown_fileline): Add state parameter, remove
2051 fileline_data parameter, name error_callback parameter.
2052 (backtrace_initialize): Add state parameter.
2053
eff02e4f
ILT
20542012-09-17 Ian Lance Taylor <iant@google.com>
2055
2056 * Initial implementation.
818ab71a 2057\f
6a720d41 2058Copyright (C) 2012-2024 Free Software Foundation, Inc.
818ab71a
JJ
2059
2060Copying and distribution of this file, with or without modification,
2061are permitted in any medium without royalty provided the copyright
2062notice and this notice are preserved.