Merged revisions 209304,209307,209332,209338-209339,209343,209346,209351,209354,20936...
[official-gcc.git] / gcc-4_9 / libbacktrace / ChangeLog
blob5dfe80b387c02a8181d7dbdbed7777b8389ab4da
1 2014-04-22  Release Manager
3         * GCC 4.9.0 released.
5 2014-03-07  Ian Lance Taylor  <iant@google.com>
7         * sort.c (backtrace_qsort): Use middle element as pivot.
9 2014-03-06  Ian Lance Taylor  <iant@google.com>
11         * sort.c: New file.
12         * stest.c: New file.
13         * internal.h (backtrace_qsort): Declare.
14         * dwarf.c (read_abbrevs): Call backtrace_qsort instead of qsort.
15         (read_line_info, read_function_entry): Likewise.
16         (read_function_info, build_dwarf_data): Likewise.
17         * elf.c (elf_initialize_syminfo): Likewise.
18         * Makefile.am (libbacktrace_la_SOURCES): Add sort.c.
19         (stest_SOURCES, stest_LDADD): Define.
20         (check_PROGRAMS): Add stest.
22 2014-02-07  Misty De Meo  <misty@brew.sh>
24         PR target/58710
25         * configure.ac: Use AC_LINK_IFELSE in check for
26         _Unwind_GetIPInfo.
27         * configure: Regenerate.
29 2014-01-02  Richard Sandiford  <rdsandiford@googlemail.com>
31         Update copyright years
33 2013-12-06  Jakub Jelinek  <jakub@redhat.com>
35         * elf.c (ET_DYN): Undefine and define again.
36         (elf_add): Add exe argument, if true and ehdr.e_type is ET_DYN,
37         return early -1 without closing the descriptor.
38         (struct phdr_data): Add exe_descriptor.
39         (phdr_callback): If pd->exe_descriptor is not -1, for very first
40         call if dlpi_name is NULL just call elf_add with the exe_descriptor,
41         otherwise backtrace_close the exe_descriptor if not -1.  Adjust
42         call to elf_add.
43         (backtrace_initialize): Adjust call to elf_add.  If it returns
44         -1, set pd.exe_descriptor to descriptor, otherwise set it to -1.
46 2013-12-05  Ian Lance Taylor  <iant@google.com>
48         * alloc.c (backtrace_vector_finish): Add error_callback and data
49         parameters.  Call backtrace_vector_release.  Return address base.
50         * mmap.c (backtrace_vector_finish): Add error_callback and data
51         parameters.  Return address base.
52         * dwarf.c (read_function_info): Get new address base from
53         backtrace_vector_finish.
54         * internal.h (backtrace_vector_finish): Update declaration.
56 2013-11-27  Ian Lance Taylor  <iant@google.com>
58         * dwarf.c (find_address_ranges): New static function, broken out
59         of build_address_map.
60         (build_address_map): Call it.
61         * btest.c (check): Check for missing filename or function, rather
62         than crashing.
63         (f3): Check that enough frames were returned.
65 2013-11-19  Jakub Jelinek  <jakub@redhat.com>
67         * backtrace.h (backtrace_syminfo_callback): Add symsize argument.
68         * elf.c (elf_syminfo): Pass 0 or sym->size to the callback as
69         last argument.
70         * btest.c (struct symdata): Add size field.
71         (callback_three): Add symsize argument.  Copy it to the data->size
72         field.
73         (f23): Set symdata.size to 0.
74         (test5): Likewise.  If sizeof (int) > 1, lookup address of
75         ((uintptr_t) &global) + 1.  Verify symdata.val and symdata.size
76         values.
78         * atomic.c: Include sys/types.h.
80 2013-11-18  Ian Lance Taylor  <iant@google.com>
82         * configure.ac: Check for support of __atomic extensions.
83         * internal.h: Declare or #define atomic functions for use in
84         backtrace code.
85         * atomic.c: New file.
86         * dwarf.c (dwarf_lookup_pc): Use atomic functions.
87         (dwarf_fileline, backtrace_dwarf_add): Likewise.
88         * elf.c (elf_add_syminfo_data, elf_syminfo): Likewise.
89         (backtrace_initialize): Likewise.
90         * fileline.c (fileline_initialize): Likewise.
91         * Makefile.am (libbacktrace_la_SOURCES): Add atomic.c.
92         * configure, config.h.in, Makefile.in: Rebuild.
94 2013-11-18  Jakub Jelinek  <jakub@redhat.com>
96         * elf.c (SHN_UNDEF): Define.
97         (elf_initialize_syminfo): Add base_address argument.  Ignore symbols
98         with st_shndx == SHN_UNDEF.  Add base_address to address fields.
99         (elf_add): Adjust caller.
101         * elf.c (phdr_callback): Process info->dlpi_addr == 0 normally.
103 2013-11-16  Ian Lance Taylor  <iant@google.com>
105         * backtrace.h (backtrace_create_state): Correct comment about
106         threading.
108 2013-11-15  Ian Lance Taylor  <iant@google.com>
110         * backtrace.h (backtrace_syminfo): Update comment and parameter
111         name to take any address, not just a PC value.
112         * elf.c (STT_OBJECT): Define.
113         (elf_nosyms): Rename parameter pc to addr.
114         (elf_symbol_search): Rename local variable pc to addr.
115         (elf_initialize_syminfo): Add STT_OBJECT symbols to elf_symbols.
116         (elf_syminfo): Rename parameter pc to addr.
117         * btest.c (global): New global variable.
118         (test5): New test.
119         (main): Call test5.
121 2013-10-17  Ian Lance Taylor  <iant@google.com>
123         * elf.c (elf_add): Don't get the wrong offsets if a debug section
124         is missing.
126 2013-10-15  David Malcolm  <dmalcolm@redhat.com>
128         * configure.ac: Add --enable-host-shared, setting up
129         pre-existing PIC_FLAG variable within Makefile.am et al.
130         * configure: Regenerate.
132 2013-09-20  Alan Modra  <amodra@gmail.com>
134         * configure: Regenerate.
136 2013-07-23  Alexander Monakov  <amonakov@ispras.ru>
138         * elf.c (elf_syminfo): Loop over the elf_syminfo_data chain.
140 2013-07-23  Alexander Monakov  <amonakov@ispras.ru>
142         * elf.c (backtrace_initialize): Pass elf_fileline_fn to
143         dl_iterate_phdr callbacks.
145 2013-03-25  Ian Lance Taylor  <iant@google.com>
147         * alloc.c: #include <sys/types.h>.
148         * mmap.c: Likewise.
150 2013-01-31  Ian Lance Taylor  <iant@google.com>
152         * dwarf.c (read_function_info): Permit fvec parameter to be NULL.
153         (dwarf_lookup_pc): Don't use ddata->fvec if threaded.
155 2013-01-25  Jakub Jelinek  <jakub@redhat.com>
157         PR other/56076
158         * dwarf.c (read_line_header): Don't crash if DW_AT_comp_dir
159         attribute was not seen.
161 2013-01-16  Ian Lance Taylor  <iant@google.com>
163         * dwarf.c (struct unit): Add filename and abs_filename fields.
164         (build_address_map): Set new fields when reading unit.
165         (dwarf_lookup_pc): If we don't find an entry in the line table,
166         just return the main file name.
168 2013-01-14  Richard Sandiford  <rdsandiford@googlemail.com>
170         Update copyright years.
172 2013-01-01  Ian Lance Taylor  <iant@google.com>
174         PR bootstrap/54834
175         * Makefile.am (AM_CPPFLAGS): Remove -I ../gcc/include and -I
176         $(MULTIBUILDTOP)/../../gcc/include.
177         * Makefile.in: Rebuild.
179 2013-01-01  Ian Lance Taylor  <iant@google.com>
181         PR other/55536
182         * mmap.c (backtrace_alloc): Don't call sync functions if not
183         threaded.
184         (backtrace_free): Likewise.
186 2012-12-12  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
188         * mmapio.c: Define MAP_FAILED if not defined.
190 2012-12-11  Jakub Jelinek  <jakub@redhat.com>
192         PR bootstrap/54926
193         * Makefile.am (AM_CFLAGS): Remove -frandom-seed=$@.
194         * configure.ac: If --with-target-subdir, add -frandom-seed=$@
195         to EXTRA_FLAGS unconditionally, otherwise check whether the compiler
196         accepts it.
197         * Makefile.in: Regenerated.
198         * configure: Regenerated.
200 2012-12-07  Jakub Jelinek  <jakub@redhat.com>
202         PR bootstrap/54926
203         * Makefile.am (AM_CFLAGS): Add -frandom-seed=$@.
204         * Makefile.in: Regenerated.
206 2012-11-20  Ian Lance Taylor  <iant@google.com>
208         * dwarf.c (read_attribute): Always clear val.
210 2012-11-13  Ian Lance Taylor  <iant@google.com>
212         PR other/55312
213         * configure.ac: Only add -Werror if building a target library.
214         * configure: Rebuild.
216 2012-11-12  Ian Lance Taylor  <iant@google.com>
217             Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
218             Gerald Pfeifer  <gerald@pfeifer.com>
220         * configure.ac: Check for getexecname.
221         * fileline.c: #include <errno.h>.  Define getexecname if not
222         available.
223         (fileline_initialize): Try to find the executable in a few
224         different ways.
225         * print.c (error_callback): Only print the filename if it came
226         from the backtrace state.
227         * configure, config.h.in: Rebuild.
229 2012-10-29  Ian Lance Taylor  <iant@google.com>
231         * mmap.c (backtrace_vector_release): Correct last patch: add
232         aligned, not size.
234 2012-10-29  Ian Lance Taylor  <iant@google.com>
236         * mmap.c (backtrace_vector_release): Make sure freed block is
237         aligned on 8-byte boundary.
239 2012-10-26  Ian Lance Taylor  <iant@google.com>
241         PR other/55087
242         * posix.c (backtrace_open): Add does_not_exist parameter.
243         * elf.c (phdr_callback): Do not warn if shared library could not
244         be opened.
245         * fileline.c (fileline_initialize): Update calls to
246         backtrace_open.
247         * internal.h (backtrace_open): Update declaration.
249 2012-10-26  Jack Howarth  <howarth@bromo.med.uc.edu>
251         PR target/55061
252         * configure.ac: Check for _Unwind_GetIPInfo function declaration.
253         * configure: Regenerate.
255 2012-10-24  Ian Lance Taylor  <iant@google.com>
257         PR target/55061
258         * configure.ac: Check whether -funwind-tables option works.
259         * configure: Rebuild.
261 2012-10-11  Ian Lance Taylor  <iant@google.com>
263         * configure.ac: Do not use dl_iterate_phdr on Solaris 10.
264         * configure: Rebuild.
266 2012-10-10  Ian Lance Taylor  <iant@google.com>
268         * elf.c: Rename all Elf typedefs to start with b_elf, and be all
269         lower case.
271 2012-10-10  Hans-Peter Nilsson  <hp@bitrange.com>
273         * elf.c (elf_add_syminfo_data): Add casts to avoid warning.
275 2012-10-09  Ian Lance Taylor  <iant@google.com>
277         * dwarf.c (dwarf_fileline): Add cast to avoid warning.
278         (backtrace_dwarf_add): Likewise.
280 2012-10-09  Ian Lance Taylor  <iant@google.com>
282         Add support for tracing through shared libraries.
283         * configure.ac: Check for link.h and dl_iterate_phdr.
284         * elf.c: #include <link.h> if system has dl_iterate_phdr.  #undef
285         ELF macros before #defining them.
286         (dl_phdr_info, dl_iterate_phdr): Define if system does not have
287         dl_iterate_phdr.
288         (struct elf_syminfo_data): Add next field.
289         (elf_initialize_syminfo): Initialize next field.
290         (elf_add_syminfo_data): New static function.
291         (elf_add): New static function, broken out of
292         backtrace_initialize.  Call backtrace_dwarf_add instead of
293         backtrace_dwarf_initialize.
294         (struct phdr_data): Define.
295         (phdr_callback): New static function.
296         (backtrace_initialize): Call elf_add.
297         * dwarf.c (struct dwarf_data): Add next and base_address fields.
298         (add_unit_addr): Add base_address parameter.  Change all callers.
299         (add_unit_ranges, build_address_map): Likewise.
300         (add_line): Add ddata parameter.  Change all callers.
301         (read_line_program, add_function_range): Likewise.
302         (dwarf_lookup_pc): New static function, broken out of
303         dwarf_fileline.
304         (dwarf_fileline): Call dwarf_lookup_pc.
305         (build_dwarf_data): New static function.
306         (backtrace_dwarf_add): New function.
307         (backtrace_dwarf_initialize): Remove.
308         * internal.h (backtrace_dwarf_initialize): Don't declare.
309         (backtrace_dwarf_add): Declare.
310         * configure, config.h.in: Rebuild.
312 2012-10-04  Gerald Pfeifer  <gerald@pfeifer.com>
314         * btest.c (f23): Avoid uninitialized variable warning.
316 2012-10-04  Ian Lance Taylor  <iant@google.com>
318         * dwarf.c: If the system header files do not declare strnlen,
319         provide our own version.
321 2012-10-03  Ian Lance Taylor  <iant@google.com>
323         * dwarf.c (read_uleb128): Fix overflow test.
324         (read_sleb128): Likewise.
325         (build_address_map): Don't change unit_buf.start.
327 2012-10-02  Uros Bizjak  <ubizjak@gmail.com>
329         PR other/54761
330         * configure.ac (EXTRA_FLAGS): New.
331         * Makefile.am (AM_FLAGS): Add $(EXTRA_FLAGS).
332         * configure, Makefile.in: Regenerate.
334 2012-09-29  Ian Lance Taylor  <iant@google.com>
336         PR other/54749
337         * fileline.c (fileline_initialize): Pass errnum as -1 when
338         reporting that we could not read executable information after a
339         previous failure.
341 2012-09-27  Ian Lance Taylor  <iant@google.com>
343         PR bootstrap/54732
344         * configure.ac: Add no-dependencies to AM_INIT_AUTOMAKE.
345         * Makefile.am: Add dependencies for all objects.
346         * configure, aclocal.m4, Makefile.in: Rebuild.
348 2012-09-27  Ian Lance Taylor  <iant@google.com>
350         PR other/54726
351         * elf.c (backtrace_initialize): Set *fileln_fn, not
352         state->fileln_fn.
354 2012-09-19  Ian Lance Taylor  <iant@google.com>
356         * configure.ac: Only use GCC_CHECK_UNWIND_GETIPINFO when compiled
357         as a target library.
358         * configure: Rebuild.
360 2012-09-19  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
361             Ian Lance Taylor  <iant@google.com>
363         * configure.ac (GCC_HEADER_STDINT): Invoke.
364         * backtrace.h: If we can't find <stdint.h>, use "gstdint.h".
365         * btest.c: Don't include <stdint.h>.
366         * dwarf.c: Likewise.
367         * configure, aclocal.m4, Makefile.in, config.h.in: Rebuild.
369 2012-09-18  Ian Lance Taylor  <iant@google.com>
371         PR bootstrap/54623
372         * Makefile.am (AM_CPPFLAGS): Define.
373         (AM_CFLAGS): Remove -I options.
374         * Makefile.in: Rebuild.
376 2012-09-18  Ian Lance Taylor  <iant@google.com>
378         * posix.c (O_BINARY): Define if not defined.
379         (backtrace_open): Pass O_BINARY to open.  Only call fcntl if
380         HAVE_FCNTL is defined.
381         * configure.ac: Test for the fcntl function.
382         * configure, config.h.in: Rebuild.
384 2012-09-18  Ian Lance Taylor  <iant@google.com>
386         * btest.c (test1, test2, test3, test4): Add the unused attribute.
388 2012-09-18  Ian Lance Taylor  <iant@google.com>
390         * dwarf.c: Correct test of HAVE_DECL_STRNLEN.
392 2012-09-18  Ian Lance Taylor  <iant@google.com>
394         * configure.ac: Add AC_USE_SYSTEM_EXTENSIONS.
395         * mmapio.c: Don't define _GNU_SOURCE.
396         * configure, config.h.in: Rebuild.
398 2012-09-18  Ian Lance Taylor  <iant@google.com>
400         * configure.ac: Check whether strnlen is declared.
401         * dwarf.c: Declare strnlen if not declared.
402         * configure, config.h.in: Rebuild.
404 2012-09-18  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
406         * fileline.c: Include <stdlib.h>.
407         * mmap.c: Likewise.
409 2012-09-17  Ian Lance Taylor  <iant@google.com>
411         PR bootstrap/54611
412         * nounwind.c (backtrace_full): Rename from backtrace.  Add state
413         parameter.
415 2012-09-17  Gerald Pfeifer  <gerald@pfeifer.com>
417         PR bootstrap/54611
418         * nounwind.c (backtrace_simple): Add state parameter.
420 2012-09-17  Ian Lance Taylor  <iant@google.com>
422         PR bootstrap/54609
423         * unknown.c (unknown_fileline): Add state parameter, remove
424         fileline_data parameter, name error_callback parameter.
425         (backtrace_initialize): Add state parameter.
427 2012-09-17  Ian Lance Taylor  <iant@google.com>
429         * Initial implementation.