blob: c199707d960c511d34a876e96b70faa071164935 [file] [log] [blame]
Mark Wielaard12ab7002014-11-27 23:41:57 +010012014-11-27 Mark Wielaard <mjw@redhat.com>
2
3 * dwarf_getcfi_elf.c (getcfi_gnu_eh_frame): Initialize
4 search_table_entries and search_table_encoding.
5
Mark Wielaard020fc022014-11-24 21:54:42 +010062014-11-24 Mark Wielaard <mjw@redhat.com>
7
8 * dwarf_getsrclines.c (read_srclines): Check line_range is not zero
9 before usage.
10
Mark Wielaard04b61f82014-11-23 23:13:55 +0100112014-11-23 Mark Wielaard <mjw@redhat.com>
12
Mark Wielaard59480ba2014-11-23 23:21:05 +010013 * dwarf_attr.c (dwarf_attr): Check __libdw_find_attr return value.
14 * dwarf_hasattr.c (dwarf_hasattr): Likewise.
15 * dwarf_siblingof.c (dwarf_siblingof): Likewise.
16
172014-11-23 Mark Wielaard <mjw@redhat.com>
18
Mark Wielaard04b61f82014-11-23 23:13:55 +010019 * dwarf_getabbrev.c (__libdw_getabbrev): Don't assert on bad DWARF.
20 Set libdw errno and return NULL.
21
Mark Wielaard9f8c08e2014-11-24 22:17:51 +0100222014-11-24 Mark Wielaard <mjw@redhat.com>
23
24 * dwarf.h (DW_LANG_C_plus_plus_11): Added.
25 (DW_LANG_C11): Likewise.
26 (DW_LANG_C_plus_plus_14): Likewise.
27 * dwarf_aggregate_size.c (array_size): Handle DW_LANG_C11,
28 DW_LANG_C_plus_plus_11, DW_LANG_C_plus_plus_14 and DW_LANG_Go
29 lower bound.
30 * dwarf_getfuncs.c (dwarf_getfuncs): Set c_cu to true for
31 DW_LANG_C11.
32
Mark Wielaard03c033f2014-11-26 17:51:28 +0100332014-11-26 Mark Wielaard <mjw@redhat.com>
34
35 * dwarf.h (DW_AT_noreturn): Added.
36
Mark Wielaard09086232014-11-11 14:10:04 +0100372014-11-11 Mark Wielaard <mjw@redhat.com>
38
39 * dwarf_getsrclines.c (read_srclines): Do address_size comparison
40 explicitly as uint8_t.
41 (__libdw_getsrclines): Add internal_function to declaration.
42
Petr Machatafb90bf32014-10-17 02:47:03 +0200432014-09-10 Petr Machata <pmachata@redhat.com>
44
45 * dwarf_macro_getparamcnt.c: New file.
46 * dwarf_macro_param.c: New file.
47 * dwarf_macro_getsrcfiles.c: New file.
48 * Makefile.am (libdw_a_SOURCES): Add the new files.
49 * libdwP.h (struct files_lines_s): New structure.
50 (DWARF_E_INVALID_OPCODE): New enumerator.
51 (struct Dwarf): New fields macro_ops, files_lines.
52 (Dwarf_Macro_Op_Proto, Dwarf_Macro_Op_Table): New structures for
53 keeping macro opcode prototypes in.
54 (Dwarf_Macro_s): Redefine from scratch.
55 (__libdw_getsrclines, __libdw_getcompdir, libdw_macro_nforms): New
56 internal interfaces.
57 * dwarf_error.c (errmsgs): Add a message for
58 DWARF_E_INVALID_OPCODE.
59 * dwarf_end.c (dwarf_end): Destroy struct Dwarf.macro_ops and
60 files_lines.
61 * libdw.h (dwarf_getmacros_off, dwarf_macro_getparamcnt)
62 (dwarf_macro_getsrcfiles, dwarf_macro_param): New public
63 interfaces.
64 * dwarf_getmacros.c (dwarf_getmacros_off): New function,
65 (get_offset_from, macro_op_compare, build_table)
66 (init_macinfo_table, get_macinfo_table, get_table_for_offset)
67 (cache_op_table, read_macros, gnu_macros_getmacros_off)
68 (macro_info_getmacros_off, do_dwarf_getmacros_die): New helper
69 functions.
70 (dwarf_getmacros): Adjust to dispatch to the new interfaces.
71 * dwarf_getsrclines.c (read_srclines): New function with guts
72 taken from dwarf_getsrclines.
73 (__libdw_getsrclines): Likewise.
74 (__libdw_getcompdir, files_lines_compare): New functions.
75 (dwarf_getsrclines): Make it dispatch to the new interfaces.
76 * dwarf_macro_param1.c (dwarf_macro_param1): Adjust to dispatch to
77 the new interfaces.
78 * dwarf_macro_param2.c (dwarf_macro_param2): Likewise.
79 * libdw.map (ELFUTILS_0.161): New. Add dwarf_getmacros_off,
80 dwarf_macro_getsrcfiles, dwarf_macro_getparamcnt, dwarf_macro_param.
81
Mark Wielaard3a36e8a2014-10-06 22:00:16 +0200822014-10-06 Mark Wielaard <mjw@redhat.com>
83
84 * Makefile.am (libdw_a_SOURCES): Add dwarf_peel_type.c.
85 * dwarf_aggregate_size.c (get_type): Use dwarf_peel_type.
86 (aggregate_size): Likewise. Add old and new version.
87 * dwarf_peel_type.c: New file.
88 * libdw.h (dwarf_peel_type): New function declaration.
89 * libdwP.h (dwarf_peel_type): New internal declaration.
90 * libdw.map (ELFUTILS_0.161): New section.
91
Petr Machata564cfbe2014-10-15 19:28:08 +0200922014-10-15 Petr Machata <pmachata@redhat.com>
93
94 * libdwP.h (struct Dwarf_Files_s.cu): Drop field.
95 * dwarf_getsrclines.c (dwarf_getsrclines): Don't set it.
96
Mark Wielaard2e83c642014-10-05 17:12:41 +0200972014-10-05 Mark Wielaard <mjw@redhat.com>
98
99 * dwarf.h: Add DW_AT_GNU_deleted.
100
Mark Wielaardb50014f2014-10-02 14:00:47 +02001012014-10-02 Mark Wielaard <mjw@redhat.com>
102
103 * dwarf_aggregate_size.c (aggregate_size): Return CU address_size
104 for sizeless DW_TAG_pointer_type, DW_TAG_reference_type or
105 DW_TAG_rvalue_reference_type.
106
Petr Machata1498f542014-09-12 19:03:33 +02001072014-09-12 Petr Machata <pmachata@redhat.com>
108
109 * memory-access.h (read_ubyte_unaligned_inc): Allow only 4- and
110 8-byte quantities. Consequently, rename to...
111 (read_addr_unaligned_inc): ... this.
112 (read_sbyte_unaligned_inc, read_ubyte_unaligned): Drop.
113 (read_sbyte_unaligned): Drop.
114
Petr Machata476feb12014-09-10 22:26:28 +02001152014-09-10 Petr Machata <pmachata@redhat.com>
116
117 * dwarf_getlocation.c (attr_ok): Also accept
118 DW_AT_GNU_call_site_value, DW_AT_GNU_call_site_data_value,
119 DW_AT_GNU_call_site_target, DW_AT_GNU_call_site_target_clobbered.
120
Mark Wielaard209f1492014-08-15 13:08:24 +02001212014-08-15 Mark Wielaard <mjw@redhat.com>
122
Mark Wielaardf18f2332014-08-15 16:03:21 +0200123 * dwarf_cu_die.c: New file.
124 * Makefile.am (libdw_a_SOURCES): Add dwarf_cu_die.c.
125 * libdw.h (dwarf_cu_die): New function declaration.
126 * libdw.map (ELFUTILS_0.160): Add dwarf_cu_die.
127
1282014-08-15 Mark Wielaard <mjw@redhat.com>
129
Mark Wielaard209f1492014-08-15 13:08:24 +0200130 * dwarf_cu_getdwarf.c: New file.
131 * Makefile.am (libdw_a_SOURCES): Add dwarf_cu_getdwarf.c.
132 * libdw.h (Dwarf_CU): New typedef.
133 (dwarf_cu_getdwarf): New function declaration.
134 * libdw.map (ELFUTILS_0.160): New. Add dwarf_cu_getdwarf.
135
Mark Wielaardaf1e6ed2014-06-18 10:57:58 +02001362014-06-18 Mark Wielaard <mjw@redhat.com>
137
138 * dwarf.h: Remove DW_TAG_mutable_type.
139
Mark Wielaardbb096d02014-05-03 00:23:06 +02001402014-05-02 Mark Wielaard <mjw@redhat.com>
141
142 * libdwP.h (__check_build_id): Removed now unused.
143
Mark Wielaarddf85bf92014-05-01 14:48:27 +02001442014-05-01 Mark Wielaard <mjw@redhat.com>
145
146 * libdwP.h (struct Dwarf): Remove free_alt.
147 * dwarf_end.c (dwarf_end): Don't check free_alt, don't end alt_dwarf.
148 * dwarf_setalt.c (dwarf_setalt): Don't check or set free_alt.
149
Mark Wielaardd81d32d2014-04-30 23:00:40 +02001502014-04-30 Mark Wielaard <mjw@redhat.com>
151
152 * libdw.map (ELFUTILS_0.159): Add dwelf_elf_gnu_build_id.
153
Florian Weimer920f03d2014-04-15 17:11:17 +02001542014-04-15 Florian Weimer <fweimer@redhat.com>
155
156 * dwarf_begin_elf.c (__check_build_id, try_debugaltlink)
157 (open_debugaltlink): Move to libdwfl.
158 (check_section): Do not locate alternate debuginfo.
159
Florian Weimer4813dbb2014-04-24 14:06:43 +02001602014-04-24 Florian Weimer <fweimer@redhat.com>
161
162 * libdw.map (ELFUTILS_0.159): Export dwelf_dwarf_gnu_debugaltlink.
163
Florian Weimer35e2a762014-04-15 14:31:55 +02001642014-04-22 Florian Weimer <fweimer@redhat.com>
165
166 * dwarf_getalt.c, dwarf_setalt.c: New files.
167 * Makefile.am (libdw_a_SOURCES): Add them.
168 * libdw.h (dwarf_getalt, dwarf_setalt): Add function declarations.
169 * libdwP.h (dwarf_getalt, dwarf_setalt): Add internal function
170 declarations.
171 * libdw.map (ELFUTILS_0.159): Export the two new functions.
172
Florian Weimerefa72a02014-04-15 14:04:19 +02001732014-04-15 Florian Weimer <fweimer@redhat.com>
174
175 * libdwP.h (enum IDX_gnu_debugaltlink): New.
176 * dwarf_begin_elf.c (dwarf_scnnames): Increase string size and add
177 .gnu_debugaltlink.
178 (check_section): Obtain .gnu_debugaltlink section from the
179 setiondata array.
180
Mark Wielaard93802972014-04-11 23:52:47 +02001812014-04-11 Mark Wielaard <mjw@redhat.com>
182
183 * libdw.map (ELFUTILS_0.159): New. Add dwelf_elf_gnu_debuglink.
184 * Makefile.am (libdw.so): Depend on libdwelf_pic.a.
185 (libdwelf_objects): New variable.
186 (libdw_a_LIBADD): Add libdwelf objects.
187
Mark Wielaardeb4da482014-04-22 16:43:11 +02001882014-04-22 Mark Wielaard <mjw@redhat.com>
189
190 * memory-access.h (get_sleb128_step): Remove undefined behavior
191 of left shifting a signed value. Replace it with a multiplication.
192
Mark Wielaard32324792014-04-13 17:39:57 +02001932014-04-13 Mark Wielaard <mjw@redhat.com>
194
195 * Makefile.am: Remove !MUDFLAP conditions.
196
Mark Wielaard7f1eec32014-04-09 11:33:23 +02001972014-04-09 Mark Wielaard <mjw@redhat.com>
198
199 * dwarf_begin_elf.c (check_section): Check for unsigned overflow
200 before calling malloc to uncompress data.
201
Jan Kratochvildff2a992014-03-04 00:04:27 +01002022014-03-03 Jan Kratochvil <jan.kratochvil@redhat.com>
203
204 Fix abort() on missing section headers.
205 * dwarf_begin_elf.c (check_section): Replace abort call by goto err.
206 New label err to return NULL.
207
Josh Stone50d5b2c2014-02-05 11:26:27 -08002082014-02-05 Josh Stone <jistone@redhat.com>
209
210 * dwarf_decl_file.c (dwarf_decl_file): Read the idx as unsigned.
211 * dwarf_decl_line.c (__libdw_attr_intval): Read the line/column as
212 unsigned. Change the range assert to DWARF_E_INVALID_DWARF.
213
Mark Wielaard19108012013-12-30 22:00:57 +01002142013-12-30 Mark Wielaard <mjw@redhat.com>
215
216 * libdw.map (ELFUTILS_0.158): Add dwfl_core_file_attach and
217 dwfl_linux_proc_attach.
218
Mark Wielaarde962ec32013-12-20 10:09:12 +01002192013-12-20 Mark Wielaard <mjw@redhat.com>
220
221 * libdw.map (ELFUTILS_0.158): Add dwfl_getthread_frames.
222
Mark Wielaard159ac522013-12-18 11:05:54 +01002232013-12-18 Mark Wielaard <mjw@redhat.com>
224
225 * libdw.map (ELFUTILS_0.158): Remove dwfl_module_addrsym_elf and
226 dwfl_module_getsym_elf. Add dwfl_module_addrinfo and
227 dwfl_module_getsym_info.
228
Mark Wielaard14c2d9e2013-12-16 13:28:59 +01002292013-12-16 Mark Wielaard <mjw@redhat.com>
230
231 * libdw.map (ELFUTILS_0.158): Add dwfl_module_getsymtab_first_global.
232
Josh Stone4e2787c2013-12-10 14:19:09 -08002332013-12-10 Josh Stone <jistone@redhat.com>
234
235 * memory-access.h (get_uleb128_rest_return): Removed.
236 (get_sleb128_rest_return): Removed.
237 (get_uleb128_step): Make this a self-contained block.
238 (get_sleb128_step): Ditto, and use a bitfield to extend signs.
239 (get_uleb128): Make this wholly implemented by __libdw_get_uleb128.
240 (get_sleb128): Make this wholly implemented by __libdw_get_sleb128.
241 (__libdw_get_uleb128): Simplify and inline for all callers.
242 (__libdw_get_sleb128): Ditto.
243 * dwarf_getlocation.c (store_implicit_value): Void the unused uleb128.
244 * memory-access.c: Delete file.
245 * Makefile.am (libdw_a_SOURCES): Remove it.
246 (DEFS): Remove the now unused -DIS_LIBDW.
247
Josh Stonec0d2a0b2013-12-09 13:52:10 -08002482013-12-09 Josh Stone <jistone@redhat.com>
249
250 * libdw_form.c (__libdw_form_val_compute_len): Renamed function from
251 __libdw_form_val_len, now handling only non-constant form lengths.
252 * libdwP.h (__libdw_form_val_len): New inlined function.
253
Mark Wielaard3951f2e2013-12-09 16:33:26 +01002542013-12-09 Mark Wielaard <mjw@redhat.com>
255
256 * dwarf_getlocation.c (__libdw_intern_expression): Handle empty
257 location expressions.
258 * dwarf_getlocation_attr.c (dwarf_getlocation_attr): When no
259 location found, return empty location expression.
260 * dwarf_getlocation_implicit_pointer.c
261 (dwarf_getlocation_implicit_pointer): Likewise.
262 (__libdw_empty_loc_attr): New internal function.
263 * libdwP.h (__libdw_empty_loc_attr): Define.
264
Mark Wielaard819c3492013-11-27 16:45:44 +01002652013-11-27 Mark Wielaard <mjw@redhat.com>
266
267 * libdw.map (ELFUTILS_0.158): Add dwfl_module_addrsym_elf and
268 dwfl_module_getsym_elf.
269
Mark Wielaard16bc4562013-11-26 15:13:22 +01002702013-11-26 Mark Wielaard <mjw@redhat.com>
271
272 * libdw.map (ELFUTILS_0.156): Move dwfl_attach_state, dwfl_pid,
273 dwfl_thread_dwfl, dwfl_thread_tid, dwfl_frame_thread,
274 dwfl_thread_state_registers, dwfl_thread_state_register_pc,
275 dwfl_getthreads, dwfl_thread_getframes and dwfl_frame_pc to ...
276 (ELFUTILS_0.158): ... here.
277
Mark Wielaard03d76f42013-11-09 16:45:22 +01002782013-11-09 Mark Wielaard <mjw@redhat.com>
279
280 * dwarf_getaranges.c (dwarf_getaranges): Read segment_size and
281 check that it is zero.
282
Jan Kratochvil0b867462013-05-30 14:37:38 +02002832013-11-07 Jan Kratochvil <jan.kratochvil@redhat.com>
284
285 * cfi.h (struct Dwarf_Frame_s): Make the comment more specific.
286 * libdw.map (ELFUTILS_0.156): Add dwfl_attach_state, dwfl_pid,
287 dwfl_thread_dwfl, dwfl_thread_tid, dwfl_frame_thread,
288 dwfl_thread_state_registers, dwfl_thread_state_register_pc,
289 dwfl_getthreads, dwfl_thread_getframes and dwfl_frame_pc.
290
Michael Forneya45c8042013-11-01 00:51:04 -07002912013-11-01 Michael Forney <mforney@mforney.org>
292
Michael Forneycdc09432013-11-01 00:51:05 -0700293 * Makefile.am (libdwfl_objects): New definition.
294 (libdw_a_LIBADD): Use libdwfl_objects.
295
2962013-11-01 Michael Forney <mforney@mforney.org>
297
Michael Forneya45c8042013-11-01 00:51:04 -0700298 * Makefile.am: Use READELF.
299
Jan Kratochvil3cf491e2013-10-30 10:48:20 +01003002013-10-30 Jan Kratochvil <jan.kratochvil@redhat.com>
301
302 * libdw.map (ELFUTILS_0.158): New.
303
Mark Wielaarde6a9bb82013-10-10 11:40:12 +02003042013-10-10 Mark Wielaard <mjw@redhat.com>
305
306 * dwarf_getfuncs.c (struct visitor_info): Rename start_offset to
307 start_addr and rename last_offset to last_addr. Now both void *.
308 (tree_visitor): Use start_add and die_addr instead of start_offset
309 and die_offset.
310 (dwarf_getfuncs): Use last_addr instead of last_offset.
311
Mark Wielaard3dec3e12013-10-06 17:04:07 +02003122013-10-06 Mark Wielaard <mjw@redhat.com>
313
314 * cfi.c (execute_cfi): Make sure DW_CFA_expression and
315 DW_CFA_val_expression are not used with abi_cfi.
316
Josh Stone5dbbc5e2013-10-03 12:38:25 -07003172013-10-03 Josh Stone <jistone@redhat.com>
318
319 * dwarf_formref_die.c (dwarf_formref_die): Don't hash the sig8 here.
320 * libdw_findcu.c (__libdw_intern_next_unit): Since this never revisits
321 a unit, make sure to always hash the sig8 here, so none are missed.
322
Mark Wielaard74f9b732013-09-30 00:39:07 +02003232013-09-29 Mark Wielaard <mjw@redhat.com>
324
325 * dwarf_getlocation.c (store_implicit_value): Cast op->number2 to
326 uintptr_t before casting to char *.
327 (__libdw_intern_expression): Cast data to uintptr_t before casting
328 to Dwarf_Word.
329 * dwarf_getlocation_attr.c (dwarf_getlocation_attr): Cast
330 op->number2 to uintptr_t before casting to char *.
331
Josh Stonef06c8582013-09-24 15:52:05 -07003322013-09-24 Josh Stone <jistone@redhat.com>
333
334 * libdw_visit_scopes.c (classify_die): Removed.
335 (may_have_scopes): New function to replace classify_die. There's no
336 need for full classification; just find tags that may contain scopes.
337 (__libdw_visit_scopes): Use a direct tag comparison for imported
338 units, and use may_have_scopes to test if recursion is needed.
339
Mark Wielaard1b734df2013-09-20 09:50:42 -04003402013-09-20 Mark Wielaard <mjw@redhat.com>
341
342 * dwarf_getfuncs.c (visitor_info): New struct.
343 (tree_visitor): New function.
344 (dwarf_getfuncs): Use __libdw_visit_scopes with tree_visitor.
345 * libdw.h (dwarf_getfuncs): Expand function documentation.
346
Mark Wielaard18b2c672013-09-12 15:49:47 +02003472013-09-12 Mark Wielaard <mjw@redhat.com>
348
349 * fde.c (intern_fde): Free fde and set libdw errno when start
350 or end could not be read.
351
Mark Wielaardb2535b62013-08-30 23:55:12 +02003522013-08-24 Mark Wielaard <mjw@redhat.com>
353
354 * dwarf_getlocation.c (store_implicit_value): Don't take data
355 as argument, get block data from op number2. Return false when
356 block data length and op number don't match up.
357 (__libdw_intern_expression): Store start of block for
358 DW_OP_implicit_value and DW_OP_GNU_entry_value instead of
359 relative data offset. Also store block start (including length)
360 for DW_OP_GNU_const_type. Don't pass data to store_implicit_value.
361 * dwarf_getlocation_attr.c: New file.
362 * dwarf_getlocation_die.c: Likewise.
363 * libdw.h (dwarf_getlocation_die): New function definition.
364 (dwarf_getlocation_attr): Likewise.
365 * libdwP.h: Declare internal dwarf_getlocation_die.
366 * libdw.map (ELFUTILS_0.157): Add dwarf_getlocation_die and
367 dwarf_getlocation_attr.
368 * Makefile.am (libdw_a_SOURCES): Add dwarf_getlocation_die.c and
369 dwarf_getlocation_attr.c.
370
Mark Wielaard66eaae92013-08-23 16:12:37 +02003712013-08-23 Mark Wielaard <mjw@redhat.com>
372
373 * dwarf_getlocation.c (attr_ok): Also accept DW_AT_segment.
374 (attr_base_address): New function.
375 (initial_offset_base): New function.
376 (getlocations_addr): New function. Taken from...
377 (dwarf_getlocation_addr): here. Use new initial_offset_base and
378 getlocations_addr.
379 (dwarf_getlocations): New function.
380 * libdw.h (dwarf_getlocations): New function definition.
381 * libdw.map (ELFUTILS_0.157): New.
382
Mark Wielaard5704c8c2013-07-02 11:22:35 +02003832013-07-02 Mark Wielaard <mjw@redhat.com>
384
Mark Wielaard4aacfc12013-07-02 16:36:16 +0200385 * dwarf_getsrclines.c (dwarf_getsrclines): Add new stack allocation
386 limit MAX_STACK_ALLOC. After MAX_STACK_ALLOC lines use malloc in
387 NEW_LINE macro. Free malloced line records if any at the end.
388
3892013-07-02 Mark Wielaard <mjw@redhat.com>
390
Mark Wielaard5704c8c2013-07-02 11:22:35 +0200391 * dwarf_getcfi_elf.c (getcfi_shdr): Check sh_type == SHT_PROGBITS.
392
Mark Wielaard79277072013-06-26 11:42:52 -04003932013-06-26 Mark Wielaard <mjw@redhat.com>
394
395 * libdw_visit_scopes.c (__libdw_visit_scopes): Don't reject root
396 DIEs without children. Return an error whenever dwarf_child or
397 dwarf_siblingof return an error. Don't call recurse and increase
398 the depth for an imported unit. Walk the children of an imported
399 unit as if they are logical children of the parent root DIE.
400
Mark Wielaard9affad32013-05-03 11:28:49 +02004012013-05-03 Mark Wielaard <mjw@redhat.com>
402
403 * dwarf_getsrclines.c (dwarf_getsrclines): Only set end_sequence
404 when nlinelist > 0.
405
Jan Kratochvil904aec22013-04-30 14:27:16 +02004062013-04-28 Jan Kratochvil <jan.kratochvil@redhat.com>
407
408 * libdw.map (ELFUTILS_0.156): New.
409
Mark Wielaardcdaaf212013-04-25 16:50:11 -04004102013-04-24 Mark Wielaard <mjw@redhat.com>
411
412 * Makefile.am: Use AM_CPPFLAGS instead of INCLUDES.
413
Mark Wielaardd4744a72013-04-10 15:52:57 +02004142013-04-10 Mark Wielaard <mjw@redhat.com>
415
416 * dwarf_formref_die.c (dwarf_formref_die): Reference size is only
417 equal to address size when we have a DW_FORM_ref_addr for DWARF
418 version 2.
419
Mark Wielaard60ef9ab2013-03-25 17:07:21 +01004202013-03-25 Mark Wielaard <mjw@redhat.com>
421
422 * dwarf_getsrclines.c (dwarf_getsrclines): Mark highest address as
423 end_sequence.
424
Mark Wielaardf1b06b52013-03-12 12:02:51 +01004252013-03-12 Mark Wielaard <mjw@redhat.com>
426
427 * dwarf_getsrcfiles.c (dwarf_getsrcfiles): Allow DW_TAG_partial_unit.
428 * dwarf_getsrclines.c (dwarf_getsrclines): Likewise.
429
Mark Wielaard443304e2013-02-15 22:45:22 +01004302013-02-15 Mark Wielaard <mjw@redhat.com>
431
432 * dwarf_formstring.c (dwarf_formstring): Check dbg_ret->sectiondata,
433 not dbg->sectiondata.
434
Roland McGrath3999ce12013-01-07 14:53:37 -08004352013-01-07 Roland McGrath <roland@hack.frob.com>
436
437 * memory-access.h
438 [ALLOW_UNALIGNED] (read_8ubyte_unaligned_noncvt): New macro.
439 [!ALLOW_UNALIGNED] (read_8ubyte_unaligned_noncvt): New inline function.
440
Mark Wielaard59254422012-12-18 14:14:22 +01004412012-12-18 Mark Wielaard <mjw@redhat.com>
442
443 * dwarf_begin_elf.c (valid_p): Call Dwarf_Sig8_Hash_free if invalid.
444 (check_section): Likewise on error.
445 (scngrp_read): Likewise.
446 (dwarf_begin_elf): Likewise.
447
Petr Machatab5c0b032012-10-09 02:11:29 +02004482012-10-09 Petr Machata <pmachata@redhat.com>
449
450 * dwarf_getlocation.c (__libdw_intern_expression): Handle
451 DW_OP_GNU_parameter_ref, DW_OP_GNU_convert, DW_OP_GNU_reinterpret,
452 DW_OP_GNU_regval_type, DW_OP_GNU_entry_value,
453 DW_OP_GNU_deref_type, DW_OP_GNU_const_type.
454
Jan Kratochvil6c45f4a2012-10-08 23:04:54 +02004552012-10-08 Jan Kratochvil <jan.kratochvil@redhat.com>
456
Jan Kratochvil1d67c0c2012-10-08 23:51:31 +0200457 * cfi.c: New include system.h.
458 (execute_cfi) (enough_registers): Clear new memory after realloc.
459
4602012-10-08 Jan Kratochvil <jan.kratochvil@redhat.com>
461
Jan Kratochvil07f35072012-10-08 23:34:35 +0200462 * fde.c (__libdw_find_fde): Change <fde != NULL> to likely. Return
463 DWARF_E_NO_MATCH if .eh_frame_hdr points to FDE which is too short for
464 searched PC.
465
4662012-10-08 Jan Kratochvil <jan.kratochvil@redhat.com>
467
Jan Kratochvil96a9fc62012-10-08 23:08:01 +0200468 * dwarf_getlocation.c (__libdw_intern_expression) <cfap>: Make new
469 loclist element DW_OP_call_frame_cfa before decoding the opcodes.
470 Remove the later DW_OP_call_frame_cfa push to RESULT.
471
4722012-10-08 Jan Kratochvil <jan.kratochvil@redhat.com>
473
Jan Kratochvil6c45f4a2012-10-08 23:04:54 +0200474 Code cleanup.
475 * fde.c (binary_search_fde): Remove always true <address >= start>
476 conditional. Move L initialization upwards.
477
Mark Wielaardf5519fc2012-08-24 13:54:52 +02004782012-08-24 Mark Wielaard <mjw@redhat.com>
479
480 * dwarf_begin_elf.c (check_section): Only probe for dwz multi files
481 when ENABLE_DWZ is defined.
482 * libdwP.h (__check_build_id): Only declare when ENABLE_DWZ is
483 defined.
484
Mark Wielaardf31c4412012-08-17 00:35:03 +02004852012-08-16 Mark Wielaard <mjw@redhat.com>
486
487 * Makefile.am (EXTRA_DIST): Add known-dwarf.h.
488 * dwarf.h (DW_LANG_Go): Update comment.
489 (DW_LANG_Mips_Assembler): Likewise.
490
Mark Wielaard775375e2012-06-22 12:02:45 +02004912012-06-27 Mark Wielaard <mjw@redhat.com>
492
493 * dwarf.h: Add DW_FORM_GNU_ref_alt and DW_FORM_GNU_strp_alt.
494 * dwarf_begin.c (dwarf_begin): Add INTDEF.
495 * dwarf_begin_elf.c (__check_build_id): New internal_function.
496 (try_debugaltlink): New function.
497 (open_debugaltlink): Likewise.
498 (check_section): Try open_debugaltlink for .gnu_debugaltlink.
499 * dwarf_end.c (dwarf_end): Free the alternative Dwarf descriptor if
500 necessary.
501 * dwarf_error.c (errmsgs): Add DWARF_E_NO_ALT_DEBUGLINK.
502 * dwarf_formref.c (__libdw_formref): Using DW_FORM_GNU_ref_alt
503 is an error here.
504 * dwarf_formref_die.c (dwarf_formref_die): Handle DW_FORM_GNU_ref_alt.
505 * dwarf_formstring.c (dwarf_formstring): Handle DW_FORM_GNU_strp_alt.
506 * dwarf_formudata.c (__libdw_formptr): Adjust __libdw_read_offset
507 calls.
508 * dwarf_getpubnames.c (get_offsets): Adjust __libdw_read_offset call.
509 * libdwP.h: Add DWARF_E_NO_ALT_DEBUGLINK.
510 (struct Dwarf): Add alt_dwarf and free_alt fields.
511 (__libdw_read_offset): Add dbg_ret argument, use to check with
512 __libdw_offset_in_section.
513 (__check_build_id): New function declaration.
514 (dwarf_begin): Define as INTDECL.
515 * libdw_form.c (__libdw_form_val_len): Handle DW_FORM_GNU_ref_alt
516 and DW_FORM_GNU_strp_alt.
517
Mark Wielaard515fba92012-07-20 00:09:56 +02005182012-07-19 Mark Wielaard <mjw@redhat.com>
519
520 * dwarf.h: Add DW_OP_GNU_parameter_ref.
521
Mark Wielaarddf9ec3f2012-07-24 20:00:14 +02005222012-07-24 Mark Wielaard <mjw@redhat.com>
523
Mark Wielaardc4010b82012-07-24 13:20:41 +0200524 * dwarf.h: Correct spelling of DW_LANG_ObjC.
525 * dwarf_aggregate_size.c (array_size): Use correct spelling of
526 DW_LANG_ObjC.
527
5282012-07-24 Mark Wielaard <mjw@redhat.com>
529
Mark Wielaarddf9ec3f2012-07-24 20:00:14 +0200530 * dwarf.h: Add DW_ATE_UTF.
531
Mark Wielaardef5688e2012-06-27 10:15:27 +02005322012-06-27 Mark Wielaard <mjw@redhat.com>
533
534 * dwarf.h: Add DW_MACRO_GNU .debug_macro type encodings.
535
Mark Wielaarda0172d72012-06-25 17:18:53 +02005362012-06-26 Mark Wielaard <mjw@redhat.com>
537
538 * libdwP.h: Add IDX_debug_macro.
539 * dwarf.h: Add DW_AT_GNU_macros.
540 * dwarf_begin_elf.c (dwarf_scnnames): Add .debug_macro.
541 * dwarf_formudata.c (dwarf_formudata): Recognize DW_AT_GNU_macros.
542
Mark Wielaard54797252012-04-27 13:00:50 +02005432012-04-27 Mark Wielaard <mjw@redhat.com>
544
545 * libdw/dwarf_highpc.c (dwarf_highpc): Handle DW_AT_high_pc being
546 a constant offset from DW_AT_low_pc.
547
Tom Tromey581c3f62012-03-21 08:54:32 -06005482012-03-19 Tom Tromey <tromey@redhat.com>
549
550 * libdw_findcu.c (findcu_cb): Move earlier.
551 (__libdw_intern_next_unit): Add new CU to search tree here...
552 (__libdw_findcu): ... not here.
553
Mark Wielaardcb643d62012-01-31 19:22:03 +01005542012-01-31 Mark Wielaard <mjw@redhat.com>
555
556 * dwarf_formudata.c (dwarf_formudata): Handle DW_FORM_sec_offset.
557
Mark Wielaard387998b2011-10-31 15:01:50 +01005582011-11-31 Mark Wielaard <mjw@redhat.com>
559
560 * Makefile.am (known-dwarf.h): Run gawk on config/known-dwarf.awk.
561
Mark Wielaard0b72b652011-07-14 12:59:26 +02005622011-07-14 Mark Wielaard <mjw@redhat.com>
563
564 * libdw.h (dwarf_offdie): Fix documentation to mention .debug_info.
565
Jakub Jelinek03124242011-05-17 17:00:14 +02005662011-05-16 Jakub Jelinek <jakub@redhat.com>
567
568 * dwarf.h (DW_OP_GNU_const_type, DW_OP_GNU_regval_type,
569 DW_OP_GNU_deref_type, DW_OP_GNU_convert, DW_OP_GNU_reinterpret):
570 New.
571
Mark Wielaardf4c39c72011-04-26 17:15:28 +02005722011-04-26 Mark Wielaard <mjw@redhat.com>
573
574 * dwarf_child (dwarf_child): Sanity check end of section against
575 cu_data () of die->cu.
576
Mark Wielaarde3368c52011-03-22 23:03:31 +01005772011-03-22 Mark Wielaard <mjw@redhat.com>
578
579 * dwarf.h: Add DW_TAG_GNU_call_site,
580 DW_TAG_GNU_call_site_parameter,
581 DW_AT_GNU_call_site_value,
582 DW_AT_GNU_call_site_data_value,
583 DW_AT_GNU_call_site_target,
584 DW_AT_GNU_call_site_target_clobbered,
585 DW_AT_GNU_tail_call,
586 DW_AT_GNU_all_tail_call_sites,
587 DW_AT_GNU_all_call_sites,
588 DW_AT_GNU_all_source_call_sites,
589 and DW_OP_GNU_entry_value.
590
Petr Machata02c56192011-03-10 01:50:32 +01005912011-03-10 Petr Machata <pmachata@redhat.com>
592
593 * libdw/dwarf_tag.c (__libdw_findabbrev): Reject requests for
594 abbreviation with code 0.
595
Petr Machata35870872011-03-09 10:01:29 -08005962011-03-09 Petr Machata <pmachata@redhat.com>
597
598 * libdw/dwarf_child.c (dwarf_child): Check for section overrun.
599
Roland McGrath725aad52011-02-23 19:52:46 -08006002011-02-23 Roland McGrath <roland@redhat.com>
601
602 * libdwP.h (struct Dwarf) [USE_ZLIB]: New member sectiondata_gzip_mask.
603 Declare __libdw_free_zdata.
604 * dwarf_end.c [USE_ZLIB] (__libdw_free_zdata): New function.
605 (dwarf_end): Call it.
606
607 * dwarf_begin_elf.c (valid_p): Likewise.
608 (check_section, scngrp_read): Likewise.
609 (check_section) [USE_ZLIB]: Grok .z* flavors of sections.
610
Roland McGrath8c0a3822010-10-13 11:21:17 -07006112010-10-13 Roland McGrath <roland@redhat.com>
612
613 * dwarf.h: Add DW_LANG_Go.
614
Roland McGrath5f95e2b2010-10-05 00:56:30 -07006152010-10-05 Roland McGrath <roland@redhat.com>
616
617 * dwarf_getaranges.c: Use malloc rather than alloca,
618 since the total number of elements can be quite huge.
619
Roland McGrath932585d2010-05-08 04:01:14 -07006202010-07-26 Roland McGrath <roland@redhat.com>
621
622 * dwarf_getlocation_implicit_pointer.c: New file.
623 * Makefile.am (libdw_a_SOURCES): Add it.
624 * libdw.map (ELFUTILS_0.149): New set.
625 Add dwarf_getlocation_implicit_pointer.
626 * libdw.h: Declare it.
627
628 * dwarf_offdie.c (do_offdie): Renamed to __libdw_offdie, made global.
629 (dwarf_offdie, dwarf_offdie_types): Update callers.
630 * libdwP.h: Declare it.
631
632 * dwarf.h: Add DW_OP_GNU_implicit_pointer.
633 * dwarf_getlocation.c (__libdw_intern_expression): Handle it.
634
Roland McGrathde44f132010-08-24 15:38:42 -07006352010-08-24 Roland McGrath <roland@redhat.com>
636
637 * libdw.map (ELFUTILS_0.149): New set. Add dwfl_dwarf_line.
638
Roland McGrath00aca7f2010-07-27 04:40:23 -07006392010-07-27 Roland McGrath <roland@redhat.com>
640
641 * dwarf_formref_die.c: Fix sig8 hash insertion.
642
Roland McGrath9616b852010-06-23 03:17:28 -07006432010-06-23 Roland McGrath <roland@redhat.com>
644
645 * cfi.c (dwarf_cfi_validate_fde): Function removed.
646 * libdw.h: Remove it.
647 * libdw.map: Likewise.
648
Roland McGrath499b8ff2010-06-22 13:13:53 -07006492010-06-22 Roland McGrath <roland@redhat.com>
650
Roland McGrathc16966a2010-06-22 17:08:43 -0700651 * dwarf_getlocation.c (check_constant_offset): data[48] are constant.
652
Roland McGrath499b8ff2010-06-22 13:13:53 -0700653 * dwarf_getsrclines.c: Fix signed comparison warning in extended
654 opcode parsing.
655
Roland McGrath0c5638c2010-06-21 23:00:35 -07006562010-06-21 Roland McGrath <roland@redhat.com>
657
Roland McGrath474cb482010-06-22 00:10:54 -0700658 * dwarf.h: Add DW_TAG_GNU_* constants.
659
Roland McGrath0c5638c2010-06-21 23:00:35 -0700660 * memory-access.h (get_sleb128_rest_return): Fix sign extension for
661 10-byte case.
662
Roland McGrath5cc030d2010-06-20 17:25:35 -07006632010-06-20 Roland McGrath <roland@redhat.com>
664
Roland McGrath2b1f0952010-06-20 17:55:50 -0700665 * libdw_findcu.c (__libdw_findcu): Take new flag argument,
666 to search TUs instead of CUs.
667 * libdwP.h: Update decl.
668 (struct Dwarf): New member tu_tree.
669 * dwarf_end.c (dwarf_end): Clean up tu_tree.
670 * dwarf_offdie.c (do_offdie): New function, broken out of ...
671 (dwarf_offdie): ... here.
672 (dwarf_offdie_types): New function.
673 * libdw.h: Declare it.
674 * libdw.map (ELFUTILS_0.148): Add it.
675
Roland McGrath5cc030d2010-06-20 17:25:35 -0700676 * libdwP.h (CUDIE): Use cu_data.
677 * dwarf_formblock.c: Likewise.
678 * dwarf_formref_die.c: Likewise.
679 * dwarf_diecu.c: Use CUDIE macro.
680 * dwarf_formaddr.c: Use cu_sec_idx.
681
Roland McGrathc70ebc02010-06-16 02:21:26 -07006822010-06-16 Roland McGrath <roland@redhat.com>
683
Roland McGrath3e0f7d12010-06-15 23:10:35 -0700684 * dwarf_formref_die.c: Use dwarf_offdie only for DW_FORM_ref_addr, so
685 we don't repeat a CU lookup we've already done. Handle
686 DW_FORM_ref_sig8 using sig8_hash table and __libdw_intern_next_unit.
687
688 * libdw_findcu.c (__libdw_intern_next_unit): New function,
689 broken out of ...
690 (__libdw_findcu): ... here. Call it.
691 * libdwP.h: Declare it.
692 (struct Dwarf): New member next_tu_offset.
693
694 * dwarf_sig8_hash.c: New file.
695 * dwarf_sig8_hash.h: New file.
696 * Makefile.am (libdw_a_SOURCES, noinst_HEADERS): Add them.
697 * dwarf_abbrev_hash.c: Include dwarf_sig8_hash.h before
698 defining NO_UNDEF.
699 * libdwP.h (struct Dwarf): New member sig8_hash.
700 * dwarf_begin_elf.c: Call Dwarf_Sig8_Hash_init on it.
701 * dwarf_end.c: Call Dwarf_Sig8_Hash_free on it.
702
703 * dwarf_nextcu.c (dwarf_next_unit): New function, broken out of ...
704 (dwarf_nextcu): ... here. Call it.
705 * libdw.h: Declare it.
706 * libdwP.h: Add INTDECL.
707 * libdw_findcu.c (__libdw_findcu): Use it instead of dwarf_nextcu.
708 * libdw.map (ELFUTILS_0.148): New set, add dwarf_next_unit.
709
710 * libdwP.h (cu_sec_idx, cu_data): New functions.
711 Use .debug_types when CU is a TU.
712 * dwarf_cuoffset.c: Use that instead of assuming IDX_debug_info.
713 * dwarf_siblingof.c: Likewise.
714 * dwarf_formstring.c: Likewise.
715 * dwarf_formudata.c (__libdw_formptr, dwarf_formudata): Likewise.
716 * dwarf_getlocation.c (dwarf_getlocation): Likewise.
717 (dwarf_getlocation_addr): Likewise.
718
719 * libdwP.h (struct Dwarf_CU): Add new members type_offset, type_sig8.
720 (DIE_OFFSET_FROM_CU_OFFSET): Take flag argument; if true, compute
721 .debug_types header size instead of .debug_info header size.
722 (CUDIE): Use it.
723 * dwarf_diecu.c: Update caller.
724 * dwarf_getaranges.c: Likewise.
725 * dwarf_nextcu.c: Likewise.
726 * libdw_findcu.c (__libdw_findcu): Initialize new members.
727
Roland McGrath3e4b5bb2010-06-16 03:40:56 -0700728 * fde.c (fde_by_offset): Renamed to ...
729 (__libdw_fde_by_offset): ... this, made global and internal_function.
730 Don't take ADDRESS argument.
731 (__libdw_find_fde): Update caller. Do address sanity check here.
732 * cfi.h: Declare __libdw_fde_by_offset.
733 * cfi.c (dwarf_cfi_validate_fde): New function.
734 * libdw.h: Declare it.
735 * libdw.map (ELFUTILS_0.148): Add it.
736
Roland McGrath5f4b5082010-06-16 03:11:57 -0700737 * cie.c (intern_new_cie): Canonicalize DW_EH_PE_absptr FDE encoding to
738 either DW_EH_PE_udata8 or DW_EH_PE_udata4.
739
Roland McGrath7934ded2010-06-16 03:04:09 -0700740 * encoded-value.h (read_encoded_value): Handle DW_EH_PE_indirect.
741 Don't assume DW_EH_PE_aligned refers to native address size.
742
Roland McGrathc70ebc02010-06-16 02:21:26 -0700743 * cfi.c (execute_cfi): Barf on CIE initial instructions changing the
744 address.
745
Roland McGrathc70cf4e2010-06-18 17:01:05 -07007462010-06-17 Roland McGrath <roland@redhat.com>
747
748 * libdwP.h (struct Dwarf_Line_s): Add members isa, discriminator, and
749 op_index.
750 * dwarf_getsrclines.c (dwarf_getsrclines): Move NEW_FILE macro guts
751 into an inner inline function. Set new fields. Check all fields for
752 overflow when setting.
753 * dwarf_lineisa.c: New file.
754 * dwarf_linediscriminator.c: New file.
755 * dwarf_lineop_index.c: New file.
756 * Makefile.am (libdw_a_SOURCES): Add them.
757 * libdw.map (ELFUTILS_0.148): Add them.
758 * libdw.h: Declare them.
759
Roland McGrath3f633072010-06-15 22:17:04 -07007602010-06-16 Roland McGrath <roland@redhat.com>
761
Roland McGrath4a87dfa2010-06-16 16:35:10 -0700762 * dwarf_next_cfi.c: Fix version 4 return_address_register decoding.
763
Roland McGrathb75f4442010-06-15 22:24:19 -0700764 * fde.c (fde_by_offset): Renamed to ...
765 (__libdw_fde_by_offset): ... this, made global and internal_function.
766 Don't take ADDRESS argument.
767 (__libdw_find_fde): Update caller. Do address sanity check here.
768 * cfi.h: Declare __libdw_fde_by_offset.
Roland McGrath9bcd2652010-06-15 22:17:20 -0700769 * cfi.c (dwarf_cfi_validate_fde): New function.
770 * libdw.h: Declare it.
Roland McGrath3f633072010-06-15 22:17:04 -0700771 * libdw.map (ELFUTILS_0.148): Add it.
772
Roland McGrath0b3363e2010-06-01 15:42:14 -0700773 * cie.c (intern_new_cie): Canonicalize DW_EH_PE_absptr FDE encoding to
774 either DW_EH_PE_udata8 or DW_EH_PE_udata4.
Roland McGrath827d4d12010-06-01 20:17:36 -0700775
776 * encoded-value.h (read_encoded_value): Handle DW_EH_PE_indirect.
777 Don't assume DW_EH_PE_aligned refers to native address size.
Roland McGrath1a030b32010-06-01 20:11:40 -0700778
779 * cfi.c (execute_cfi): Barf on CIE initial instructions changing the
Roland McGrath675229b2010-06-01 20:10:19 -0700780 address.
781
7822010-06-15 Roland McGrath <roland@redhat.com>
Roland McGrath52123962010-06-01 19:05:08 -0700783
784 * dwarf_formref.c (__libdw_formref): Diagnose DW_FORM_ref_sig8 like
Roland McGrath7fac1ce2010-06-01 15:56:58 -0700785 DW_FORM_ref_addr.
786 * dwarf_formref_die.c (dwarf_formref_die): Diagnose it the same way
Roland McGrath0b3363e2010-06-01 15:42:14 -0700787 here, since we don't support it yet.
788
Mark Wielaard3f507bd2010-05-31 15:06:31 +0200789 * dwarf_next_cfi.c: Handle version 4 format.
790
Mark Wielaard08e71db2010-05-31 15:39:15 +0200791 * dwarf_getsrclines.c: Handle version 4 format.
792
7932010-06-01 Roland McGrath <roland@redhat.com>
794
795 * libdwP.h: Remove unused IDX_debug_*names, add IDX_debug_types.
Mark Wielaard3f507bd2010-05-31 15:06:31 +0200796 * dwarf_begin_elf.c (dwarf_scnnames): Likewise.
797
Eduardo Santiagod2240bc2010-05-28 14:26:52 -0700798 * libdwP.h (CIE_VERSION): Remove unused macro.
Ulrich Drepper6fb34512010-05-28 20:28:04 -0700799
Ulrich Drepper49fe7142010-05-28 20:32:37 -0700800 * dwarf_getsrclines.c: Fix version field test.
801 * libdwP.h (DWARF_VERSION): Remove useless macro.
Ulrich Drepper6fb34512010-05-28 20:28:04 -0700802
Roland McGrathcfa5da22010-05-27 13:49:25 -0700803 * dwarf_formudata.c (__libdw_formptr): Fix DW_FORM_sec_offset handling.
804
805 * dwarf_formblock.c (dwarf_formblock): Handle DW_FORM_exprloc.
806
807 * libdw_findcu.c (__libdw_findcu): Accept version 4.
Roland McGrath688f7fc2010-05-08 03:22:59 -0700808
8092010-05-31 Mark Wielaard <mjw@redhat.com>
810
811 * cfi.h (dwarf_cfi_cie_p): Move definition from here, to ..
812 * libdw.h (dwarf_cfi_cie_p): ... here.
813
8142010-05-31 Mark Wielaard <mjw@redhat.com>
815
816 * dwarf.h: Fix DW_LANG_Python constant.
Roland McGrath0ab97832010-04-26 11:50:27 -0700817
8182010-05-28 Eduardo Santiago <santiago@redhat.com>
Roland McGrath3b10ac02010-04-26 18:45:36 -0700819
820 * dwarf_getlocation.c (dwarf_getlocation): Do attr_ok check first
821 thing.
822
8232010-05-27 Roland McGrath <roland@redhat.com>
Roland McGrath0ab97832010-04-26 11:50:27 -0700824
825 * dwarf.h: Add DW_AT_enum_class, DW_AT_linkage_name,
826 DW_TAG_template_alias, DW_LANG_Python, DW_LNE_set_discriminator.
827
8282010-05-08 Roland McGrath <roland@redhat.com>
829
830 * dwarf_getlocation.c (__libdw_intern_expression): Take new argument
Roland McGrath3f9d9552010-04-22 20:51:07 -0700831 REF_SIZE. Use that to handle DW_OP_call_ref correctly.
832 (getlocation): Update caller.
833 * dwarf_frame_cfa.c (dwarf_frame_cfa): Likewise.
834 * dwarf_frame_register.c (dwarf_frame_register): Likewise.
835 * libdwP.h: Update decl.
836
8372010-04-26 Roland McGrath <roland@redhat.com>
Roland McGrath8068e062010-03-10 23:49:13 -0800838
839 * cfi.h (struct Dwarf_Frame_s): Add cfa_invalid alternative in cfa_rule.
840 * cfi.c (execute_cfi): Set that instead of doing cfi_assert for
841 DW_CFA_def_cfa_{offset*,register} when a non-offset rule is in force.
Roland McGrath22359e22010-02-15 15:57:03 -0800842 * dwarf_frame_cfa.c (dwarf_frame_cfa): Handle cfa_invalid.
843
844 * dwarf_getlocation.c (__libdw_intern_expression): Take new arg CFAP.
845 Prepend DW_OP_call_frame_cfa if true.
Mark Wielaardee29a312010-02-02 20:44:53 +0100846 (getlocation): Update caller.
847 * dwarf_frame_cfa.c (dwarf_frame_cfa): Likewise.
848 * dwarf_frame_register.c (dwarf_frame_register): Likewise.
849 * libdwP.h: Update decl.
Roland McGrathf95760a2010-01-07 20:24:34 -0800850
8512010-04-22 Roland McGrath <roland@redhat.com>
852
853 * cfi.c (execute_cfi): Never return without cleanup.
Roland McGrath019d9fb2010-01-05 13:36:07 -0800854 Free FS on failure.
855 (cie_cache_initial_state): Adjust caller to expect that free.
Roland McGrathebc5c882010-01-05 22:53:31 -0800856 (__libdw_frame_at_address): Likewise.
857
8582010-03-10 Roland McGrath <roland@redhat.com>
859
860 * libdw.map (ELFUTILS_0.146): New set. Add dwfl_core_file_report.
861
8622010-02-15 Roland McGrath <roland@redhat.com>
863
864 * Makefile.am: Use config/eu.am for common stuff.
Roland McGrath0cb19832010-01-05 13:38:15 -0800865
8662010-02-02 Mark Wielaard <mjw@redhat.com>
Roland McGrath019d9fb2010-01-05 13:36:07 -0800867
868 * fde.c (intern_fde): Fix length check for sized_augmentation_data.
Roland McGrath888381b2009-11-21 17:03:34 -0800869
8702010-01-07 Roland McGrath <roland@redhat.com>
871
872 * dwarf_getcfi_elf.c (getcfi_phdr): Use elf_getphdrnum.
873
Roland McGrath9ca7bc42009-10-15 12:26:49 -07008742010-01-05 Roland McGrath <roland@redhat.com>
875
876 * dwarf_aggregate_size.c: New file.
877 * Makefile.am (libdw_a_SOURCES): Add it.
878 * libdw.h: Declare it.
Roland McGrath7e0aecd2009-09-17 15:02:34 -0700879 * libdwP.h: Add INTDECL.
880 * libdw.map (ELFUTILS_0.144): New set. Add dwarf_aggregate_size.
881
882 * dwarf_srclang.c: Add INTDEF.
883 * libdwP.h: Add INTDECL.
884
Roland McGrathf0371042009-09-10 12:39:09 -0700885 * dwarf.h: Add some more DW_AT_GNU_* types from gcc.
886
887 * dwarf.h: Add DW_AT_GNU_vector, DW_AT_GNU_template_name.
888
8892009-11-21 Roland McGrath <roland@redhat.com>
890
891 * dwarf_getlocation.c (check_constant_offset): Return 1 for all
892 non-constant forms.
Mark Wielaard418ae4c2009-09-09 20:59:26 +0200893
8942009-10-15 Roland McGrath <roland@redhat.com>
895
896 * libdw_form.c (__libdw_form_val_len): Grok DW_FORM_sec_offset,
Josh Stonecc93cc42009-08-21 18:04:44 -0700897 DW_FORM_exprloc, DW_FORM_flag_present, and DW_FORM_ref_sig8.
898
8992009-09-17 Roland McGrath <roland@redhat.com>
900
Roland McGrath08277ba2009-08-10 15:08:08 -0700901 * dwarf_getlocation.c (dwarf_getlocation_implicit_value): Make OP
902 argument a pointer to const.
903 * libdw.h: Update decl.
904
Roland McGrathebfb6482009-08-09 15:40:52 -07009052009-09-10 Roland McGrath <roland@redhat.com>
906
907 * dwarf_getlocation.c (store_implicit_value): New function.
908 (__libdw_intern_expression): Use it, handle DW_OP_implicit_value.
909 (dwarf_getlocation_implicit_value): New function.
910 * libdw.h: Declare it.
911 * libdw.map (ELFUTILS_0.143): Add it.
912
9132009-09-09 Mark Wielaard <mjw@redhat.com>
914
915 * dwarf_getcfi.c (dwarf_getcfi): Clear cfi->ebl.
916
9172009-08-21 Josh Stone <jistone@redhat.com>
918
Roland McGrathde69d522009-08-07 18:26:19 -0700919 * dwarf_hasattr_integrate.c: Integrate DW_AT_specification too.
920
9212009-08-10 Roland McGrath <roland@redhat.com>
922
923 * dwarf_getscopevar.c: Use dwarf_diename.
924
9252009-08-09 Roland McGrath <roland@redhat.com>
926
927 * libdw.map (ELFUTILS_0.143): New version set,
928 inherits from ELFUTILS_0.142.
Roland McGrathaf800142009-07-22 13:55:50 -0700929 * dwarf_arrayorder.c: Use OLD_VERSION and NEW_VERSION to define an
930 alias in the ELFUTILS_0.122 version set and the default in the new set.
931 * dwarf_srclang.c: Likewise.
932 * dwarf_decl_file.c: Likewise.
933 * dwarf_decl_line.c: Likewise.
934 * dwarf_decl_column.c: Likewise.
935 * dwarf_bytesize.c: Likewise.
936 * dwarf_bitsize.c: Likewise.
937 * dwarf_bitoffset.c: Likewise.
938
9392009-08-07 Roland McGrath <roland@redhat.com>
940
941 * dwarf_arrayorder.c: Use dwarf_attr_integrate.
942 * dwarf_srclang.c: Likewise.
943 * dwarf_decl_file.c: Likewise.
944 * dwarf_decl_line.c (__libdw_attr_intval): Likewise.
Roland McGrathe23e9e72009-07-21 18:14:52 -0700945 * dwarf_bytesize.c: Likewise.
946 * dwarf_bitsize.c: Likewise.
947 * dwarf_bitoffset.c: Likewise.
948
9492009-07-22 Roland McGrath <roland@redhat.com>
950
951 * dwarf_frame_cfa.c: Change calling convention.
952 * libdw.h: Update decl.
Roland McGrath96349ff2009-07-20 11:51:41 -0700953
954 * dwarf_frame_register.c: Change calling/return-value convention for
955 value-only results and undefined/same_value.
956 * libdw.h: Update decl.
957
Roland McGratha6abdfd2009-07-16 17:40:19 -0700958 * dwarf_getlocation.c (__libdw_intern_expression): Take new bool
959 argument, append DW_OP_stack_value if set. Don't take NOPS argument,
Roland McGrathe160cc92009-07-16 17:48:27 -0700960 return that value instead.
961 (getlocation): Update caller.
962 * dwarf_frame_cfa.c: Likewise.
963 * libdwP.h: Update decl.
964
Roland McGratha6abdfd2009-07-16 17:40:19 -07009652009-07-21 Roland McGrath <roland@redhat.com>
966
967 * dwarf_getsrc_file.c: Ignore a CU that just has no DW_AT_stmt_list.
968 Fix loop iteration after skipping a bogus or useless CU.
969
970 * dwarf_entry_breakpoints.c: Handle 0 dwarf_errno () as harmless
971 absence, not DWARF_E_NO_DEBUG_LINE.
Roland McGrath7dd94642009-07-15 11:14:23 -0700972
9732009-07-20 Roland McGrath <roland@redhat.com>
974
975 * dwarf_getlocation.c (__libdw_intern_expression):
976 Handle DW_OP_stack_value.
Roland McGrath80893432009-07-13 12:08:55 -0700977
9782009-07-16 Roland McGrath <roland@redhat.com>
979
980 * dwarf_formudata.c (__libdw_formptr): Handle DW_FORM_sec_offset,
Roland McGrathcfdd86e2009-07-08 13:15:07 -0700981 reject others when CU's version > 3.
982
Roland McGrath3c84db32009-06-24 17:41:40 -0700983 * dwarf_formflag.c: Handle DW_FORM_flag_present.
984
985 * dwarf.h: Add DW_OP_{implicit,stack}_value from DWARF 4 draft.
986 Also DW_TAG_type_unit and DW_TAG_rvalue_reference_type.
987 Also DW_AT_signature, DW_AT_main_subprogram, DW_AT_data_bit_offset,
988 and DW_AT_const_expr.
989 Also DW_FORM_sec_offset, DW_FORM_exprloc, DW_FORM_flag_present,
990 and DW_FORM_ref_sig8.
991
9922009-07-15 Roland McGrath <roland@redhat.com>
993
994 * dwarf_getlocation.c: Grok DW_OP_form_tls_address,
995 DW_OP_GNU_push_tls_address, and DW_OP_bit_piece.
996
9972009-07-13 Roland McGrath <roland@redhat.com>
998
999 * dwarf_getlocation.c: Grok DW_OP_call_frame_cfa.
1000
10012009-07-08 Roland McGrath <roland@redhat.com>
1002
1003 * libdw.map (ELFUTILS_0.142): Add dwfl_module_dwarf_cfi,
1004 dwfl_module_eh_cfi.
1005
1006 * libdwP.h (struct Dwarf): Add member `cfi'.
1007 * dwarf_end.c (dwarf_end): Call __libdw_destroy_frame_cache on it.
1008 * dwarf_getcfi.c: New file.
1009 * dwarf_getcfi_elf.c: New file.
1010 * dwarf_cfi_end.c: New file.
1011 * dwarf_cfi_addrframe.c: New file.
1012 * dwarf_frame_cfa.c: New file.
1013 * dwarf_frame_register.c: New file.
1014 * dwarf_frame_return_address_register.c: New file.
1015 * Makefile.am (libdw_a_SOURCES): Add them.
1016 * unwind.h: Declare those functions.
1017 * libdw.map (ELFUTILS_0.142): Export them.
1018
1019 * dwarf_getlocation.c (__libdw_intern_expression): New function,
1020 broken out of ...
1021 (getlocation): ... here, call it.
1022 * libdwP.h: Declare it.
1023
1024 * cie.c: New file.
1025 * fde.c: New file.
1026 * frame-cache.c: New file.
1027 * cfi.c: New file.
1028 * cfi.h: New file.
1029 * encoded-value.h: New file.
1030 * Makefile.am (libdw_a_SOURCES, noinst_HEADERS): Add them.
1031 * libdwP.h: Add DWARF_E_INVALID_CFI to errors enum.
1032 * dwarf_error.c (errmsgs): Add element for it.
1033
1034 * dwarf_next_cfi.c: New file.
1035 * Makefile.am (libdw_a_SOURCES): Add it.
Roland McGrath6e1f4652009-07-08 14:48:34 -07001036 * libdw.h (Dwarf_CIE, Dwarf_FDE, Dwarf_CIE_Entry): New types.
1037 Declare dwarf_next_cfi.
Roland McGrathcfdd86e2009-07-08 13:15:07 -07001038 * libdw.map (ELFUTILS_0.142): New set, inherits from ELFUTILS_0.136.
1039 Add dwarf_next_cfi.
1040
1041 * memory-access.h [! ALLOW_UNALIGNED]
Roland McGrath05c4e042009-06-18 13:56:02 -07001042 (read_2ubyte_unaligned): Renamed to ...
1043 (read_2ubyte_unaligned_1): ... this. Take bool rather than Dwarf *.
1044 (read_2ubyte_unaligned): Define as macro passing dbg->other_byte_order.
1045 (read_2sbyte_unaligned): Likewise.
1046 (read_4ubyte_unaligned): Likewise.
1047 (read_4sbyte_unaligned): Likewise.
1048 (read_8ubyte_unaligned): Likewise.
1049 (read_8sbyte_unaligned): Likewise.
1050
Ulrich Drepper99d23722009-06-14 20:19:45 -07001051 * libdwP.h (IDX_eh_frame): Remove it.
1052 * dwarf_begin_elf.c (dwarf_scnnames): Remove its element.
1053
10542009-07-08 Roland McGrath <roland@redhat.com>
1055
1056 * libdwP.h (struct Dwarf_Line_s): Reorder members to pack better.
1057
1058 * dwarf_getlocation.c (check_constant_offset): New function.
1059 (dwarf_getlocation, dwarf_getlocation_addr): Call it to
1060 handle DW_AT_data_member_location of data[48] as constant offset.
1061
10622009-06-18 Roland McGrath <roland@redhat.com>
1063
1064 * libdwP.h (__libdw_read_address_inc): Constify.
1065 (__libdw_read_offset_inc): Likewise.
1066 * dwarf_getaranges.c: Likewise.
1067 * dwarf_getlocation.c: Likewise.
1068 * dwarf_getsrclines.c: Likewise.
1069 * dwarf_nextcu.c: Likewise.
1070
10712009-05-05 Petr Machata <pmachata@redhat.com>
1072
1073 * libdwP.h (__libdw_formptr): Declare new function.
1074 * dwarf_formudata.c: Implement it here.
1075 * dwarf_getlocation.c (dwarf_getlocation_addr):
1076 Call it instead of hand-rolled offset handling code.
1077 * dwarf_getsrclines.c (dwarf_getsrclines): Likewise.
1078 * dwarf_ranges.c (dwarf_ranges): Likewise.
1079
10802009-05-04 Petr Machata <pmachata@redhat.com>
1081
1082 * libdwP.h (__libdw_read_begin_end_pair_inc): Declare new function.
1083 * dwarf_ranges.c: Implement it here.
1084 (dwarf_ranges): Call it.
Roland McGrathe2eabd82009-05-07 18:54:52 -07001085 * dwarf_getlocation.c (dwarf_getlocation_addr): Call it also here.
1086
10872009-04-23 Petr Machata <pmachata@redhat.com>
1088
1089 * dwarf_formaddr.c (dwarf_formaddr): Call __libdw_read_* instead
1090 of read_*ubyte_unaligned.
Petr Machataf3df61f2009-05-07 21:02:33 +02001091 * dwarf_formref_die.c (dwarf_formref_die): Likewise.
1092 * dwarf_formstring.c (dwarf_formstring): Likewise.
1093 * dwarf_formudate.c (dwarf_formudata): Likewise.
1094 * dwarf_getaranges.c (dwarf_getaranges): Likewise.
1095 * dwarf_getlocation.c (dwarf_getlocation_addr): Likewise.
Roland McGrath2fb90512009-04-15 14:47:13 -07001096 * dwarf_getpubnames.c (get_offsets): Likewise.
1097 * dwarf_nextcu.c (dwarf_nextcu): Likewise.
1098
10992009-04-23 Petr Machata <pmachata@redhat.com>
1100
Roland McGrath6a4bdd92009-04-01 14:25:29 -07001101 * libdwP.h (__libdw_read_addr_inc, __libdw_read_off_inc,
1102 __libdw_read_addr, __libdw_read_off): Add four new internal
1103 functions.
1104
Roland McGrathc5acb302009-01-28 18:28:52 -080011052009-05-07 Roland McGrath <roland@redhat.com>
1106
Roland McGrath03288f02009-01-28 22:00:54 -08001107 * dwarf_getmacros.c (dwarf_getmacros): Use absolute section offset in
1108 return value and OFFSET argument, not CU-relative. Only fetch the
1109 attribute data when called with OFFSET of 0.
Roland McGrathc5acb302009-01-28 18:28:52 -08001110
11112009-05-07 Petr Machata <pmachata@redhat.com>
Roland McGrathf46272a2009-01-26 18:36:16 -08001112
1113 * dwarf_getmacros.c (dwarf_getmacros): Take into account offset in
1114 DW_AT_macro_info attribute of CU DIE.
1115
Roland McGrathd31505f2009-01-25 19:37:33 -080011162009-04-15 Roland McGrath <roland@redhat.com>
1117
1118 * dwarf.h (DW_CIE_ID): Removed.
1119 (DW_CIE_ID_32, DW_CIE_ID_64): New constants replace it.
Roland McGrath3bf7a092009-01-23 16:34:07 -08001120
11212009-04-01 Roland McGrath <roland@redhat.com>
1122
1123 * dwarf.h: Add DW_CFA_GNU_negative_offset_extended.
1124
Roland McGrathafdd51e2009-01-22 02:26:24 -080011252009-01-28 Roland McGrath <roland@redhat.com>
1126
1127 * libdwP.h (struct Dwarf_Line_s): Move out of struct Dwarf_Lines_s
1128 defn so C++ doesn't scope the name to not match the Dwarf_Line typedef.
Roland McGrath1ea4fdc2009-01-21 19:14:37 -08001129
1130 * libdwP.h (struct Dwarf_Files_s): Replace dbg field with cu field.
1131
11322009-01-26 Roland McGrath <roland@redhat.com>
1133
1134 * dwarf_ranges.c: Return 0 when no ranges or *_pc attrs at all.
Roland McGrath24b03302009-01-17 14:34:13 -08001135
11362009-01-25 Roland McGrath <roland@redhat.com>
Roland McGrath54456d82009-01-17 14:39:35 -08001137
1138 * dwarf_getattrs.c: Correctly skip attribute values when restarting.
1139
Roland McGrath5513e642009-01-11 01:35:11 -080011402009-01-23 Roland McGrath <roland@redhat.com>
1141
1142 * Makefile.am ($(srcdir)/known-dwarf.h): Target renamed back.
1143 Put these rules under if MAINTAINER_MODE.
1144
11452009-01-22 Roland McGrath <roland@redhat.com>
1146
Roland McGrath24b03302009-01-17 14:34:13 -08001147 * dwarf.h: Add DW_OP_GNU_encoded_addr.
1148
Ulrich Drepper7e678fa2009-01-10 18:02:05 -080011492009-01-21 Roland McGrath <roland@redhat.com>
1150
1151 * Makefile.am (CLEANFILES): Renamed to ...
1152 (MOSTLYCLEANFILES): ... here.
Roland McGrathe06762c2009-01-08 13:39:08 -08001153 (CLEANFILES): New variable, add known-dwarf.h.
1154
11552009-01-17 Roland McGrath <roland@redhat.com>
1156
Roland McGrath7e827f22009-01-06 02:09:50 -08001157 * Makefile.am (known-dwarf.h): Target renamed, not in $(srcdir).
Roland McGrath1f6d2012008-12-31 00:21:04 -08001158 Make it unconditional.
1159 (BUILT_SOURCES): Updated.
1160
1161 * dwarf.h: Add description comments for DW_LANG_* values.
Roland McGrathbca43152009-01-05 23:59:32 -08001162
1163 * Makefile.am [MAINTAINER_MODE]
1164 ($(srcdir)/known-dwarf.h): New target.
Ulrich Drepperac194d02009-01-06 00:30:01 -08001165 (BUILT_SOURCES): Add it.
1166
Roland McGrathc462c632009-01-06 01:04:31 -08001167 * dwarf.h: Add DW_OP_GNU_push_tls_address, DW_OP_GNU_uninit.
Ulrich Drepperac194d02009-01-06 00:30:01 -08001168
11692009-01-10 Ulrich Drepper <drepper@redhat.com>
1170
1171 * dwarf_error.c: Always use __thread. Remove all !USE_TLS code.
Roland McGrathb4d6f0f2008-08-25 22:55:17 +00001172
11732009-01-08 Roland McGrath <roland@redhat.com>
1174
1175 * Makefile.am (libdw.so): Don't depend on $(zip_LIBS), just link it in.
1176
Ulrich Drepper8d358d92008-01-22 06:34:31 +000011772008-01-06 Roland McGrath <roland@redhat.com>
1178
1179 * libdwP.h (struct Dwarf_Abbrev): Change type of 'has_children' to bool.
1180 Reorder members.
1181 * dwarf_haschildren.c: Return -1 for error case, not 0.
1182
1183 * Makefile.am (libdw.so): Link in $(zip_LIBS).
1184
Ulrich Drepperb27ce002008-01-18 20:08:54 +000011852009-01-06 Ulrich Drepper <drepper@redhat.com>
1186
1187 * dwarf.h: Add definition for unwind and call frame information.
1188
1189 * memory-access.h: Define read_ubyte_unaligned, read_sbyte_unaligned,
Ulrich Drepper35f08c42008-01-18 19:59:08 +00001190 read_ubyte_unaligned_inc, and read_sbyte_unaligned_inc.
1191
11922008-08-15 Roland McGrath <roland@redhat.com>
1193
1194 * libdw.map (ELFUTILS_0.136): New version set, inherits from
1195 ELFUTILS_0.130. Add dwfl_addrsegment, dwfl_report_segment.
1196
11972008-01-21 Ulrich Drepper <drepper@redhat.com>
1198
1199 * dwarf_child.c: Minor optimizations.
1200 * dwarf_getattrs.c: Likewise.
1201 * dwarf_getpubnames.c: Likewise.
1202 * dwarf_siblingof.c: Likewise.
Ulrich Dreppera969d8e2008-01-22 06:15:00 +00001203 * dwarf_tag.c: Likewise.
Ulrich Drepper35f08c42008-01-18 19:59:08 +00001204
12052008-01-18 Ulrich Drepper <drepper@redhat.com>
1206
1207 * dwarf_getsrclines.c (dwarf_getsrclines): Don't require exact match
1208 of DWARF_VERSION comparison, just fail if the file's version is newer.
1209
12102008-01-17 Nick Clifton <nickc@redhat.com>
1211
1212 * dwarf.h (DWARF3_LENGTH_MIN_ESCAPE_CODE): New define.
1213 (DWARF3_LENGTH_MAX_ESCAPE_CODE): New define.
1214 (DWARF3_LENGTH_64_BIT): New define.
1215 * dwarf_getaranges (dwarf_getaranges): Use the new definitions.
1216 * dwarf_getpubnames: Include dwarf.h.
1217 (get_offsets): Use the new definitions.
1218 * dwarf_getsrclines.c (dwarf_getsrclines): Use the new defintions.
1219 * dwarf_nextcu.c: Include dwarf.h. Correct comment.
1220 (dwarf_nextcu): Use the new definitions.
1221
1222 * libdwP.h (DIE_OFFSET_FROM_CU_OFFSET): New macro.
1223 * dwarf_diecu.c (dwarf_diecu): Use the new macro.
1224 * dwarf_getaranges (dwarf_getaranges): Use the new macro.
1225 * dwarf_nextcu.c (dwarf_nextcu): Use the new macro.
1226
1227 * dwarf_getpubnames (get_offsets): Replace assertion with test and
1228 error return.
1229
1230 * dwarf_entry_breakpoints.c (dwarf_entry_breakpoints): Use CUDIE.
1231
1232 * dwarf_siblingof (dwarf_siblingof): Detect a NULL return pointer.
1233 Set the address in the return structure to the address of the next
1234 non-sibling die, if there is no sibling and the return pointer is
1235 not the same as the die pointer.
Ulrich Dreppere219f1c2008-01-09 05:49:49 +00001236 * libdw.h: Expand the description of the dwarf_siblingof prototype.
1237
1238 * dwarf_child.c: Fix typo in comment.
1239
1240 * libdwP.h (DWARF_VERSION): Change to 3.
1241
Roland McGrathe4c22ea2007-10-23 13:07:39 +00001242 * dwarf_formref.c (__libdw_formref.c): Handle attributes which do
1243 not have a initialised valp pointer.
1244
1245 * dwarf_getattrs.c (dwarf_getattrs): Return 1 rather than 0 when
1246 the end of the attributes is reached. When the callback fails,
1247 return the address of the failing attribute, not the address of
1248 its successor.
1249 * libdw.h: Expand the description of the dwarf_getattrs prototype.
1250
1251 * dwarf_child.c (__libdw_find_attr): Use the new definition.
1252 (dwarf_child): Likewise.
1253 * dwarf_tag.c (__libdw_findabbrev): Likewise.
1254 (dwarf_tag): Likewise.
1255
12562008-01-08 Roland McGrath <roland@redhat.com>
1257
1258 * Makefile.am (euinclude): Variable removed.
1259 (pkginclude_HEADERS): Set this instead of euinclude_HEADERS.
1260 (libdw.so): Pass -Wl,--enable-new-dtags,-rpath,$(pkglibdir).
Ulrich Drepperb597dfa2007-10-16 05:21:27 +00001261
12622007-10-17 Roland McGrath <roland@redhat.com>
1263
1264 * libdw.h (__deprecated_attribute__): New macro.
1265 (dwarf_formref): Mark it deprecated.
1266 * dwarf_formref.c (__libdw_formref): New function, broken out of ...
1267 (dwarf_formref): ... here. Call it. Remove INTDEF.
Roland McGrath59ea7f32007-10-04 08:50:09 +00001268 * libdwP.h: Remove INTDECL.
1269 Declare __libdw_formref.
1270 * dwarf_siblingof.c (dwarf_siblingof): Call __libdw_formref instead.
1271 * dwarf_formref_die.c: Likewise. Handle DW_FORM_ref_addr here.
1272
1273 * libdw_form.c (__libdw_form_val_len): Fix DW_FORM_ref_addr result,
1274 needs to check CU->version.
1275
Roland McGrath057ec6b2007-10-02 20:55:05 +00001276 * libdwP.h (struct Dwarf_CU): New member `version'.
1277 * libdw_findcu.c (__libdw_findcu): Initialize it.
1278
1279 * dwarf_child.c: Return 1 for null entry as first child.
1280
Roland McGrathd1a48172007-08-07 19:51:01 +000012812007-10-05 Roland McGrath <roland@redhat.com>
1282
1283 * dwarf_begin_elf.c (check_section): Punt on SHT_NOBITS sections.
1284
1285 * libdw.h (__extern_inline): Rename to __libdw_extern_inline.
1286 [__OPTIMIZE__] (dwarf_whatattr, dwarf_whatform): Update uses.
1287
12882007-10-03 Roland McGrath <roland@redhat.com>
1289
1290 * libdw.map (ELFUTILS_0.130: Add dwfl_build_id_find_elf
1291 and dwfl_build_id_find_debuginfo.
Roland McGrath87d47802007-07-16 22:23:37 +00001292
1293 * libdw.map (ELFUTILS_0.130): New version set, inherits from
1294 ELFUTILS_0.127. Add dwfl_module_build_id, dwfl_module_report_build_id.
1295
12962007-10-02 Roland McGrath <roland@redhat.com>
Roland McGrath43da9892007-04-16 23:13:37 +00001297
1298 * libdw_visit_scopes.c (classify_die): Return walk for class_type and
1299 structure_type.
1300
Roland McGrathbf2ee482007-04-05 09:27:36 +000013012007-08-07 Roland McGrath <roland@redhat.com>
1302
Roland McGrath43da9892007-04-16 23:13:37 +00001303 * dwarf_getscopes.c (pc_match): Swallow dwarf_haspc error return when
1304 error code is DWARF_E_NOERROR (0).
1305
1306 * dwarf_getscopes.c (pc_record): Always bail early if DIE->prune.
1307 Fix typo in __libdw_visit_scopes argument.
1308
1309 * dwarf_getscopes.c (pc_match): Check dwarf_haspc error return,
1310 swallow DWARF_E_NO_DEBUG_RANGES but not other errors.
1311
13122007-07-03 Roland McGrath <roland@redhat.com>
Roland McGrathbf2ee482007-04-05 09:27:36 +00001313
1314 * libdw.h (__extern_inline): New macro.
1315 [__OPTIMIZE__] (dwarf_whatattr, dwarf_whatform): Use it.
1316
Ulrich Drepperc07fbb32007-03-30 19:14:59 +000013172007-04-16 Roland McGrath <roland@redhat.com>
1318
1319 * libdw.map (ELFUTILS_0.127): Add dwfl_module_address_section.
1320
13212007-04-05 Roland McGrath <roland@redhat.com>
1322
1323 * dwarf_getsrcdirs.c: New file.
1324 * Makefile.am (libdw_a_SOURCES): Add it.
Ulrich Drepper6258e742007-03-13 06:22:40 +00001325 * libdw.h: Declare dwarf_getsrcdirs.
1326 * libdw.map (ELFUTILS_0.127): Add it.
1327
1328 * libdwP.h (struct Dwarf_Files_s): New member ndirs.
1329 * dwarf_getsrclines.c (dwarf_getsrclines): Don't clobber NDIRLIST to
1330 zero before we use it to check for DWARF_E_INVALID_DIR_IDX.
1331 Save DIRARRAY in the Dwarf_Files.
1332
1333 * dwarf_ranges.c (dwarf_ranges): Don't sign-extend 32-bit BEGIN
Ulrich Drepper903c1162007-02-15 19:40:37 +00001334 address to check for all-ones base address entry. Check directly.
1335 Reported by Sébastien Dugué <sebastien.dugue@bull.net>.
1336
13372007-03-25 Roland McGrath <roland@redhat.com>
Ulrich Drepperaa915fd2007-02-05 07:25:33 +00001338
1339 * dwarf_begin_elf.c (check_section): Return Dwarf * instead of void.
1340 Return NULL when freeing RESULT on error.
1341 (global_read, scngrp_read): Check return value from check_section,
1342 break out of loop after it has freed RESULT.
1343 (valid_p): Handle null argument.
1344
Roland McGrath8190db62006-12-17 23:56:51 +000013452007-03-12 Roland McGrath <roland@redhat.com>
1346
1347 * libdw.map (ELFUTILS_0.127): Add dwfl_report_begin_add.
1348
13492007-03-04 Roland McGrath <roland@redhat.com>
Roland McGrathc373d852006-10-10 00:25:21 +00001350
1351 * libdw.map (ELFUTILS_0.127): New version set, inherits from
1352 ELFUTILS_0.126. Add dwfl_module_addrsym.
1353
13542007-02-10 Roland McGrath <roland@redhat.com>
1355
1356 * dwarf.h (DW_OP_fbreg): Comment fix.
1357
13582007-02-03 Roland McGrath <roland@redhat.com>
1359
1360 * dwarf_getelf.c (dwarf_getelf): Renamed from dwarf_get_elf.
1361 * libdw.map (ELFUTILS_0.126): New version set, inherits from
Ulrich Drepper077c65f2006-07-12 19:54:51 +00001362 ELFUTILS_0.122. Move dwarf_getelf there; it was never truly
1363 exported in the past.
1364
13652006-12-17 Roland McGrath <roland@redhat.com>
1366
1367 * dwarf_getlocation.c (dwarf_getlocation_addr): Use zero as base
1368 address when the CU is missing attributes due to buggy GCC.
1369
Ulrich Dreppere1812e12006-07-12 07:46:03 +000013702006-08-29 Roland McGrath <roland@redhat.com>
1371
1372 * Makefile.am (CLEANFILES): Add libdw.so.$(VERSION).
1373
1374 * libdw.h (dwarf_diecu): Add __nonnull_attribute__.
1375 (dwarf_child): Don't list arg 1 in __nonnull_attribute__.
1376
Ulrich Drepper3be74472006-05-27 18:15:40 +00001377 * libdw_alloc.c (__libdw_allocate): Take new ALIGN argument, make sure
1378 result is aligned. Adjust NEWP->remaining here for this allocation.
1379 * libdwP.h: Update decl.
1380 (libdw_alloc): Update caller.
Ulrich Dreppere7a73172006-05-22 18:16:45 +00001381
13822006-07-12 Ulrich Drepper <drepper@redhat.com>
1383
1384 * dwarf_child.c: Adjust for internal_function_def removal.
1385 * dwarf_getabbrev.c: Likewise.
Ulrich Drepper4f3d2a22006-05-22 01:30:56 +00001386 * dwarf_tag.c: Likewise.
1387 * libdw_form.c: Likewise.
1388 * memory-access.c: Likewise.
1389
13902006-06-28 Roland McGrath <roland@redhat.com>
Roland McGrath2dade662006-02-28 22:13:20 +00001391
1392 * libdw.map: Export dwfl_linecu, dwfl_line_comp_dir.
1393
1394 * libdw.map: Bump to 0.122; export dwfl_module_getsymtab and
1395 dwfl_module_getsym.
1396
Roland McGrath08333122006-02-27 04:54:26 +000013972006-05-27 Ulrich Drepper <drepper@redhat.com>
1398
1399 * libdw.h: Add extern "C".
1400
Roland McGrath50ffcbf2005-12-23 01:51:43 +000014012006-05-22 Ulrich Drepper <drepper@redhat.com>
1402
1403 * dwarf_getaranges.c (dwarf_getaranges): Handle files without
1404 aranges information.
Roland McGrathdec3a242005-12-12 08:35:55 +00001405
14062006-05-21 Ulrich Drepper <drepper@redhat.com>
1407
1408 * libdw.h: Add nonnull attributes to dwarf_tag, dwarf_getattrs,
1409 dwarf_haschildren.
Roland McGrathf64a4422005-12-09 23:40:30 +00001410
14112006-02-28 Roland McGrath <roland@redhat.com>
1412
1413 * dwarf.h: Add missing DW_ATE_*, DW_TAG_*, DW_LANG_*, DW_CFA_*,
1414 DW_OP_* values, to match DWARF 3.0. Add new DW_DS_*, DW_END_*
1415 values from DWARF 3.0.
Roland McGrath994b4892005-12-05 22:46:21 +00001416
14172006-02-22 Roland McGrath <roland@redhat.com>
1418
1419 * libdw.map: Bump to 0.120; export dwfl_version.
Roland McGrathe47ab762005-11-17 03:16:00 +00001420
14212005-12-22 Roland McGrath <roland@redhat.com>
1422
1423 * libdw.map: Bump to 0.119; export dwfl_linux_proc_maps_report.
1424
14252005-12-12 Roland McGrath <roland@redhat.com>
1426
1427 * dwarf_ranges.c: Copy CU base address-finding code from
Roland McGrath07d4f2f2005-10-28 06:56:24 +00001428 dwarf_getlocation.
1429
14302005-12-09 Roland McGrath <roland@redhat.com>
1431
1432 * dwarf_getlocation.c (dwarf_getlocation_addr): Add some unlikelys.
1433 Delay CU base lookup until it's needed.
1434 If CU base lookup fails with no error, flag invalid DWARF.
1435
14362005-11-25 Roland McGrath <roland@redhat.com>
1437
1438 * libdw.map: Bump to 0.118; export dwfl_module_register_names.
1439
Roland McGrath6724c902005-10-28 07:07:19 +000014402005-11-15 Roland McGrath <roland@redhat.com>
1441
1442 * Makefile.am [BUILD_STATIC] (AM_CFLAGS): Add -fpic.
1443
14442005-11-13 Roland McGrath <roland@redhat.com>
1445
1446 * libdw.map: Bump to 0.117; export dwfl_module_return_value_location.
1447
14482005-10-27 Roland McGrath <roland@redhat.com>
1449
1450 * dwarf_entry_breakpoints.c (search_range): Fix binary search code;
1451 don't match end_sequence markers.
1452
1453 * dwarf_getsrclines.c (compare_lines): Sort end_sequence markers
1454 before normal records at the same address.
1455 * dwarf_getsrc_die.c (dwarf_getsrc_die): Don't match an end_sequence
1456 marker.
1457
14582005-10-26 Roland McGrath <roland@redhat.com>
1459
1460 * dwarf_getfuncs.c (dwarf_getfuncs): Use Dwarf_Die, not Dwarf_Func.
1461 * dwarf_func_file.c: Renamed to ...
1462 * dwarf_decl_file.c: ... here.
1463 * dwarf_func_col.c: Renamed to ...
1464 * dwarf_decl_column.c: ... here.
1465 * dwarf_func_line.c: Renamed to ...
1466 * dwarf_decl_line.c: ... here.
1467 (dwarf_func_line): Renamed to ...
1468 (dwarf_decl_line): ... this. Take a Dwarf_Die * argument.
1469 (__libdw_func_intval): Renamed __libdw_attr_intval.
1470 * dwarf_func_name.c: File removed.
1471 * dwarf_func_lowpc.c: File removed.
1472 * dwarf_func_highpc.c: File removed.
1473 * dwarf_func_entrypc.c: File removed.
1474 * dwarf_func_die.c: File removed.
1475 * Makefile.am (libdw_a_SOURCES): Updated.
1476 * libdw.h: Update decls.
1477 (Dwarf_Func): Type removed.
1478 * libdwP.h: Update decls.
Roland McGrath07d4f2f2005-10-28 06:56:24 +00001479 (struct Dwarf_Func_s): Type removed.
1480 * libdw.map: Updated.
1481
1482 * libdwP.h (CUDIE): New macro.
1483 * dwarf_getlocation.c (dwarf_getlocation_addr): Use it.
1484 * dwarf_getscopes_die.c (dwarf_getscopes_die): Likewise.
1485 * dwarf_ranges.c (dwarf_ranges): Likewise.
1486
1487 * dwarf_getloclist.c: Renamed to ...
1488 * dwarf_getlocation.c: ... here.
1489 (getloclist): Renamed to getlocation.
1490 (dwarf_getloclist): Renamed to dwarf_getlocation.
1491 (dwarf_addrloclists): Renamed to dwarf_getlocation_addr.
1492 * Makefile.am (libdw_a_SOURCES): Updated.
1493 * libdw.h (dwarf_getloclist): Renamed to dwarf_getlocation.
1494 (dwarf_addrloclists): Renamed dwarf_getlocation_addr.
1495 (Dwarf_Loc): Renamed Dwarf_Op.
1496 * libdwP.h (struct loc_s): Update use.
1497 * libdw.map: Update map.
1498
1499 * dwarf_entry_breakpoints.c: Use the second line record within the
1500 function, regardless of its source location data.
1501
15022005-10-25 Roland McGrath <roland@redhat.com>
1503
1504 * dwarf_entry_breakpoints.c: Fall back to entrypc for contiguous too.
1505
1506 * libdw.map: Add dwarf_entrypc, dwarf_entry_breakpoints.
1507
15082005-10-14 Roland McGrath <roland@redhat.com>
1509
1510 * dwarf_diecu.c (dwarf_diecu): New file.
1511 * Makefile.am (libdw_a_SOURCES): Add it.
1512 * libdw.h: Declare dwarf_diecu.
1513 * libdw.map: Export it.
1514
1515 * libdw.map: Bump to 0.116; export dwarf_ranges.
1516
15172005-09-20 Roland McGrath <roland@redhat.com>
1518
1519 * dwarf_haspc.c: Use dwarf_ranges.
1520 * dwarf_entry_breakpoints.c: Likewise.
1521
1522 * dwarf_ranges.c: New file.
1523 * Makefile.am (libdw_a_SOURCES): Add it.
1524 * libdw.h: Declare dwarf_ranges.
1525 * libdwP.h: Add INTDECL.
1526
Ulrich Drepperfbe998a2005-08-29 16:27:10 +000015272005-09-14 Roland McGrath <roland@redhat.com>
1528
1529 * dwarf_entry_breakpoints.c (dwarf_entry_breakpoints): Fix braino in
1530 prologue_end marker scanning loop.
1531
15322005-09-11 Roland McGrath <roland@redhat.com>
Roland McGrath71e15a02005-08-27 10:33:26 +00001533
1534 * dwarf.h: Comment typo fix.
1535
15362005-09-07 Roland McGrath <roland@redhat.com>
1537
1538 * dwarf_entry_breakpoints.c: New file.
1539 * Makefile.am (libdw_a_SOURCES): Add it.
1540 * libdw.h: Declare dwarf_entry_breakpoints.
1541
1542 * dwarf_entrypc.c: New file.
1543 * Makefile.am (libdw_a_SOURCES): Add it.
1544 * libdw.h: Declare dwarf_entrypc.
1545 * libdwP.h: Add INTDECL.
1546
15472005-08-28 Ulrich Drepper <drepper@redhat.com>
1548
1549 * Makefile.am: Use $(LINK) not $(CC) when creating DSO.
1550 (%.os): Use COMPILE.os.
1551 (COMPILE.os): Filter out gconv options.
1552
15532005-08-27 Roland McGrath <roland@redhat.com>
1554
Roland McGrathd17fac72005-08-23 08:20:21 +00001555 * dwarf_getscopes.c (dwarf_getscopes): Rewritten using
1556 __libdw_visit_scopes.
1557
1558 * dwarf_getscopes_die.c: New file.
1559 * Makefile.am (libdw_a_SOURCES): Add it.
1560 * libdw.h: Declare dwarf_getscopes_die.
1561 * libdw.map: Bump to 0.115 and add it.
1562
1563 * libdw_visit_scopes.c (__libdw_visit_scopes): Pass a struct
1564 containing a DIE and its parent pointer, instead of just Dwarf_Die.
1565 Take two functions for both preorder and postorder visitors.
1566 * libdwP.h: Update decl.
1567 (struct Dwarf_Die_Chain): New type.
1568 * dwarf_func_inline.c: Update uses.
1569
1570 * dwarf_diename.c (dwarf_diename): Use dwarf_attr_integrate.
1571 Add INTDEF.
Roland McGrathf5fda7d2005-08-18 22:01:57 +00001572 * libdwP.h: Add INTDECL.
1573 * dwarf_func_name.c (dwarf_func_name): Use dwarf_diename.
1574
15752005-08-23 Roland McGrath <roland@redhat.com>
1576
Roland McGrath1ecb6062005-08-15 09:53:04 +00001577 * dwarf_attr_integrate.c (dwarf_attr_integrate): Treat
1578 DW_AT_specification the same as DW_AT_abstract_origin.
1579
15802005-08-20 Roland McGrath <roland@redhat.com>
1581
1582 * libdw.map: Add dwfl_cumodule, remove dwfl_linecu.
1583 Add dwfl_linux_kernel_report_offline, dwfl_offline_section_address,
1584 and dwfl_report_offline.
1585
15862005-08-19 Roland McGrath <roland@redhat.com>
1587
1588 * libdw.map: Bump version to ELFUTILS_0.114 for libdwfl changes.
Roland McGrath1c83bf12005-08-11 07:03:55 +00001589 Add dwfl_module_relocate_address, dwfl_module_relocations,
Ulrich Drepper6d5c3bd2005-08-11 04:37:52 +00001590 dwfl_module_relocation_info.
Roland McGrath1c83bf12005-08-11 07:03:55 +00001591
15922005-08-18 Roland McGrath <roland@redhat.com>
Ulrich Drepper6d5c3bd2005-08-11 04:37:52 +00001593
Roland McGrath4959bf82005-08-09 10:31:08 +00001594 * dwarf_getscopes.c (dwarf_getscopes): Include the CU itself as
1595 outermost scope in the results.
Roland McGrathb6312e12005-08-09 10:36:01 +00001596
15972005-08-15 Roland McGrath <roland@redhat.com>
Roland McGrath4959bf82005-08-09 10:31:08 +00001598
1599 * dwarf_func_inline.c: New file.
1600 * Makefile.am (libdw_a_SOURCES): Add it.
1601 * libdw.h: Declare dwarf_func_inline, dwarf_func_inline_instances.
Roland McGratha5a89682005-08-02 01:24:01 +00001602 * libdw.map: Add them.
1603
1604 * dwarf_func_die.c: New file.
1605 * Makefile.am (libdw_a_SOURCES): Add it.
1606 * libdw.h: Declare dwarf_func_die.
Ulrich Drepper18618fd2005-07-28 21:29:22 +00001607 * libdw.map: Add it. Bump version to ELFUTILS_0.114.
1608
16092005-08-10 Ulrich Drepper <drepper@redhat.com>
1610
1611 * dwarf_getsrclines.c (dwarf_getsrclines): Correct fallout of renaming
Roland McGrath366784a2005-07-28 06:20:53 +00001612 of DW_LNS_set_epilog_begin.
1613
Roland McGrath18385902005-07-28 07:12:38 +000016142005-08-09 Roland McGrath <roland@redhat.com>
1615
1616 * dwarf.h (DW_LNS_set_epilog_begin): Renamed DW_LNS_set_epilogue_begin.
1617
1618 * dwarf_end.c: Add INTDEF.
1619 * dwarf_error.c (dwarf_errmsg): Likewise.
Roland McGrath366784a2005-07-28 06:20:53 +00001620 * libdwP.h (dwarf_end, dwarf_errmsg): Add INTDECLs.
1621
16222005-08-01 Roland McGrath <roland@redhat.com>
Ulrich Drepperb08d5a82005-07-26 05:00:05 +00001623
1624 * dwarf_getaranges.c (dwarf_getaranges): Check for bogus offset.
1625 * dwarf_getabbrev.c (__libdw_getabbrev): Likewise.
1626
16272005-07-28 Ulrich Drepper <drepper@redhat.com>
1628
1629 * Makefile.am (libdw.so): No need to link with libeu.a anymore.
1630 (libdw_a_LIBADD): Add all files from libdwfl.a.
1631
16322005-07-27 Roland McGrath <roland@redhat.com>
1633
1634 * Makefile.am (libdw.so): Link ../libdwfl/libdwfl_pic.a in,
1635 along with ../libebl/libebl.a and ../lib/libeu.a;
1636 depend on ../libelf/libelf.so.
1637 (libdw_so_LDADD): New variable.
1638 * libdw.map: Add dwfl_* symbols formerly in ../libdwfl/libdwfl.map.
1639
1640 * libdw.map: Define an empty base version and move all symbols to
1641 version ELFUTILS_0.111; don't define ELFUTILS_1.0 at all yet.
1642
16432005-07-23 Ulrich Drepper <drepper@redhat.com>
1644
1645 * dwarf_error.c: Add internal alias for dwarf_errno.
1646 * libdwP.h: Declare __dwarf_errno_internal.
1647 * dwarf_getloclist.c: Use INTDEF for dwarf_errno.
1648
1649 * dwarf_error.c [USE_TLS]: Actually use __thread in definition of
1650 global_error.
1651
16522005-06-01 Roland McGrath <roland@redhat.com>
1653
1654 * dwarf_getaranges.c (dwarf_getaranges): Sort result array.
1655 * dwarf_getarange_addr.c (dwarf_getarange_addr): Use binary search.
1656
16572005-06-08 Roland McGrath <roland@redhat.com>
1658
1659 * memory-access.h (get_uleb128_step, get_uleb128): Remove casts.
1660 (get_sleb128_step, get_sleb128): Likewise.
1661 * dwarf_getattrs.c (dwarf_getattrs): Add consts.
1662 * dwarf_getloclist.c (getloclist): Likewise.
1663 * dwarf_formblock.c (dwarf_formblock): Likewise.
1664 * dwarf_getsrclines.c (dwarf_getsrclines): Likewise.
1665 * dwarf_getabbrevattr.c (dwarf_getabbrevattr): Likewise.
1666 * dwarf_formref.c (dwarf_formref): Likewise.
1667 * dwarf_formsdata.c (dwarf_formsdata): Likewise.
1668 * dwarf_formudata.c (dwarf_formudata): Likewise.
1669 * dwarf_haschildren.c (dwarf_haschildren): Likewise.
1670 * dwarf_child.c (__libdw_find_attr, __libdw_find_attr): Likewise.
1671 * dwarf_tag.c (dwarf_tag): Likewise.
1672 * dwarf_getabbrev.c (__libdw_getabbrev): Likewise.
1673 * memory-access.c (__libdw_get_uleb128, __libdw_get_sleb128): Likewise.
1674 * libdw_form.c (__libdw_form_val_len): Likewise.
1675 * libdwP.h: Update decl.
1676
16772005-06-04 Roland McGrath <roland@redhat.com>
1678
1679 * memory-access.h (get_uleb128_rest_return): New macro.
1680 [! IS_LIBDW] (__libdw_get_uleb128): New static, defined using it.
1681 (get_sleb128_rest_return): New macro.
1682 [! IS_LIBDW] (__libdw_get_sleb128): New static, defined using it.
1683 * memory-access.c: New file.
1684 * Makefile.am (libdw_a_SOURCES): Add it.
1685 (DEFS): Add -DIS_LIBDW.
1686
16872005-05-31 Roland McGrath <roland@redhat.com>
1688
1689 * dwarf_formref_die.c (dwarf_formref_die): Add CU header offset to
1690 formref offset.
1691
16922005-05-30 Roland McGrath <roland@redhat.com>
1693
1694 * dwarf_getloclist.c (dwarf_addrloclists): Use DW_AT_entry_pc for base
1695 address if DW_AT_low_pc is missing. Not to spec, but GCC generates it.
1696
1697 * dwarf_getloclist.c (dwarf_addrloclists): Don't sign-extend 4-byte
1698 BEGIN value. Instead, match base address entries separately for
1699 32/64 size cases.
1700
17012005-05-28 Roland McGrath <roland@redhat.com>
1702
1703 * dwarf_getloclist.c (dwarf_addrloclists): Fix decoding to advance
1704 past location expression contents.
1705
17062005-05-23 Roland McGrath <roland@redhat.com>
1707
1708 * dwarf_getsrclines.c: Comment typo fix.
1709
1710 * dwarf_haspc.c (dwarf_haspc): Fix CU DIE address calculation.
1711 * dwarf_getloclist.c (dwarf_addrloclists): Likewise.
1712
17132005-05-22 Ulrich Drepper <drepper@redhat.com>
1714
1715 * libdwP.h: Only use INTDECL for alias prototypes.
1716
17172005-05-19 Roland McGrath <roland@redhat.com>
1718
1719 * dwarf_getloclist.c (attr_ok): Permit DW_AT_static_link too.
1720
1721 * dwarf_getscopevar.c: New file.
1722 * Makefile.am (libdw_a_SOURCES): Add it.
1723 * libdw.h: Declare dwarf_getscopevar.
1724
1725 * dwarf_getsrcfiles.c: Add INTDEF.
1726 * dwarf_haschildren.c: Likewise.
1727 * libdwP.h (dwarf_getsrcfiles, dwarf_haschildren): Add INTDECL.
1728
1729 * dwarf_getscopes.c: New file.
1730 * Makefile.am (libdw_a_SOURCES): Add it.
1731 * libdw.h: Declare dwarf_getscopes.
1732 * libdw.map: Add it.
1733
17342005-05-18 Roland McGrath <roland@redhat.com>
1735
1736 * libdwP.h (IDX_debug_ranges): New enum constant.
1737 * dwarf_begin_elf.c (dwarf_scnnames): Add it for ".debug_ranges".
1738 * libdwP.h (DWARF_E_NO_DEBUG_RANGES): New enum constant.
1739 * dwarf_error.c (errmsgs): Add it.
1740 * dwarf_haspc.c: New file.
1741 * libdw.h: Declare dwarf_haspc.
1742 * libdw.map: Add it.
1743 * libdwP.h: Add INTDECL.
1744
1745 * dwarf_attr_integrate.c: New file.
1746 * dwarf_hasattr_integrate.c: New file.
1747 * Makefile.am (libdw_a_SOURCES): Add them.
1748 * libdw.h: Declare dwarf_attr_integrate, dwarf_hasattr_integrate.
1749 * libdw.map: Add them.
1750
1751 * dwarf_hasattr.c: Add INTDEF.
1752 * libdwP.h: Add INTDECL for it.
1753
1754 * dwarf_formref_die.c: New file.
1755 * Makefile.am (libdw_a_SOURCES): Add it.
1756 * libdw.h (dwarf_formref_die): Declare it.
1757 * libdwP.h (dwarf_formref_die): Add INTDECL.
1758 * libdw.map: Add it.
1759
1760 * dwarf_getloclist.c (attr_ok, getloclist): New functions, broken out
1761 of ...
1762 (dwarf_getloclist): ... here. Call them.
1763 (dwarf_addrloclists): New function.
1764 * libdw.h: Declare it.
1765 * libdw.map: Add it.
1766
1767 * dwarf_getmacros.c (dwarf_getmacros): Don't bail at
1768 DW_MACINFO_end_file. Recognize type 0 as terminator.
1769
17702005-05-05 Roland McGrath <roland@redhat.com>
1771
1772 * dwarf_getsrc_die.c (dwarf_getsrc_die): Use binary search.
1773
1774 * dwarf_getsrclines.c (dwarf_getsrclines): Sort result array, since
1775 the line program does not produce all entries in ascending order.
1776
17772005-04-25 Ulrich Drepper <drepper@redhat.com>
1778
1779 * dwarf_getsrc_file.c (dwarf_getsrc_file): Handle multiple
1780 occurences (e.g., inlines) better.
1781
17822005-04-24 Ulrich Drepper <drepper@redhat.com>
1783
1784 * libdw.h (DWARF_END_ABBREV): Define.
1785 * dwarf_getabbrev.c (__libdw_getabbrev): Return DWARF_END_ABBREV if
1786 end is reached.
1787 * dwarf_offabbrev.c (dwarf_offabbrev): Return -1 on error, 1 if end
1788 of records reached.
1789 * dwarf_tag.c (__libdw_findabbrev): Also recognize DWARF_END_ABBREV
1790 as error of __libdw_getabbrev.
1791
17922005-04-04 Ulrich Drepper <drepper@redhat.com>
1793
1794 * dwarf_getsrc_file.c (dwarf_getsrc_file): Minor optimization.
1795
1796 * dwarf_getsrc_file.c (dwarf_getsrc_file): Always pass number of
1797 results back to caller.
1798
17992005-04-04 Roland McGrath <roland@redhat.com>
1800
1801 * dwarf_getsrc_file.c (dwarf_getsrc_file): Use size_t for CUHL.
1802
1803 * dwarf_func_line.c (__libdw_func_intval): Use internal_function in
1804 defn.
1805
18062005-04-04 Ulrich Drepper <drepper@redhat.com>
1807
1808 * dwarf_getsrc_file.c (dwarf_getsrc_file): Use INTUSE.
1809
1810 * dwarf_getsrc_file.c: New file.
1811 * Makefile.am (libdw_a_SOURCES): Add dwarf_getsrc_file.c.
1812 * libdw.h: Declare dwarf_getsrc_file.
1813 * libdw.map: Add dwarf_getsrc_file.
1814
18152005-04-02 Ulrich Drepper <drepper@redhat.com>
1816
1817 * dwarf_func_entrypc.c: New file.
1818 * dwarf_func_col.c: New file.
1819 * dwarf_func_line.c: New file.
1820 * dwarf_func_file.c: New file.
1821 * libdw.h: Add prototypes for new functions.
1822 * libdw.map: Add dwarf_func_entrypc, dwarf_func_col, dwarf_func_line,
1823 dwarf_func_file.
1824 * Makefile.am (libdw_a_SOURCES): Add dwarf_func_entrypc.c,
1825 dwarf_func_col.c, dwarf_func_line.c, dwarf_func_file.c.
1826 * libdwP.h (struct Dwarf_Func_s): Add cudie element.
1827 Declare __libdw_func_intval and __dwarf_formsdata_internal.
1828 * dwarf_getfuncs.c: Also fill in cudie in Dwarf_Func object.
1829 * dwarf_formsdata.c: Use INTUSE and INTDEF to avoid PLTs.
1830
1831 * dwarf.h: Add some DWARF3 definitions.
1832
18332005-04-01 Ulrich Drepper <drepper@redhat.com>
1834
1835 * dwarf_getfuncs.c: New file.
1836 * dwarf_func_highpc.c: New file.
1837 * dwarf_func_lowpc.c: New file.
1838 * dwarf_func_name.c: New file.
1839 * Makefile.am (libdw_a_SOURCES): Add dwarf_getfuncs.c,
1840 dwarf_func_highpc.c, dwarf_func_lowpc.c, and dwarf_func_name.c.
1841 * libdw.map: Add dwarf_getfuncs, dwarf_func_highpc, dwarf_func_lowpc,
1842 and dwarf_func_name.
1843 * libdw.h: Add prototypes for new functions.
1844 * dwarf_child.c: Use INTUSE and INTDEF to avoid PLTs.
1845 * dwarf_siblingof.c: Likewise.
1846 * dwarf_dieoffset.c: Likewise.
1847 * dwarf_highpc.c: Likewise.
1848 * dwarf_lowpc.c: Likewise.
1849 * libdwP.h: Add prototypes for internal functions.
1850 Define Dwarf_Func_s structure.
1851
18522005-03-29 Ulrich Drepper <drepper@redhat.com>
1853
1854 * libdw.h: Add padding in Dwarf_die.
1855
1856 * dwarf_arrayorder.c: Use INTUSE and INTDEF to avoid PLTs.
1857 * dwarf_attr.c: Likewise.
1858 * dwarf_begin.c: Likewise.
1859 * dwarf_begin_elf.c: Likewise.
1860 * dwarf_bitoffset.c: Likewise.
1861 * dwarf_bitsize.c: Likewise.
1862 * dwarf_bytesize.c: Likewise.
1863 * dwarf_diename.c: Likewise.
1864 * dwarf_formaddr.c: Likewise.
1865 * dwarf_formblock.c: Likewise.
1866 * dwarf_formref.c: Likewise.
1867 * dwarf_formstring.c: Likewise.
1868 * dwarf_formudata.c: Likewise.
1869 * dwarf_getarange_addr.c: Likewise.
1870 * dwarf_getarangeinfo.c: Likewise.
1871 * dwarf_getaranges.c: Likewise.
1872 * dwarf_getloclist.c: Likewise.
1873 * dwarf_getmacros.c: Likewise.
1874 * dwarf_getsrc_die.c: Likewise.
1875 * dwarf_getsrcfiles.c: Likewise.
1876 * dwarf_getsrclines.c: Likewise.
1877 * dwarf_highpc.c: Likewise.
1878 * dwarf_lowpc.c: Likewise.
1879 * dwarf_nextcu.c: Likewise.
1880 * dwarf_offdie.c: Likewise.
1881 * dwarf_siblingof.c: Likewise.
1882 * dwarf_srclang.c: Likewise.
1883 * dwarf_tag.c: Likewise.
1884 * libdw_findcu.c: Likewise.
1885 * libdwP.h: Add prototypes for internal functions.
1886
1887 * dwarf_addrdie.c: New file.
1888 * dwarf_macro_opcode.c: New file.
1889 * dwarf_macro_param1.c: New file.
1890 * dwarf_macro_param2.c: New file.
1891 * libdw.h: Add declarations. Move Dwarf_Macro definition to libdwP.h.
1892 * libdwP.h: Remove Dwarf_Macro definition.
1893 * Makefile.am (libdw_a_SOURCES): Add dwarf_addrdie.c,
1894 dwarf_macro_opcode.c, dwarf_macro_param1.c, and dwarf_macro_param2.c.
1895 * libdw.map: Add entries for new functions.
1896
18972005-03-21 Ulrich Drepper <drepper@redhat.com>
1898
1899 * libdw.h: Handle broken gcc < 4.
1900
19012005-02-15 Ulrich Drepper <drepper@redhat.com>
1902
1903 * Makefile (AM_CFLAGS): Add -Wunused -Wextra -Wformat=2.
1904
1905 * dwarf_begin_elf.c: Fix warnings.
1906 * dwarf_dieoffset.c: Likewise.
1907 * dwarf_end.c: Likewise.
1908 * dwarf_error.c: Likewise.
1909 * dwarf_getpubnames.c: Likewise.
1910
1911 * libdwP.h: Add new error values.
1912 * dwarf_error.c: Support new error values.
1913 * dwarf_getpubnames.c: Check parameter value.
1914
19152005-02-05 Ulrich Drepper <drepper@redhat.com>
1916
1917 * Makefile.am: Check for text relocations in constructed DSO.
1918
1919 * Makefile.am [MUDFLAP] (AM_CFLAGS): Add -fmudflap.
1920
19212005-02-04 Ulrich Drepper <drepper@redhat.com>
1922
1923 * dwarf_siblingof.c (dwarf_siblingof): Add some buffer boundary
1924 checks to not read over buffer boundaries for ill-formed DWARF data.
1925
19262004-09-25 Ulrich Drepper <drepper@redhat.com>
1927
1928 * dwarf_child.c: Make compile with gcc 4.0.
1929 * dwarf_error.c: Likewise.
1930 * dwarf_formblock.c: Likewise.
1931 * dwarf_getabbrev.c: Likewise.
1932 * dwarf_getattrs.c: Likewise.
1933 * dwarf_getsrclines.c: Likewise.
1934 * dwarf_tag.c: Likewise.
1935 * libdw_form.c: Likewise.
1936
19372004-01-20 Ulrich Drepper <drepper@redhat.com>
1938
1939 * Makefile.am: Support building with mudflap.
1940
1941 * dwarf_getloclist.c: Fix warnings gcc 3.4 spits out.
1942 * dwarf_getsrclines.c: Likewise.
1943 * dwarf_memory-access.h: Likewise.
1944
19452004-01-19 Ulrich Drepper <drepper@redhat.com>
1946
1947 * dwarf_getsrcfiles.c: Third parameter can be NULL.
1948
1949 * libdw.h: Define Dwarf_macro. Declare dwarf_getmacros.
1950 Third parameter of dwarf_getsrcfiles can be NULL.
1951
1952 * libdw.map: Add dwarf_getmacros.
1953 * Makefile.am (libdw_a_SOURCES): Add dwarf_getmacros.
1954 * dwarf_getmacros.c: New file.
1955
19562004-01-18 Ulrich Drepper <drepper@redhat.com>
1957
1958 * libdw.h: Second parameter of dwarf_getaranges can be NULL.
1959
1960 * dwarf_nextcu.c: Return -1 if dwarf parameter is NULL.
1961
1962 * dwarf_getsrclines.c:
1963 Use read_2ubyte_unaligned_inc instead of _inc-less variant.
1964
1965 * dwarf_getaranges.c: Allow naranges parameter to be NULL.
1966
1967 * libdwP.h (_): Use elfutils domain.
1968
1969 * dwarf_getsrclines.c (dwarf_getsrclines): Add more branch prediction.
1970
1971 * dwarf_getsrclines.c: Fix typo in comment.
1972
19732004-01-17 Ulrich Drepper <drepper@redhat.com>
1974
1975 * Makefile.am: Support building with mudflap.
1976
19772004-01-16 Ulrich Drepper <drepper@redhat.com>
1978
1979 * memory-access.h: Add lots of const in case a pointer passed is const.
1980
1981 * dwarf_formflag.c: New file.
1982 * dwarf_getattrs.c: New file.
1983 * dwarf_error.c: Add new error value.
1984 * libdw.h: Add prototypes for new functions. Adjust prototype for
1985 dwarf_getpubnames.
1986 * libdw.map: Add new functions.
1987 * dwarf_getpubnames.c: Change type of return value and fourth parameter
1988 to ptrdiff_t.
1989 * libdwP.h: Add new error value.
1990 * Makefile.am (libdw_a_SOURCES): Add dwarf_getattrs.c and
1991 dwarf_formflag.c.
1992
1993 * dwarf_getpubnames.c (dwarf_getpubnames): Just fail if dbg is NULL.
1994
19952004-01-12 Ulrich Drepper <drepper@redhat.com>
1996
1997 * dwarf_getarange_addr.c: New file
1998 * dwarf_getarangeinfo.c: New file.
1999 * dwarf_getaranges.c: New file.
2000 * dwarf_onerange.c: New file.
2001 * libdw.h: Declare new functions. Define Dwarf_Arange and
2002 Dwarf_Aranges.
2003 * libdw.map: Add new functions.
2004 * libdwP.h: Add new errors. Add aranges member to struct Dwarf.
2005 Define Dwarf_Aranges_s and Dwarf_Arange_s.
2006 * Makefile.am (libdw_a_SOURCES): Add dwarf_getaranges.c,
2007 dwarf_onearange.c, dwarf_getarangeinfo.c, dwarf_getarange_addr.c.
2008 * dwarf_error.c: Add new message.
2009
20102004-01-11 Ulrich Drepper <drepper@redhat.com>
2011
2012 * Makefile.am (libdw_a_SOURCES): Add dwarf_lineaddr.c, dwarf_linecol.c,
2013 dwarf_linebeginstatement.c, dwarf_lineendsequence.c, dwarf_lineblock.c,
2014 dwarf_lineprologueend.c, dwarf_lineepiloguebegin.c, dwarf_onesrcline.c.
2015 * dwarf_error.c: Add another message.
2016 * dwarf_getsrc_die.c: Adjust for Dwarf_Files and Dwarf_Lines
2017 introduction.
2018 * dwarf_filesrc.c: Likewise.
2019 * dwarf_getsrcfiles.c: Likewise.
2020 * dwarf_getsrclines.c: Likewise.
2021 * dwarf_lineaddr.c: New file.
2022 * dwarf_linebeginstatement.c: New file.
2023 * dwarf_lineblock.c: New file.
2024 * dwarf_linecol.c: New file.
2025 * dwarf_lineendsequence.c: New file.
2026 * dwarf_lineepiloguebegin.c: New file.
2027 * dwarf_lineno.c: New file.
2028 * dwarf_lineprologueend.c: New file.
2029 * dwarf_onesrcline.c: New file.
2030 * dwarf_lineno.c: Change interface to store result in object pointed
2031 to by second parameter.
2032 * libdw.h: Add prototypes for new functions. Change dwarf_lineno
2033 prototype. Define Dwarf_Files and Dwarf_Lines.
2034 * libdw.map: Add new functions.
2035 * libdwP.h: Define Dwarf_Files_s and Dwarf_Lines_s.
2036 * libdw_findcu.c: Don't initialize nlines field.
2037
2038 * dwarf_siblingof: Little optimization.
2039
2040 * dwarf_begin.c: Remember that the ELF descriptor must be closed.
2041 * dwarf_end.c: Close ELF descriptor if free_elf is set.
2042 * libdwP.h (struct Dwarf): Add free_elf field.
2043
2044 * Makefile.am (libdw_a_SOURCES): Add dwarf_getstring.c and
2045 dwarf_offabbrev.c.
2046 * dwarf_getstring.c: New file.
2047 * dwarf_offabbrev.c: New file.
2048 * libdw.map: Add dwarf_getstring and dwarf_offabbrev.
2049 * dwarf_getabbrev.c (__libdw_getabbrev): Add new dbg and result
2050 parameters. Don't allocate memory if not necessary and don't lookup
2051 previous results if no CU given.
2052 (dwarf_getabbrev): Adjust call to __libdw_getabbrev.
2053 * dwarf_tag.c: Adjust call to __libdw_getabbrev.
2054 * libdw.h: Declare dwarf_offabbrev and dwarf_getstring.
2055 * libdwP.h: Change prototype for __libdw_getabbrev.
2056
2057 * dwarf_getabbrevattr.c: Add offsetp parameter. Fill in before
2058 returning if this is wanted.
2059
20602004-01-09 Ulrich Drepper <drepper@redhat.com>
2061
2062 * dwarf_nextcu.c: Add new parameter offset_sizep. Initialize it
2063 with offset_size value.
2064 * libdw.h: Adjust dwarf_nextcu prototype.
2065 * libdwP.h (struct Dwarf_CU): Add offset_size member.
2066 * libdw_findcu.c: Adjust dwarf_nextcu call. Initialize offset_size
2067 member of new CU struct.
2068 * dwarf_formstring.c: Depend on offset_size not address_size for
2069 DW_FORM_strp handling.
2070 * dwarf_form.c: Likewise for DW_FORM_strp and DW_FORM_ref_addr.
2071
2072 * dwarf_tag.c (__libdw_findabbrev): Return correct value for
2073 failing lookup.
2074 (dwarf_tag): Correctly recognize failed lookup.
2075
2076 * dwarf_end.c (cu_free): Call tdestroy for locs member. Use new
2077 function noop_free.
2078 * dwarf_error.c: Add message for DWARF_E_NO_BLOCK.
2079 * dwarf_formblock.c: New file.
2080 * dwarf_getloclist.c: Rewrite to handle a single block.
2081 * libdw.h: Define Dwarf_Block. Rename Dwarf_Loc members. Remove
2082 Dwarf_Locdesc definition. Declare dwarf_formblock. Remove
2083 dwarf_getloclistent declaration.
2084 * libdw.map: Add dwarf_formblock, remove dwarf_getloclistent.
2085 * libdwP.h: Define struct loc_s and DWARF_E_NO_BLOCK.
2086 Add locs member to struct Dwarf_CU.
2087 * libdw_fundcu.c: Initialize locs member of new CU.
2088 * Makefile.am (libdw_a_SOURCES): Add dwarf_formblock.c.
2089 Remove dwarf_getloclistent.c.
2090
20912004-01-07 Ulrich Drepper <drepper@redhat.com>
2092
2093 * libdw.h: Use __nonnull__ attribute only for gcc >= 3.3.
2094 * libdwP.h: Likewise.
2095
2096 * dwarf_getloclist.c: New file.
2097 * dwarf_getloclistent.c: New file.
2098 * libdw.h: Define Dwarf_Loc and Dwarf_Locdesc.
2099 Declare dwarf_getloclistent and dwarf_getloclist.
2100 * libdw.map: Add dwarf_getloclistent and dwarf_getloclist.
2101 * libdwP.h: Define DWARF_E_NO_LOCLIST.
2102 * Makefile.am (libdw_a_SOURCES): Add dwarf_getloclistent.c and
2103 dwarf_getloclist.c.
2104
2105 * dwarf_error.c: More error messages.
2106
21072004-01-06 Ulrich Drepper <drepper@redhat.com>
2108
2109 * dwarf_getsrclines.c: Remove debugging support.
2110
2111 * dwarf_getsrcfiles.c: New file.
2112 * dwarf_filesrc.c: New file.
2113 * libdw.h: Declare these functions. Define Dwarf_File.
2114 * libdwP.c: Adjust Dwarf_File_s definition.
2115 * libdw.map: Add these functions.
2116 * Makefile.am (libdw_a_SOURCES): Add dwarf_getsrcfiles.c and
2117 dwarf_filesrc.c.
2118 * dwarf_getsrclines.c: Initialize cu->files.
2119
21202004-01-05 Ulrich Drepper <drepper@redhat.com>
2121
2122 * libdw.h: Add more nonnull function attributes.
2123
2124 * dwarf_begin_elf.c (dwarf_begin_elf): Don't initialize mem_tail->next.
2125 * dwarf_end.c (cu_free): New function.
2126 (dwarf_end): Also free CU tree. Correct freeing of memory blocks.
2127 * dwarf_error.c (errmsgs): Add new messages.
2128 * dwarf_getsrc_die.c: New file.
2129 * dwarf_getsrclines.c: New file.
2130 * dwarf_lineno.c: New file.
2131 * dwarf_linesrc.c: New file.
2132 * dwarf_nextcu.c (dwarf_nextcu): Use read_*byte_unaligned_inc
2133 instead of the *_inc-less variants.
Ulrich Drepper6fb34512010-05-28 20:28:04 -07002134 * libdw.h: Define Dwarf_Line. Add some function attributes. Declare
Ulrich Drepperb08d5a82005-07-26 05:00:05 +00002135 dwarf_getsrclines, dwarf_getsrc_die, dwarf_lineno, and dwarf_linesrc.
2136 * libdw.map: Add dwarf_getsrclines, dwarf_getsrc_die, dwarf_lineno,
2137 and dwarf_linesrc.
2138 * libdwP.h: Add more error codes.
2139 (struct Dwarf): Remove mem_tail.next member.
2140 (Dwarf_File): Define type.
2141 (struct Dwarf_Line_s): Define type.
2142 (struct Dwarf_CU): Add lines and nlines members.
2143 (libdw_alloc): Define local variable _tail and use it.
2144 Add some function attributes.
2145 * libdw_alloc.c (__libdw_allocate): Don't initialize next member.
2146 * libdw_findcu.c (__libdw_findcu): Initialize lines and nlines members.
2147 * memory-access.h: Add unlikely for the endian conversion paths.
2148 * Makefile.am (AM_CFLAGS): Add -std parameter.
2149 (libdw_a_SOURCES): Add dwarf_getsrclines, dwarf_getsrc_die,
2150 dwarf_lineno, and dwarf_linesrc.
2151
21522003-08-11 Ulrich Drepper <drepper@redhat.com>
2153
2154 * Moved to CVS archive.