blob: 068d452123442a1035838b0c44e938fd5dd79e4c [file] [log] [blame]
Mark Wielaard38648042014-12-15 14:56:07 +010012014-12-15 Mark Wielaard <mjw@redhat.com>
2
3 * dwarf_getpubnames.c (get_offsets): Make sure whole unit fall inside
4 section data.
5 (dwarf_getpubnames): Make sure section data contains string zero
6 terminator.
7
Mark Wielaard1b5477d2014-12-16 10:53:22 +010082014-12-16 Mark Wielaard <mjw@redhat.com>
9
10 * memory-access.h (__libdw_get_sleb128): Unroll the first step to help
11 the compiler optimize for the common single-byte case.
12
Josh Stone54662f12014-12-15 12:18:25 -0800132014-12-15 Josh Stone <jistone@redhat.com>
14
15 * memory-access.h (__libdw_max_len_leb128): New.
16 (__libdw_get_uleb128): Use __libdw_max_len_leb128.
17 (__libdw_get_sleb128): Likewise.
18
Mark Wielaard7a053472014-12-14 21:48:23 +0100192014-12-14 Mark Wielaard <mjw@redhat.com>
20
21 * cfi.c (execute_cfi): Add program bounds checks.
22 * dwarf_child.c (__libdw_find_attr): Add attrp bounds checks.
23 * dwarf_formblock.c (dwarf_formblock): Call get_uleb128 with endp.
24 * dwarf_formref.c (__libdw_formref): Add datap bounds checks.
25 * dwarf_formsdata.c (dwarf_formsdata): Likewise.
26 * dwarf_formudata.c (dwarf_formudata): Likewise.
27 * dwarf_frame_register.c (dwarf_frame_register): Call get_uleb128
28 with end of data buf.
29 * dwarf_getabbrev.c (__libdw_getabbrev): Add abbrevp bounds checks.
30 * dwarf_getabbrevattr.c (dwarf_getabbrevattr): Assume get_uleb128
31 call gets enough data.
32 * dwarf_getattrs,c (dwarf_getattrs): Call get_uleb128 with endp.
33 * dwarf_getlocation.c (store_implicit_value): Call get_uleb128
34 with enough data.
35 (__libdw_intern_expression): Call get_uleb128/get_sleb128 with
36 end_data.
37 * dwarf_getmacros.c (get_table_for_offset): Add nforms bounds check.
38 * dwarf_getsrclines.c (read_srclines): Bounds check linep and call
39 get_uleb128 with lineendp.
40 * dwarf_hasattr.c (dwarf_hasattr): Bounds check attrp and call
41 get_uleb128 with endp.
42 * dwarf_next_cfi.c (dwarf_next_cfi): Bounds check bytes and call
43 get_uleb128/get_sleb128 with limit.
44 * encoded-value.h (read_encoded_value): Assume get_uleb128 and
45 get_sleb128 get called with enough data.
46 * fde.c (intern_fde): Call get_uleb128 with instructions_end.
47 * libdwP.h (__libdw_dieabbrev): Call get_uleb128 with die->cu->endp.
48 * libdw_form.c (__libdw_form_val_compute_len): Call get_uleb128 with
49 endp.
50 * memory-access.h (__libdw_get_uleb128): Take an extra endp.
51 Don't call get_uleb128_step if out of data.
52 (__libdw_get_sleb128): Likewise for get_sleb128_step.
53
Mark Wielaard92026652014-12-12 16:43:04 +0100542014-12-12 Mark Wielaard <mjw@redhat.com>
55
56 * libdwP.h (struct Dwarf): Add fake_loc_cu.
57 (cu_data): Removed.
58 (DIE_OFFSET_FROM_CU_OFFSET): Don't use cu_data, use cu_sec_idx.
59 (__libdw_form_val_compute_len): Drop dbg and endp arguments.
60 (__libdw_form_val_len): Likewise.
61 * libdw_form.c (__libdw_form_val_compute_len): Likewise.
62 * libdw_findcu.c (__libdw_intern_next_unit): Don't use cu_data, use
63 the already found data buffer directly.
64 * dwarf_begin_elf.c (valid_p): Setup fake_loc_cu.
65 * dwarf_end.c (dwarf_end): Free fake_loc_cu.
66 * dwarf_child.c (__libdw_find_attr): Call __libdw_form_val_len with
67 just cu.
68 * dwarf_getattrs.c (dwarf_getattrs): Likewise.
69 * dwarf_formblock.c (dwarf_formblock): Add bounds checking.
70 * dwarf_getlocation_attr.c (attr_form_cu): New function.
71 (dwarf_getlocation_attr): Use attr_form_cu to set result->cu.
72 (getlocation): Handle empty blocks immediately.
73 * dwarf_getlocation_implicit_pointer.c (empty_cu): New static var.
74 (__libdw_empty_loc_attr): Drop cu argument, use empty_cu.
75 (dwarf_getlocation_implicit_pointer): Call __libdw_empty_loc_attr with
76 one argument.
77 * dwarf_getmacros.c (read_macros): Also setup startp and endp for
78 fake_cu. Call __libdw_form_val_len with just fake_cu.
79 * dwarf_formref_die.c (dwarf_formref_die): Don't use cu_data, get
80 datap and size directly from cu startp and endp.
81
Mark Wielaardf73385e2014-12-12 00:22:31 +0100822014-12-11 Mark Wielaard <mjw@redhat.com>
83
84 * libdw_findcu.c (__libdw_intern_next_unit): Sanity check offset.
85
Mark Wielaard4a330f62014-12-14 00:09:29 +0100862014-12-13 Mark Wielaard <mjw@redhat.com>
87
88 * dwarf_getaranges.c (compare_aranges): Make sure Dwarf_Addr
89 difference doesn't wrap around before returning as int.
90
Josh Stone6e1c0d92014-12-11 16:22:48 -0800912014-12-11 Josh Stone <jistone@redhat.com>
92
93 * dwarf_getsrclines.c (struct linelist): Add sequence.
94 (compare_lines): Take linelists, and break ties by sequence.
95 (read_srclines): Use linelists for sorting.
96 (read_srclines::add_new_line): Set sequence.
97
Josh Stoneb849f812014-12-10 18:28:04 -0800982014-12-10 Josh Stone <jistone@redhat.com>
99
Josh Stone8d200b52014-12-10 18:41:43 -0800100 * libdwP.h (Dwarf_CU): Add startp and endp boundaries.
101 * libdw_findcu.c (__libdw_intern_next_unit): Set startp and endp.
102 * dwarf_child.c (dwarf_child): Use cu->endp.
103 * dwarf_cuoffset.c (dwarf_cuoffset): Use cu->startp.
104 * dwarf_dieoffset.c (dwarf_dieoffset): Use cu->startp.
105 * dwarf_siblingof.c (dwarf_siblingof): Use both.
106
1072014-12-10 Josh Stone <jistone@redhat.com>
108
Josh Stone64e44df2014-12-10 18:33:34 -0800109 * dwarf_hasattr.c (dwarf_hasattr): Just walk abbrev for presence.
110
1112014-12-10 Josh Stone <jistone@redhat.com>
112
Josh Stoneb849f812014-12-10 18:28:04 -0800113 * libdwP.h (__libdw_dieabbrev): New die->abbrev lookup function.
114 * dwarf_child.c (__libdw_find_attr, dwarf_child): Use it.
115 * dwarf_getattrs.c (dwarf_getattrs): Likewise.
116 * dwarf_haschildren.c (dwarf_haschildren): Likewise.
117 * dwarf_tag.c (dwarf_tag): Likewise.
118
Mark Wielaardcb73b5a2014-12-04 21:43:44 +01001192014-12-04 Mark Wielaard <mjw@redhat.com>
120
121 * libdwP.h (__libdw_form_val_compute_len): Add endp argument.
122 (__libdw_form_val_len): Likewise and check len doesn't overflow.
123 * libdw_form.c (__libdw_form_val_compute_len): Likewise.
124 * dwarf_child.c (__libdw_find_attr): Call __libdw_form_val_len
125 with endp.
126 * dwarf_getattrs.c (dwarf_getattrs): Likewise.
127 * dwarf_getmacros.c (read_macros): Likewise and check for errors.
128
Petr Machataedb079a2014-12-02 21:22:14 +01001292014-12-02 Petr Machata <pmachata@redhat.com>
130
131 * dwarf_getmacros.c (token_from_offset, offset_from_token): New
132 helper functions.
133 (do_dwarf_getmacros_die): Merge into dwarf_getmacros.
134 * libdw.h (DWARF_GETMACROS_START): New macro.
135
Mark Wielaard12ab7002014-11-27 23:41:57 +01001362014-11-27 Mark Wielaard <mjw@redhat.com>
137
Mark Wielaard805ec832014-11-27 23:53:30 +0100138 * Makefile.am (libdw.so): Use textrel_check.
139
1402014-11-27 Mark Wielaard <mjw@redhat.com>
141
Mark Wielaard12ab7002014-11-27 23:41:57 +0100142 * dwarf_getcfi_elf.c (getcfi_gnu_eh_frame): Initialize
143 search_table_entries and search_table_encoding.
144
Mark Wielaard020fc022014-11-24 21:54:42 +01001452014-11-24 Mark Wielaard <mjw@redhat.com>
146
147 * dwarf_getsrclines.c (read_srclines): Check line_range is not zero
148 before usage.
149
Mark Wielaard04b61f82014-11-23 23:13:55 +01001502014-11-23 Mark Wielaard <mjw@redhat.com>
151
Mark Wielaard59480ba2014-11-23 23:21:05 +0100152 * dwarf_attr.c (dwarf_attr): Check __libdw_find_attr return value.
153 * dwarf_hasattr.c (dwarf_hasattr): Likewise.
154 * dwarf_siblingof.c (dwarf_siblingof): Likewise.
155
1562014-11-23 Mark Wielaard <mjw@redhat.com>
157
Mark Wielaard04b61f82014-11-23 23:13:55 +0100158 * dwarf_getabbrev.c (__libdw_getabbrev): Don't assert on bad DWARF.
159 Set libdw errno and return NULL.
160
Mark Wielaard9f8c08e2014-11-24 22:17:51 +01001612014-11-24 Mark Wielaard <mjw@redhat.com>
162
163 * dwarf.h (DW_LANG_C_plus_plus_11): Added.
164 (DW_LANG_C11): Likewise.
165 (DW_LANG_C_plus_plus_14): Likewise.
166 * dwarf_aggregate_size.c (array_size): Handle DW_LANG_C11,
167 DW_LANG_C_plus_plus_11, DW_LANG_C_plus_plus_14 and DW_LANG_Go
168 lower bound.
169 * dwarf_getfuncs.c (dwarf_getfuncs): Set c_cu to true for
170 DW_LANG_C11.
171
Mark Wielaard03c033f2014-11-26 17:51:28 +01001722014-11-26 Mark Wielaard <mjw@redhat.com>
173
174 * dwarf.h (DW_AT_noreturn): Added.
175
Mark Wielaard09086232014-11-11 14:10:04 +01001762014-11-11 Mark Wielaard <mjw@redhat.com>
177
178 * dwarf_getsrclines.c (read_srclines): Do address_size comparison
179 explicitly as uint8_t.
180 (__libdw_getsrclines): Add internal_function to declaration.
181
Petr Machatafb90bf32014-10-17 02:47:03 +02001822014-09-10 Petr Machata <pmachata@redhat.com>
183
184 * dwarf_macro_getparamcnt.c: New file.
185 * dwarf_macro_param.c: New file.
186 * dwarf_macro_getsrcfiles.c: New file.
187 * Makefile.am (libdw_a_SOURCES): Add the new files.
188 * libdwP.h (struct files_lines_s): New structure.
189 (DWARF_E_INVALID_OPCODE): New enumerator.
190 (struct Dwarf): New fields macro_ops, files_lines.
191 (Dwarf_Macro_Op_Proto, Dwarf_Macro_Op_Table): New structures for
192 keeping macro opcode prototypes in.
193 (Dwarf_Macro_s): Redefine from scratch.
194 (__libdw_getsrclines, __libdw_getcompdir, libdw_macro_nforms): New
195 internal interfaces.
196 * dwarf_error.c (errmsgs): Add a message for
197 DWARF_E_INVALID_OPCODE.
198 * dwarf_end.c (dwarf_end): Destroy struct Dwarf.macro_ops and
199 files_lines.
200 * libdw.h (dwarf_getmacros_off, dwarf_macro_getparamcnt)
201 (dwarf_macro_getsrcfiles, dwarf_macro_param): New public
202 interfaces.
203 * dwarf_getmacros.c (dwarf_getmacros_off): New function,
204 (get_offset_from, macro_op_compare, build_table)
205 (init_macinfo_table, get_macinfo_table, get_table_for_offset)
206 (cache_op_table, read_macros, gnu_macros_getmacros_off)
207 (macro_info_getmacros_off, do_dwarf_getmacros_die): New helper
208 functions.
209 (dwarf_getmacros): Adjust to dispatch to the new interfaces.
210 * dwarf_getsrclines.c (read_srclines): New function with guts
211 taken from dwarf_getsrclines.
212 (__libdw_getsrclines): Likewise.
213 (__libdw_getcompdir, files_lines_compare): New functions.
214 (dwarf_getsrclines): Make it dispatch to the new interfaces.
215 * dwarf_macro_param1.c (dwarf_macro_param1): Adjust to dispatch to
216 the new interfaces.
217 * dwarf_macro_param2.c (dwarf_macro_param2): Likewise.
218 * libdw.map (ELFUTILS_0.161): New. Add dwarf_getmacros_off,
219 dwarf_macro_getsrcfiles, dwarf_macro_getparamcnt, dwarf_macro_param.
220
Mark Wielaard3a36e8a2014-10-06 22:00:16 +02002212014-10-06 Mark Wielaard <mjw@redhat.com>
222
223 * Makefile.am (libdw_a_SOURCES): Add dwarf_peel_type.c.
224 * dwarf_aggregate_size.c (get_type): Use dwarf_peel_type.
225 (aggregate_size): Likewise. Add old and new version.
226 * dwarf_peel_type.c: New file.
227 * libdw.h (dwarf_peel_type): New function declaration.
228 * libdwP.h (dwarf_peel_type): New internal declaration.
229 * libdw.map (ELFUTILS_0.161): New section.
230
Petr Machata564cfbe2014-10-15 19:28:08 +02002312014-10-15 Petr Machata <pmachata@redhat.com>
232
233 * libdwP.h (struct Dwarf_Files_s.cu): Drop field.
234 * dwarf_getsrclines.c (dwarf_getsrclines): Don't set it.
235
Mark Wielaard2e83c642014-10-05 17:12:41 +02002362014-10-05 Mark Wielaard <mjw@redhat.com>
237
238 * dwarf.h: Add DW_AT_GNU_deleted.
239
Mark Wielaardb50014f2014-10-02 14:00:47 +02002402014-10-02 Mark Wielaard <mjw@redhat.com>
241
242 * dwarf_aggregate_size.c (aggregate_size): Return CU address_size
243 for sizeless DW_TAG_pointer_type, DW_TAG_reference_type or
244 DW_TAG_rvalue_reference_type.
245
Petr Machata1498f542014-09-12 19:03:33 +02002462014-09-12 Petr Machata <pmachata@redhat.com>
247
248 * memory-access.h (read_ubyte_unaligned_inc): Allow only 4- and
249 8-byte quantities. Consequently, rename to...
250 (read_addr_unaligned_inc): ... this.
251 (read_sbyte_unaligned_inc, read_ubyte_unaligned): Drop.
252 (read_sbyte_unaligned): Drop.
253
Petr Machata476feb12014-09-10 22:26:28 +02002542014-09-10 Petr Machata <pmachata@redhat.com>
255
256 * dwarf_getlocation.c (attr_ok): Also accept
257 DW_AT_GNU_call_site_value, DW_AT_GNU_call_site_data_value,
258 DW_AT_GNU_call_site_target, DW_AT_GNU_call_site_target_clobbered.
259
Mark Wielaard209f1492014-08-15 13:08:24 +02002602014-08-15 Mark Wielaard <mjw@redhat.com>
261
Mark Wielaardf18f2332014-08-15 16:03:21 +0200262 * dwarf_cu_die.c: New file.
263 * Makefile.am (libdw_a_SOURCES): Add dwarf_cu_die.c.
264 * libdw.h (dwarf_cu_die): New function declaration.
265 * libdw.map (ELFUTILS_0.160): Add dwarf_cu_die.
266
2672014-08-15 Mark Wielaard <mjw@redhat.com>
268
Mark Wielaard209f1492014-08-15 13:08:24 +0200269 * dwarf_cu_getdwarf.c: New file.
270 * Makefile.am (libdw_a_SOURCES): Add dwarf_cu_getdwarf.c.
271 * libdw.h (Dwarf_CU): New typedef.
272 (dwarf_cu_getdwarf): New function declaration.
273 * libdw.map (ELFUTILS_0.160): New. Add dwarf_cu_getdwarf.
274
Mark Wielaardaf1e6ed2014-06-18 10:57:58 +02002752014-06-18 Mark Wielaard <mjw@redhat.com>
276
277 * dwarf.h: Remove DW_TAG_mutable_type.
278
Mark Wielaardbb096d02014-05-03 00:23:06 +02002792014-05-02 Mark Wielaard <mjw@redhat.com>
280
281 * libdwP.h (__check_build_id): Removed now unused.
282
Mark Wielaarddf85bf92014-05-01 14:48:27 +02002832014-05-01 Mark Wielaard <mjw@redhat.com>
284
285 * libdwP.h (struct Dwarf): Remove free_alt.
286 * dwarf_end.c (dwarf_end): Don't check free_alt, don't end alt_dwarf.
287 * dwarf_setalt.c (dwarf_setalt): Don't check or set free_alt.
288
Mark Wielaardd81d32d2014-04-30 23:00:40 +02002892014-04-30 Mark Wielaard <mjw@redhat.com>
290
291 * libdw.map (ELFUTILS_0.159): Add dwelf_elf_gnu_build_id.
292
Florian Weimer920f03d2014-04-15 17:11:17 +02002932014-04-15 Florian Weimer <fweimer@redhat.com>
294
295 * dwarf_begin_elf.c (__check_build_id, try_debugaltlink)
296 (open_debugaltlink): Move to libdwfl.
297 (check_section): Do not locate alternate debuginfo.
298
Florian Weimer4813dbb2014-04-24 14:06:43 +02002992014-04-24 Florian Weimer <fweimer@redhat.com>
300
301 * libdw.map (ELFUTILS_0.159): Export dwelf_dwarf_gnu_debugaltlink.
302
Florian Weimer35e2a762014-04-15 14:31:55 +02003032014-04-22 Florian Weimer <fweimer@redhat.com>
304
305 * dwarf_getalt.c, dwarf_setalt.c: New files.
306 * Makefile.am (libdw_a_SOURCES): Add them.
307 * libdw.h (dwarf_getalt, dwarf_setalt): Add function declarations.
308 * libdwP.h (dwarf_getalt, dwarf_setalt): Add internal function
309 declarations.
310 * libdw.map (ELFUTILS_0.159): Export the two new functions.
311
Florian Weimerefa72a02014-04-15 14:04:19 +02003122014-04-15 Florian Weimer <fweimer@redhat.com>
313
314 * libdwP.h (enum IDX_gnu_debugaltlink): New.
315 * dwarf_begin_elf.c (dwarf_scnnames): Increase string size and add
316 .gnu_debugaltlink.
317 (check_section): Obtain .gnu_debugaltlink section from the
318 setiondata array.
319
Mark Wielaard93802972014-04-11 23:52:47 +02003202014-04-11 Mark Wielaard <mjw@redhat.com>
321
322 * libdw.map (ELFUTILS_0.159): New. Add dwelf_elf_gnu_debuglink.
323 * Makefile.am (libdw.so): Depend on libdwelf_pic.a.
324 (libdwelf_objects): New variable.
325 (libdw_a_LIBADD): Add libdwelf objects.
326
Mark Wielaardeb4da482014-04-22 16:43:11 +02003272014-04-22 Mark Wielaard <mjw@redhat.com>
328
329 * memory-access.h (get_sleb128_step): Remove undefined behavior
330 of left shifting a signed value. Replace it with a multiplication.
331
Mark Wielaard32324792014-04-13 17:39:57 +02003322014-04-13 Mark Wielaard <mjw@redhat.com>
333
334 * Makefile.am: Remove !MUDFLAP conditions.
335
Mark Wielaard7f1eec32014-04-09 11:33:23 +02003362014-04-09 Mark Wielaard <mjw@redhat.com>
337
338 * dwarf_begin_elf.c (check_section): Check for unsigned overflow
339 before calling malloc to uncompress data.
340
Jan Kratochvildff2a992014-03-04 00:04:27 +01003412014-03-03 Jan Kratochvil <jan.kratochvil@redhat.com>
342
343 Fix abort() on missing section headers.
344 * dwarf_begin_elf.c (check_section): Replace abort call by goto err.
345 New label err to return NULL.
346
Josh Stone50d5b2c2014-02-05 11:26:27 -08003472014-02-05 Josh Stone <jistone@redhat.com>
348
349 * dwarf_decl_file.c (dwarf_decl_file): Read the idx as unsigned.
350 * dwarf_decl_line.c (__libdw_attr_intval): Read the line/column as
351 unsigned. Change the range assert to DWARF_E_INVALID_DWARF.
352
Mark Wielaard19108012013-12-30 22:00:57 +01003532013-12-30 Mark Wielaard <mjw@redhat.com>
354
355 * libdw.map (ELFUTILS_0.158): Add dwfl_core_file_attach and
356 dwfl_linux_proc_attach.
357
Mark Wielaarde962ec32013-12-20 10:09:12 +01003582013-12-20 Mark Wielaard <mjw@redhat.com>
359
360 * libdw.map (ELFUTILS_0.158): Add dwfl_getthread_frames.
361
Mark Wielaard159ac522013-12-18 11:05:54 +01003622013-12-18 Mark Wielaard <mjw@redhat.com>
363
364 * libdw.map (ELFUTILS_0.158): Remove dwfl_module_addrsym_elf and
365 dwfl_module_getsym_elf. Add dwfl_module_addrinfo and
366 dwfl_module_getsym_info.
367
Mark Wielaard14c2d9e2013-12-16 13:28:59 +01003682013-12-16 Mark Wielaard <mjw@redhat.com>
369
370 * libdw.map (ELFUTILS_0.158): Add dwfl_module_getsymtab_first_global.
371
Josh Stone4e2787c2013-12-10 14:19:09 -08003722013-12-10 Josh Stone <jistone@redhat.com>
373
374 * memory-access.h (get_uleb128_rest_return): Removed.
375 (get_sleb128_rest_return): Removed.
376 (get_uleb128_step): Make this a self-contained block.
377 (get_sleb128_step): Ditto, and use a bitfield to extend signs.
378 (get_uleb128): Make this wholly implemented by __libdw_get_uleb128.
379 (get_sleb128): Make this wholly implemented by __libdw_get_sleb128.
380 (__libdw_get_uleb128): Simplify and inline for all callers.
381 (__libdw_get_sleb128): Ditto.
382 * dwarf_getlocation.c (store_implicit_value): Void the unused uleb128.
383 * memory-access.c: Delete file.
384 * Makefile.am (libdw_a_SOURCES): Remove it.
385 (DEFS): Remove the now unused -DIS_LIBDW.
386
Josh Stonec0d2a0b2013-12-09 13:52:10 -08003872013-12-09 Josh Stone <jistone@redhat.com>
388
389 * libdw_form.c (__libdw_form_val_compute_len): Renamed function from
390 __libdw_form_val_len, now handling only non-constant form lengths.
391 * libdwP.h (__libdw_form_val_len): New inlined function.
392
Mark Wielaard3951f2e2013-12-09 16:33:26 +01003932013-12-09 Mark Wielaard <mjw@redhat.com>
394
395 * dwarf_getlocation.c (__libdw_intern_expression): Handle empty
396 location expressions.
397 * dwarf_getlocation_attr.c (dwarf_getlocation_attr): When no
398 location found, return empty location expression.
399 * dwarf_getlocation_implicit_pointer.c
400 (dwarf_getlocation_implicit_pointer): Likewise.
401 (__libdw_empty_loc_attr): New internal function.
402 * libdwP.h (__libdw_empty_loc_attr): Define.
403
Mark Wielaard819c3492013-11-27 16:45:44 +01004042013-11-27 Mark Wielaard <mjw@redhat.com>
405
406 * libdw.map (ELFUTILS_0.158): Add dwfl_module_addrsym_elf and
407 dwfl_module_getsym_elf.
408
Mark Wielaard16bc4562013-11-26 15:13:22 +01004092013-11-26 Mark Wielaard <mjw@redhat.com>
410
411 * libdw.map (ELFUTILS_0.156): Move dwfl_attach_state, dwfl_pid,
412 dwfl_thread_dwfl, dwfl_thread_tid, dwfl_frame_thread,
413 dwfl_thread_state_registers, dwfl_thread_state_register_pc,
414 dwfl_getthreads, dwfl_thread_getframes and dwfl_frame_pc to ...
415 (ELFUTILS_0.158): ... here.
416
Mark Wielaard03d76f42013-11-09 16:45:22 +01004172013-11-09 Mark Wielaard <mjw@redhat.com>
418
419 * dwarf_getaranges.c (dwarf_getaranges): Read segment_size and
420 check that it is zero.
421
Jan Kratochvil0b867462013-05-30 14:37:38 +02004222013-11-07 Jan Kratochvil <jan.kratochvil@redhat.com>
423
424 * cfi.h (struct Dwarf_Frame_s): Make the comment more specific.
425 * libdw.map (ELFUTILS_0.156): Add dwfl_attach_state, dwfl_pid,
426 dwfl_thread_dwfl, dwfl_thread_tid, dwfl_frame_thread,
427 dwfl_thread_state_registers, dwfl_thread_state_register_pc,
428 dwfl_getthreads, dwfl_thread_getframes and dwfl_frame_pc.
429
Michael Forneya45c8042013-11-01 00:51:04 -07004302013-11-01 Michael Forney <mforney@mforney.org>
431
Michael Forneycdc09432013-11-01 00:51:05 -0700432 * Makefile.am (libdwfl_objects): New definition.
433 (libdw_a_LIBADD): Use libdwfl_objects.
434
4352013-11-01 Michael Forney <mforney@mforney.org>
436
Michael Forneya45c8042013-11-01 00:51:04 -0700437 * Makefile.am: Use READELF.
438
Jan Kratochvil3cf491e2013-10-30 10:48:20 +01004392013-10-30 Jan Kratochvil <jan.kratochvil@redhat.com>
440
441 * libdw.map (ELFUTILS_0.158): New.
442
Mark Wielaarde6a9bb82013-10-10 11:40:12 +02004432013-10-10 Mark Wielaard <mjw@redhat.com>
444
445 * dwarf_getfuncs.c (struct visitor_info): Rename start_offset to
446 start_addr and rename last_offset to last_addr. Now both void *.
447 (tree_visitor): Use start_add and die_addr instead of start_offset
448 and die_offset.
449 (dwarf_getfuncs): Use last_addr instead of last_offset.
450
Mark Wielaard3dec3e12013-10-06 17:04:07 +02004512013-10-06 Mark Wielaard <mjw@redhat.com>
452
453 * cfi.c (execute_cfi): Make sure DW_CFA_expression and
454 DW_CFA_val_expression are not used with abi_cfi.
455
Josh Stone5dbbc5e2013-10-03 12:38:25 -07004562013-10-03 Josh Stone <jistone@redhat.com>
457
458 * dwarf_formref_die.c (dwarf_formref_die): Don't hash the sig8 here.
459 * libdw_findcu.c (__libdw_intern_next_unit): Since this never revisits
460 a unit, make sure to always hash the sig8 here, so none are missed.
461
Mark Wielaard74f9b732013-09-30 00:39:07 +02004622013-09-29 Mark Wielaard <mjw@redhat.com>
463
464 * dwarf_getlocation.c (store_implicit_value): Cast op->number2 to
465 uintptr_t before casting to char *.
466 (__libdw_intern_expression): Cast data to uintptr_t before casting
467 to Dwarf_Word.
468 * dwarf_getlocation_attr.c (dwarf_getlocation_attr): Cast
469 op->number2 to uintptr_t before casting to char *.
470
Josh Stonef06c8582013-09-24 15:52:05 -07004712013-09-24 Josh Stone <jistone@redhat.com>
472
473 * libdw_visit_scopes.c (classify_die): Removed.
474 (may_have_scopes): New function to replace classify_die. There's no
475 need for full classification; just find tags that may contain scopes.
476 (__libdw_visit_scopes): Use a direct tag comparison for imported
477 units, and use may_have_scopes to test if recursion is needed.
478
Mark Wielaard1b734df2013-09-20 09:50:42 -04004792013-09-20 Mark Wielaard <mjw@redhat.com>
480
481 * dwarf_getfuncs.c (visitor_info): New struct.
482 (tree_visitor): New function.
483 (dwarf_getfuncs): Use __libdw_visit_scopes with tree_visitor.
484 * libdw.h (dwarf_getfuncs): Expand function documentation.
485
Mark Wielaard18b2c672013-09-12 15:49:47 +02004862013-09-12 Mark Wielaard <mjw@redhat.com>
487
488 * fde.c (intern_fde): Free fde and set libdw errno when start
489 or end could not be read.
490
Mark Wielaardb2535b62013-08-30 23:55:12 +02004912013-08-24 Mark Wielaard <mjw@redhat.com>
492
493 * dwarf_getlocation.c (store_implicit_value): Don't take data
494 as argument, get block data from op number2. Return false when
495 block data length and op number don't match up.
496 (__libdw_intern_expression): Store start of block for
497 DW_OP_implicit_value and DW_OP_GNU_entry_value instead of
498 relative data offset. Also store block start (including length)
499 for DW_OP_GNU_const_type. Don't pass data to store_implicit_value.
500 * dwarf_getlocation_attr.c: New file.
501 * dwarf_getlocation_die.c: Likewise.
502 * libdw.h (dwarf_getlocation_die): New function definition.
503 (dwarf_getlocation_attr): Likewise.
504 * libdwP.h: Declare internal dwarf_getlocation_die.
505 * libdw.map (ELFUTILS_0.157): Add dwarf_getlocation_die and
506 dwarf_getlocation_attr.
507 * Makefile.am (libdw_a_SOURCES): Add dwarf_getlocation_die.c and
508 dwarf_getlocation_attr.c.
509
Mark Wielaard66eaae92013-08-23 16:12:37 +02005102013-08-23 Mark Wielaard <mjw@redhat.com>
511
512 * dwarf_getlocation.c (attr_ok): Also accept DW_AT_segment.
513 (attr_base_address): New function.
514 (initial_offset_base): New function.
515 (getlocations_addr): New function. Taken from...
516 (dwarf_getlocation_addr): here. Use new initial_offset_base and
517 getlocations_addr.
518 (dwarf_getlocations): New function.
519 * libdw.h (dwarf_getlocations): New function definition.
520 * libdw.map (ELFUTILS_0.157): New.
521
Mark Wielaard5704c8c2013-07-02 11:22:35 +02005222013-07-02 Mark Wielaard <mjw@redhat.com>
523
Mark Wielaard4aacfc12013-07-02 16:36:16 +0200524 * dwarf_getsrclines.c (dwarf_getsrclines): Add new stack allocation
525 limit MAX_STACK_ALLOC. After MAX_STACK_ALLOC lines use malloc in
526 NEW_LINE macro. Free malloced line records if any at the end.
527
5282013-07-02 Mark Wielaard <mjw@redhat.com>
529
Mark Wielaard5704c8c2013-07-02 11:22:35 +0200530 * dwarf_getcfi_elf.c (getcfi_shdr): Check sh_type == SHT_PROGBITS.
531
Mark Wielaard79277072013-06-26 11:42:52 -04005322013-06-26 Mark Wielaard <mjw@redhat.com>
533
534 * libdw_visit_scopes.c (__libdw_visit_scopes): Don't reject root
535 DIEs without children. Return an error whenever dwarf_child or
536 dwarf_siblingof return an error. Don't call recurse and increase
537 the depth for an imported unit. Walk the children of an imported
538 unit as if they are logical children of the parent root DIE.
539
Mark Wielaard9affad32013-05-03 11:28:49 +02005402013-05-03 Mark Wielaard <mjw@redhat.com>
541
542 * dwarf_getsrclines.c (dwarf_getsrclines): Only set end_sequence
543 when nlinelist > 0.
544
Jan Kratochvil904aec22013-04-30 14:27:16 +02005452013-04-28 Jan Kratochvil <jan.kratochvil@redhat.com>
546
547 * libdw.map (ELFUTILS_0.156): New.
548
Mark Wielaardcdaaf212013-04-25 16:50:11 -04005492013-04-24 Mark Wielaard <mjw@redhat.com>
550
551 * Makefile.am: Use AM_CPPFLAGS instead of INCLUDES.
552
Mark Wielaardd4744a72013-04-10 15:52:57 +02005532013-04-10 Mark Wielaard <mjw@redhat.com>
554
555 * dwarf_formref_die.c (dwarf_formref_die): Reference size is only
556 equal to address size when we have a DW_FORM_ref_addr for DWARF
557 version 2.
558
Mark Wielaard60ef9ab2013-03-25 17:07:21 +01005592013-03-25 Mark Wielaard <mjw@redhat.com>
560
561 * dwarf_getsrclines.c (dwarf_getsrclines): Mark highest address as
562 end_sequence.
563
Mark Wielaardf1b06b52013-03-12 12:02:51 +01005642013-03-12 Mark Wielaard <mjw@redhat.com>
565
566 * dwarf_getsrcfiles.c (dwarf_getsrcfiles): Allow DW_TAG_partial_unit.
567 * dwarf_getsrclines.c (dwarf_getsrclines): Likewise.
568
Mark Wielaard443304e2013-02-15 22:45:22 +01005692013-02-15 Mark Wielaard <mjw@redhat.com>
570
571 * dwarf_formstring.c (dwarf_formstring): Check dbg_ret->sectiondata,
572 not dbg->sectiondata.
573
Roland McGrath3999ce12013-01-07 14:53:37 -08005742013-01-07 Roland McGrath <roland@hack.frob.com>
575
576 * memory-access.h
577 [ALLOW_UNALIGNED] (read_8ubyte_unaligned_noncvt): New macro.
578 [!ALLOW_UNALIGNED] (read_8ubyte_unaligned_noncvt): New inline function.
579
Mark Wielaard59254422012-12-18 14:14:22 +01005802012-12-18 Mark Wielaard <mjw@redhat.com>
581
582 * dwarf_begin_elf.c (valid_p): Call Dwarf_Sig8_Hash_free if invalid.
583 (check_section): Likewise on error.
584 (scngrp_read): Likewise.
585 (dwarf_begin_elf): Likewise.
586
Petr Machatab5c0b032012-10-09 02:11:29 +02005872012-10-09 Petr Machata <pmachata@redhat.com>
588
589 * dwarf_getlocation.c (__libdw_intern_expression): Handle
590 DW_OP_GNU_parameter_ref, DW_OP_GNU_convert, DW_OP_GNU_reinterpret,
591 DW_OP_GNU_regval_type, DW_OP_GNU_entry_value,
592 DW_OP_GNU_deref_type, DW_OP_GNU_const_type.
593
Jan Kratochvil6c45f4a2012-10-08 23:04:54 +02005942012-10-08 Jan Kratochvil <jan.kratochvil@redhat.com>
595
Jan Kratochvil1d67c0c2012-10-08 23:51:31 +0200596 * cfi.c: New include system.h.
597 (execute_cfi) (enough_registers): Clear new memory after realloc.
598
5992012-10-08 Jan Kratochvil <jan.kratochvil@redhat.com>
600
Jan Kratochvil07f35072012-10-08 23:34:35 +0200601 * fde.c (__libdw_find_fde): Change <fde != NULL> to likely. Return
602 DWARF_E_NO_MATCH if .eh_frame_hdr points to FDE which is too short for
603 searched PC.
604
6052012-10-08 Jan Kratochvil <jan.kratochvil@redhat.com>
606
Jan Kratochvil96a9fc62012-10-08 23:08:01 +0200607 * dwarf_getlocation.c (__libdw_intern_expression) <cfap>: Make new
608 loclist element DW_OP_call_frame_cfa before decoding the opcodes.
609 Remove the later DW_OP_call_frame_cfa push to RESULT.
610
6112012-10-08 Jan Kratochvil <jan.kratochvil@redhat.com>
612
Jan Kratochvil6c45f4a2012-10-08 23:04:54 +0200613 Code cleanup.
614 * fde.c (binary_search_fde): Remove always true <address >= start>
615 conditional. Move L initialization upwards.
616
Mark Wielaardf5519fc2012-08-24 13:54:52 +02006172012-08-24 Mark Wielaard <mjw@redhat.com>
618
619 * dwarf_begin_elf.c (check_section): Only probe for dwz multi files
620 when ENABLE_DWZ is defined.
621 * libdwP.h (__check_build_id): Only declare when ENABLE_DWZ is
622 defined.
623
Mark Wielaardf31c4412012-08-17 00:35:03 +02006242012-08-16 Mark Wielaard <mjw@redhat.com>
625
626 * Makefile.am (EXTRA_DIST): Add known-dwarf.h.
627 * dwarf.h (DW_LANG_Go): Update comment.
628 (DW_LANG_Mips_Assembler): Likewise.
629
Mark Wielaard775375e2012-06-22 12:02:45 +02006302012-06-27 Mark Wielaard <mjw@redhat.com>
631
632 * dwarf.h: Add DW_FORM_GNU_ref_alt and DW_FORM_GNU_strp_alt.
633 * dwarf_begin.c (dwarf_begin): Add INTDEF.
634 * dwarf_begin_elf.c (__check_build_id): New internal_function.
635 (try_debugaltlink): New function.
636 (open_debugaltlink): Likewise.
637 (check_section): Try open_debugaltlink for .gnu_debugaltlink.
638 * dwarf_end.c (dwarf_end): Free the alternative Dwarf descriptor if
639 necessary.
640 * dwarf_error.c (errmsgs): Add DWARF_E_NO_ALT_DEBUGLINK.
641 * dwarf_formref.c (__libdw_formref): Using DW_FORM_GNU_ref_alt
642 is an error here.
643 * dwarf_formref_die.c (dwarf_formref_die): Handle DW_FORM_GNU_ref_alt.
644 * dwarf_formstring.c (dwarf_formstring): Handle DW_FORM_GNU_strp_alt.
645 * dwarf_formudata.c (__libdw_formptr): Adjust __libdw_read_offset
646 calls.
647 * dwarf_getpubnames.c (get_offsets): Adjust __libdw_read_offset call.
648 * libdwP.h: Add DWARF_E_NO_ALT_DEBUGLINK.
649 (struct Dwarf): Add alt_dwarf and free_alt fields.
650 (__libdw_read_offset): Add dbg_ret argument, use to check with
651 __libdw_offset_in_section.
652 (__check_build_id): New function declaration.
653 (dwarf_begin): Define as INTDECL.
654 * libdw_form.c (__libdw_form_val_len): Handle DW_FORM_GNU_ref_alt
655 and DW_FORM_GNU_strp_alt.
656
Mark Wielaard515fba92012-07-20 00:09:56 +02006572012-07-19 Mark Wielaard <mjw@redhat.com>
658
659 * dwarf.h: Add DW_OP_GNU_parameter_ref.
660
Mark Wielaarddf9ec3f2012-07-24 20:00:14 +02006612012-07-24 Mark Wielaard <mjw@redhat.com>
662
Mark Wielaardc4010b82012-07-24 13:20:41 +0200663 * dwarf.h: Correct spelling of DW_LANG_ObjC.
664 * dwarf_aggregate_size.c (array_size): Use correct spelling of
665 DW_LANG_ObjC.
666
6672012-07-24 Mark Wielaard <mjw@redhat.com>
668
Mark Wielaarddf9ec3f2012-07-24 20:00:14 +0200669 * dwarf.h: Add DW_ATE_UTF.
670
Mark Wielaardef5688e2012-06-27 10:15:27 +02006712012-06-27 Mark Wielaard <mjw@redhat.com>
672
673 * dwarf.h: Add DW_MACRO_GNU .debug_macro type encodings.
674
Mark Wielaarda0172d72012-06-25 17:18:53 +02006752012-06-26 Mark Wielaard <mjw@redhat.com>
676
677 * libdwP.h: Add IDX_debug_macro.
678 * dwarf.h: Add DW_AT_GNU_macros.
679 * dwarf_begin_elf.c (dwarf_scnnames): Add .debug_macro.
680 * dwarf_formudata.c (dwarf_formudata): Recognize DW_AT_GNU_macros.
681
Mark Wielaard54797252012-04-27 13:00:50 +02006822012-04-27 Mark Wielaard <mjw@redhat.com>
683
684 * libdw/dwarf_highpc.c (dwarf_highpc): Handle DW_AT_high_pc being
685 a constant offset from DW_AT_low_pc.
686
Tom Tromey581c3f62012-03-21 08:54:32 -06006872012-03-19 Tom Tromey <tromey@redhat.com>
688
689 * libdw_findcu.c (findcu_cb): Move earlier.
690 (__libdw_intern_next_unit): Add new CU to search tree here...
691 (__libdw_findcu): ... not here.
692
Mark Wielaardcb643d62012-01-31 19:22:03 +01006932012-01-31 Mark Wielaard <mjw@redhat.com>
694
695 * dwarf_formudata.c (dwarf_formudata): Handle DW_FORM_sec_offset.
696
Mark Wielaard387998b2011-10-31 15:01:50 +01006972011-11-31 Mark Wielaard <mjw@redhat.com>
698
699 * Makefile.am (known-dwarf.h): Run gawk on config/known-dwarf.awk.
700
Mark Wielaard0b72b652011-07-14 12:59:26 +02007012011-07-14 Mark Wielaard <mjw@redhat.com>
702
703 * libdw.h (dwarf_offdie): Fix documentation to mention .debug_info.
704
Jakub Jelinek03124242011-05-17 17:00:14 +02007052011-05-16 Jakub Jelinek <jakub@redhat.com>
706
707 * dwarf.h (DW_OP_GNU_const_type, DW_OP_GNU_regval_type,
708 DW_OP_GNU_deref_type, DW_OP_GNU_convert, DW_OP_GNU_reinterpret):
709 New.
710
Mark Wielaardf4c39c72011-04-26 17:15:28 +02007112011-04-26 Mark Wielaard <mjw@redhat.com>
712
713 * dwarf_child (dwarf_child): Sanity check end of section against
714 cu_data () of die->cu.
715
Mark Wielaarde3368c52011-03-22 23:03:31 +01007162011-03-22 Mark Wielaard <mjw@redhat.com>
717
718 * dwarf.h: Add DW_TAG_GNU_call_site,
719 DW_TAG_GNU_call_site_parameter,
720 DW_AT_GNU_call_site_value,
721 DW_AT_GNU_call_site_data_value,
722 DW_AT_GNU_call_site_target,
723 DW_AT_GNU_call_site_target_clobbered,
724 DW_AT_GNU_tail_call,
725 DW_AT_GNU_all_tail_call_sites,
726 DW_AT_GNU_all_call_sites,
727 DW_AT_GNU_all_source_call_sites,
728 and DW_OP_GNU_entry_value.
729
Petr Machata02c56192011-03-10 01:50:32 +01007302011-03-10 Petr Machata <pmachata@redhat.com>
731
732 * libdw/dwarf_tag.c (__libdw_findabbrev): Reject requests for
733 abbreviation with code 0.
734
Petr Machata35870872011-03-09 10:01:29 -08007352011-03-09 Petr Machata <pmachata@redhat.com>
736
737 * libdw/dwarf_child.c (dwarf_child): Check for section overrun.
738
Roland McGrath725aad52011-02-23 19:52:46 -08007392011-02-23 Roland McGrath <roland@redhat.com>
740
741 * libdwP.h (struct Dwarf) [USE_ZLIB]: New member sectiondata_gzip_mask.
742 Declare __libdw_free_zdata.
743 * dwarf_end.c [USE_ZLIB] (__libdw_free_zdata): New function.
744 (dwarf_end): Call it.
745
746 * dwarf_begin_elf.c (valid_p): Likewise.
747 (check_section, scngrp_read): Likewise.
748 (check_section) [USE_ZLIB]: Grok .z* flavors of sections.
749
Roland McGrath8c0a3822010-10-13 11:21:17 -07007502010-10-13 Roland McGrath <roland@redhat.com>
751
752 * dwarf.h: Add DW_LANG_Go.
753
Roland McGrath5f95e2b2010-10-05 00:56:30 -07007542010-10-05 Roland McGrath <roland@redhat.com>
755
756 * dwarf_getaranges.c: Use malloc rather than alloca,
757 since the total number of elements can be quite huge.
758
Roland McGrath932585d2010-05-08 04:01:14 -07007592010-07-26 Roland McGrath <roland@redhat.com>
760
761 * dwarf_getlocation_implicit_pointer.c: New file.
762 * Makefile.am (libdw_a_SOURCES): Add it.
763 * libdw.map (ELFUTILS_0.149): New set.
764 Add dwarf_getlocation_implicit_pointer.
765 * libdw.h: Declare it.
766
767 * dwarf_offdie.c (do_offdie): Renamed to __libdw_offdie, made global.
768 (dwarf_offdie, dwarf_offdie_types): Update callers.
769 * libdwP.h: Declare it.
770
771 * dwarf.h: Add DW_OP_GNU_implicit_pointer.
772 * dwarf_getlocation.c (__libdw_intern_expression): Handle it.
773
Roland McGrathde44f132010-08-24 15:38:42 -07007742010-08-24 Roland McGrath <roland@redhat.com>
775
776 * libdw.map (ELFUTILS_0.149): New set. Add dwfl_dwarf_line.
777
Roland McGrath00aca7f2010-07-27 04:40:23 -07007782010-07-27 Roland McGrath <roland@redhat.com>
779
780 * dwarf_formref_die.c: Fix sig8 hash insertion.
781
Roland McGrath9616b852010-06-23 03:17:28 -07007822010-06-23 Roland McGrath <roland@redhat.com>
783
784 * cfi.c (dwarf_cfi_validate_fde): Function removed.
785 * libdw.h: Remove it.
786 * libdw.map: Likewise.
787
Roland McGrath499b8ff2010-06-22 13:13:53 -07007882010-06-22 Roland McGrath <roland@redhat.com>
789
Roland McGrathc16966a2010-06-22 17:08:43 -0700790 * dwarf_getlocation.c (check_constant_offset): data[48] are constant.
791
Roland McGrath499b8ff2010-06-22 13:13:53 -0700792 * dwarf_getsrclines.c: Fix signed comparison warning in extended
793 opcode parsing.
794
Roland McGrath0c5638c2010-06-21 23:00:35 -07007952010-06-21 Roland McGrath <roland@redhat.com>
796
Roland McGrath474cb482010-06-22 00:10:54 -0700797 * dwarf.h: Add DW_TAG_GNU_* constants.
798
Roland McGrath0c5638c2010-06-21 23:00:35 -0700799 * memory-access.h (get_sleb128_rest_return): Fix sign extension for
800 10-byte case.
801
Roland McGrath5cc030d2010-06-20 17:25:35 -07008022010-06-20 Roland McGrath <roland@redhat.com>
803
Roland McGrath2b1f0952010-06-20 17:55:50 -0700804 * libdw_findcu.c (__libdw_findcu): Take new flag argument,
805 to search TUs instead of CUs.
806 * libdwP.h: Update decl.
807 (struct Dwarf): New member tu_tree.
808 * dwarf_end.c (dwarf_end): Clean up tu_tree.
809 * dwarf_offdie.c (do_offdie): New function, broken out of ...
810 (dwarf_offdie): ... here.
811 (dwarf_offdie_types): New function.
812 * libdw.h: Declare it.
813 * libdw.map (ELFUTILS_0.148): Add it.
814
Roland McGrath5cc030d2010-06-20 17:25:35 -0700815 * libdwP.h (CUDIE): Use cu_data.
816 * dwarf_formblock.c: Likewise.
817 * dwarf_formref_die.c: Likewise.
818 * dwarf_diecu.c: Use CUDIE macro.
819 * dwarf_formaddr.c: Use cu_sec_idx.
820
Roland McGrathc70ebc02010-06-16 02:21:26 -07008212010-06-16 Roland McGrath <roland@redhat.com>
822
Roland McGrath3e0f7d12010-06-15 23:10:35 -0700823 * dwarf_formref_die.c: Use dwarf_offdie only for DW_FORM_ref_addr, so
824 we don't repeat a CU lookup we've already done. Handle
825 DW_FORM_ref_sig8 using sig8_hash table and __libdw_intern_next_unit.
826
827 * libdw_findcu.c (__libdw_intern_next_unit): New function,
828 broken out of ...
829 (__libdw_findcu): ... here. Call it.
830 * libdwP.h: Declare it.
831 (struct Dwarf): New member next_tu_offset.
832
833 * dwarf_sig8_hash.c: New file.
834 * dwarf_sig8_hash.h: New file.
835 * Makefile.am (libdw_a_SOURCES, noinst_HEADERS): Add them.
836 * dwarf_abbrev_hash.c: Include dwarf_sig8_hash.h before
837 defining NO_UNDEF.
838 * libdwP.h (struct Dwarf): New member sig8_hash.
839 * dwarf_begin_elf.c: Call Dwarf_Sig8_Hash_init on it.
840 * dwarf_end.c: Call Dwarf_Sig8_Hash_free on it.
841
842 * dwarf_nextcu.c (dwarf_next_unit): New function, broken out of ...
843 (dwarf_nextcu): ... here. Call it.
844 * libdw.h: Declare it.
845 * libdwP.h: Add INTDECL.
846 * libdw_findcu.c (__libdw_findcu): Use it instead of dwarf_nextcu.
847 * libdw.map (ELFUTILS_0.148): New set, add dwarf_next_unit.
848
849 * libdwP.h (cu_sec_idx, cu_data): New functions.
850 Use .debug_types when CU is a TU.
851 * dwarf_cuoffset.c: Use that instead of assuming IDX_debug_info.
852 * dwarf_siblingof.c: Likewise.
853 * dwarf_formstring.c: Likewise.
854 * dwarf_formudata.c (__libdw_formptr, dwarf_formudata): Likewise.
855 * dwarf_getlocation.c (dwarf_getlocation): Likewise.
856 (dwarf_getlocation_addr): Likewise.
857
858 * libdwP.h (struct Dwarf_CU): Add new members type_offset, type_sig8.
859 (DIE_OFFSET_FROM_CU_OFFSET): Take flag argument; if true, compute
860 .debug_types header size instead of .debug_info header size.
861 (CUDIE): Use it.
862 * dwarf_diecu.c: Update caller.
863 * dwarf_getaranges.c: Likewise.
864 * dwarf_nextcu.c: Likewise.
865 * libdw_findcu.c (__libdw_findcu): Initialize new members.
866
Roland McGrath3e4b5bb2010-06-16 03:40:56 -0700867 * fde.c (fde_by_offset): Renamed to ...
868 (__libdw_fde_by_offset): ... this, made global and internal_function.
869 Don't take ADDRESS argument.
870 (__libdw_find_fde): Update caller. Do address sanity check here.
871 * cfi.h: Declare __libdw_fde_by_offset.
872 * cfi.c (dwarf_cfi_validate_fde): New function.
873 * libdw.h: Declare it.
874 * libdw.map (ELFUTILS_0.148): Add it.
875
Roland McGrath5f4b5082010-06-16 03:11:57 -0700876 * cie.c (intern_new_cie): Canonicalize DW_EH_PE_absptr FDE encoding to
877 either DW_EH_PE_udata8 or DW_EH_PE_udata4.
878
Roland McGrath7934ded2010-06-16 03:04:09 -0700879 * encoded-value.h (read_encoded_value): Handle DW_EH_PE_indirect.
880 Don't assume DW_EH_PE_aligned refers to native address size.
881
Roland McGrathc70ebc02010-06-16 02:21:26 -0700882 * cfi.c (execute_cfi): Barf on CIE initial instructions changing the
883 address.
884
Roland McGrathc70cf4e2010-06-18 17:01:05 -07008852010-06-17 Roland McGrath <roland@redhat.com>
886
887 * libdwP.h (struct Dwarf_Line_s): Add members isa, discriminator, and
888 op_index.
889 * dwarf_getsrclines.c (dwarf_getsrclines): Move NEW_FILE macro guts
890 into an inner inline function. Set new fields. Check all fields for
891 overflow when setting.
892 * dwarf_lineisa.c: New file.
893 * dwarf_linediscriminator.c: New file.
894 * dwarf_lineop_index.c: New file.
895 * Makefile.am (libdw_a_SOURCES): Add them.
896 * libdw.map (ELFUTILS_0.148): Add them.
897 * libdw.h: Declare them.
898
Roland McGrath3f633072010-06-15 22:17:04 -07008992010-06-16 Roland McGrath <roland@redhat.com>
900
Roland McGrath4a87dfa2010-06-16 16:35:10 -0700901 * dwarf_next_cfi.c: Fix version 4 return_address_register decoding.
902
Roland McGrathb75f4442010-06-15 22:24:19 -0700903 * fde.c (fde_by_offset): Renamed to ...
904 (__libdw_fde_by_offset): ... this, made global and internal_function.
905 Don't take ADDRESS argument.
906 (__libdw_find_fde): Update caller. Do address sanity check here.
907 * cfi.h: Declare __libdw_fde_by_offset.
Roland McGrath9bcd2652010-06-15 22:17:20 -0700908 * cfi.c (dwarf_cfi_validate_fde): New function.
909 * libdw.h: Declare it.
Roland McGrath3f633072010-06-15 22:17:04 -0700910 * libdw.map (ELFUTILS_0.148): Add it.
911
Roland McGrath0b3363e2010-06-01 15:42:14 -0700912 * cie.c (intern_new_cie): Canonicalize DW_EH_PE_absptr FDE encoding to
913 either DW_EH_PE_udata8 or DW_EH_PE_udata4.
Roland McGrath827d4d12010-06-01 20:17:36 -0700914
915 * encoded-value.h (read_encoded_value): Handle DW_EH_PE_indirect.
916 Don't assume DW_EH_PE_aligned refers to native address size.
Roland McGrath1a030b32010-06-01 20:11:40 -0700917
918 * cfi.c (execute_cfi): Barf on CIE initial instructions changing the
Roland McGrath675229b2010-06-01 20:10:19 -0700919 address.
920
9212010-06-15 Roland McGrath <roland@redhat.com>
Roland McGrath52123962010-06-01 19:05:08 -0700922
923 * dwarf_formref.c (__libdw_formref): Diagnose DW_FORM_ref_sig8 like
Roland McGrath7fac1ce2010-06-01 15:56:58 -0700924 DW_FORM_ref_addr.
925 * dwarf_formref_die.c (dwarf_formref_die): Diagnose it the same way
Roland McGrath0b3363e2010-06-01 15:42:14 -0700926 here, since we don't support it yet.
927
Mark Wielaard3f507bd2010-05-31 15:06:31 +0200928 * dwarf_next_cfi.c: Handle version 4 format.
929
Mark Wielaard08e71db2010-05-31 15:39:15 +0200930 * dwarf_getsrclines.c: Handle version 4 format.
931
9322010-06-01 Roland McGrath <roland@redhat.com>
933
934 * libdwP.h: Remove unused IDX_debug_*names, add IDX_debug_types.
Mark Wielaard3f507bd2010-05-31 15:06:31 +0200935 * dwarf_begin_elf.c (dwarf_scnnames): Likewise.
936
Eduardo Santiagod2240bc2010-05-28 14:26:52 -0700937 * libdwP.h (CIE_VERSION): Remove unused macro.
Ulrich Drepper6fb34512010-05-28 20:28:04 -0700938
Ulrich Drepper49fe7142010-05-28 20:32:37 -0700939 * dwarf_getsrclines.c: Fix version field test.
940 * libdwP.h (DWARF_VERSION): Remove useless macro.
Ulrich Drepper6fb34512010-05-28 20:28:04 -0700941
Roland McGrathcfa5da22010-05-27 13:49:25 -0700942 * dwarf_formudata.c (__libdw_formptr): Fix DW_FORM_sec_offset handling.
943
944 * dwarf_formblock.c (dwarf_formblock): Handle DW_FORM_exprloc.
945
946 * libdw_findcu.c (__libdw_findcu): Accept version 4.
Roland McGrath688f7fc2010-05-08 03:22:59 -0700947
9482010-05-31 Mark Wielaard <mjw@redhat.com>
949
950 * cfi.h (dwarf_cfi_cie_p): Move definition from here, to ..
951 * libdw.h (dwarf_cfi_cie_p): ... here.
952
9532010-05-31 Mark Wielaard <mjw@redhat.com>
954
955 * dwarf.h: Fix DW_LANG_Python constant.
Roland McGrath0ab97832010-04-26 11:50:27 -0700956
9572010-05-28 Eduardo Santiago <santiago@redhat.com>
Roland McGrath3b10ac02010-04-26 18:45:36 -0700958
959 * dwarf_getlocation.c (dwarf_getlocation): Do attr_ok check first
960 thing.
961
9622010-05-27 Roland McGrath <roland@redhat.com>
Roland McGrath0ab97832010-04-26 11:50:27 -0700963
964 * dwarf.h: Add DW_AT_enum_class, DW_AT_linkage_name,
965 DW_TAG_template_alias, DW_LANG_Python, DW_LNE_set_discriminator.
966
9672010-05-08 Roland McGrath <roland@redhat.com>
968
969 * dwarf_getlocation.c (__libdw_intern_expression): Take new argument
Roland McGrath3f9d9552010-04-22 20:51:07 -0700970 REF_SIZE. Use that to handle DW_OP_call_ref correctly.
971 (getlocation): Update caller.
972 * dwarf_frame_cfa.c (dwarf_frame_cfa): Likewise.
973 * dwarf_frame_register.c (dwarf_frame_register): Likewise.
974 * libdwP.h: Update decl.
975
9762010-04-26 Roland McGrath <roland@redhat.com>
Roland McGrath8068e062010-03-10 23:49:13 -0800977
978 * cfi.h (struct Dwarf_Frame_s): Add cfa_invalid alternative in cfa_rule.
979 * cfi.c (execute_cfi): Set that instead of doing cfi_assert for
980 DW_CFA_def_cfa_{offset*,register} when a non-offset rule is in force.
Roland McGrath22359e22010-02-15 15:57:03 -0800981 * dwarf_frame_cfa.c (dwarf_frame_cfa): Handle cfa_invalid.
982
983 * dwarf_getlocation.c (__libdw_intern_expression): Take new arg CFAP.
984 Prepend DW_OP_call_frame_cfa if true.
Mark Wielaardee29a312010-02-02 20:44:53 +0100985 (getlocation): Update caller.
986 * dwarf_frame_cfa.c (dwarf_frame_cfa): Likewise.
987 * dwarf_frame_register.c (dwarf_frame_register): Likewise.
988 * libdwP.h: Update decl.
Roland McGrathf95760a2010-01-07 20:24:34 -0800989
9902010-04-22 Roland McGrath <roland@redhat.com>
991
992 * cfi.c (execute_cfi): Never return without cleanup.
Roland McGrath019d9fb2010-01-05 13:36:07 -0800993 Free FS on failure.
994 (cie_cache_initial_state): Adjust caller to expect that free.
Roland McGrathebc5c882010-01-05 22:53:31 -0800995 (__libdw_frame_at_address): Likewise.
996
9972010-03-10 Roland McGrath <roland@redhat.com>
998
999 * libdw.map (ELFUTILS_0.146): New set. Add dwfl_core_file_report.
1000
10012010-02-15 Roland McGrath <roland@redhat.com>
1002
1003 * Makefile.am: Use config/eu.am for common stuff.
Roland McGrath0cb19832010-01-05 13:38:15 -08001004
10052010-02-02 Mark Wielaard <mjw@redhat.com>
Roland McGrath019d9fb2010-01-05 13:36:07 -08001006
1007 * fde.c (intern_fde): Fix length check for sized_augmentation_data.
Roland McGrath888381b2009-11-21 17:03:34 -08001008
10092010-01-07 Roland McGrath <roland@redhat.com>
1010
1011 * dwarf_getcfi_elf.c (getcfi_phdr): Use elf_getphdrnum.
1012
Roland McGrath9ca7bc42009-10-15 12:26:49 -070010132010-01-05 Roland McGrath <roland@redhat.com>
1014
1015 * dwarf_aggregate_size.c: New file.
1016 * Makefile.am (libdw_a_SOURCES): Add it.
1017 * libdw.h: Declare it.
Roland McGrath7e0aecd2009-09-17 15:02:34 -07001018 * libdwP.h: Add INTDECL.
1019 * libdw.map (ELFUTILS_0.144): New set. Add dwarf_aggregate_size.
1020
1021 * dwarf_srclang.c: Add INTDEF.
1022 * libdwP.h: Add INTDECL.
1023
Roland McGrathf0371042009-09-10 12:39:09 -07001024 * dwarf.h: Add some more DW_AT_GNU_* types from gcc.
1025
1026 * dwarf.h: Add DW_AT_GNU_vector, DW_AT_GNU_template_name.
1027
10282009-11-21 Roland McGrath <roland@redhat.com>
1029
1030 * dwarf_getlocation.c (check_constant_offset): Return 1 for all
1031 non-constant forms.
Mark Wielaard418ae4c2009-09-09 20:59:26 +02001032
10332009-10-15 Roland McGrath <roland@redhat.com>
1034
1035 * libdw_form.c (__libdw_form_val_len): Grok DW_FORM_sec_offset,
Josh Stonecc93cc42009-08-21 18:04:44 -07001036 DW_FORM_exprloc, DW_FORM_flag_present, and DW_FORM_ref_sig8.
1037
10382009-09-17 Roland McGrath <roland@redhat.com>
1039
Roland McGrath08277ba2009-08-10 15:08:08 -07001040 * dwarf_getlocation.c (dwarf_getlocation_implicit_value): Make OP
1041 argument a pointer to const.
1042 * libdw.h: Update decl.
1043
Roland McGrathebfb6482009-08-09 15:40:52 -070010442009-09-10 Roland McGrath <roland@redhat.com>
1045
1046 * dwarf_getlocation.c (store_implicit_value): New function.
1047 (__libdw_intern_expression): Use it, handle DW_OP_implicit_value.
1048 (dwarf_getlocation_implicit_value): New function.
1049 * libdw.h: Declare it.
1050 * libdw.map (ELFUTILS_0.143): Add it.
1051
10522009-09-09 Mark Wielaard <mjw@redhat.com>
1053
1054 * dwarf_getcfi.c (dwarf_getcfi): Clear cfi->ebl.
1055
10562009-08-21 Josh Stone <jistone@redhat.com>
1057
Roland McGrathde69d522009-08-07 18:26:19 -07001058 * dwarf_hasattr_integrate.c: Integrate DW_AT_specification too.
1059
10602009-08-10 Roland McGrath <roland@redhat.com>
1061
1062 * dwarf_getscopevar.c: Use dwarf_diename.
1063
10642009-08-09 Roland McGrath <roland@redhat.com>
1065
1066 * libdw.map (ELFUTILS_0.143): New version set,
1067 inherits from ELFUTILS_0.142.
Roland McGrathaf800142009-07-22 13:55:50 -07001068 * dwarf_arrayorder.c: Use OLD_VERSION and NEW_VERSION to define an
1069 alias in the ELFUTILS_0.122 version set and the default in the new set.
1070 * dwarf_srclang.c: Likewise.
1071 * dwarf_decl_file.c: Likewise.
1072 * dwarf_decl_line.c: Likewise.
1073 * dwarf_decl_column.c: Likewise.
1074 * dwarf_bytesize.c: Likewise.
1075 * dwarf_bitsize.c: Likewise.
1076 * dwarf_bitoffset.c: Likewise.
1077
10782009-08-07 Roland McGrath <roland@redhat.com>
1079
1080 * dwarf_arrayorder.c: Use dwarf_attr_integrate.
1081 * dwarf_srclang.c: Likewise.
1082 * dwarf_decl_file.c: Likewise.
1083 * dwarf_decl_line.c (__libdw_attr_intval): Likewise.
Roland McGrathe23e9e72009-07-21 18:14:52 -07001084 * dwarf_bytesize.c: Likewise.
1085 * dwarf_bitsize.c: Likewise.
1086 * dwarf_bitoffset.c: Likewise.
1087
10882009-07-22 Roland McGrath <roland@redhat.com>
1089
1090 * dwarf_frame_cfa.c: Change calling convention.
1091 * libdw.h: Update decl.
Roland McGrath96349ff2009-07-20 11:51:41 -07001092
1093 * dwarf_frame_register.c: Change calling/return-value convention for
1094 value-only results and undefined/same_value.
1095 * libdw.h: Update decl.
1096
Roland McGratha6abdfd2009-07-16 17:40:19 -07001097 * dwarf_getlocation.c (__libdw_intern_expression): Take new bool
1098 argument, append DW_OP_stack_value if set. Don't take NOPS argument,
Roland McGrathe160cc92009-07-16 17:48:27 -07001099 return that value instead.
1100 (getlocation): Update caller.
1101 * dwarf_frame_cfa.c: Likewise.
1102 * libdwP.h: Update decl.
1103
Roland McGratha6abdfd2009-07-16 17:40:19 -070011042009-07-21 Roland McGrath <roland@redhat.com>
1105
1106 * dwarf_getsrc_file.c: Ignore a CU that just has no DW_AT_stmt_list.
1107 Fix loop iteration after skipping a bogus or useless CU.
1108
1109 * dwarf_entry_breakpoints.c: Handle 0 dwarf_errno () as harmless
1110 absence, not DWARF_E_NO_DEBUG_LINE.
Roland McGrath7dd94642009-07-15 11:14:23 -07001111
11122009-07-20 Roland McGrath <roland@redhat.com>
1113
1114 * dwarf_getlocation.c (__libdw_intern_expression):
1115 Handle DW_OP_stack_value.
Roland McGrath80893432009-07-13 12:08:55 -07001116
11172009-07-16 Roland McGrath <roland@redhat.com>
1118
1119 * dwarf_formudata.c (__libdw_formptr): Handle DW_FORM_sec_offset,
Roland McGrathcfdd86e2009-07-08 13:15:07 -07001120 reject others when CU's version > 3.
1121
Roland McGrath3c84db32009-06-24 17:41:40 -07001122 * dwarf_formflag.c: Handle DW_FORM_flag_present.
1123
1124 * dwarf.h: Add DW_OP_{implicit,stack}_value from DWARF 4 draft.
1125 Also DW_TAG_type_unit and DW_TAG_rvalue_reference_type.
1126 Also DW_AT_signature, DW_AT_main_subprogram, DW_AT_data_bit_offset,
1127 and DW_AT_const_expr.
1128 Also DW_FORM_sec_offset, DW_FORM_exprloc, DW_FORM_flag_present,
1129 and DW_FORM_ref_sig8.
1130
11312009-07-15 Roland McGrath <roland@redhat.com>
1132
1133 * dwarf_getlocation.c: Grok DW_OP_form_tls_address,
1134 DW_OP_GNU_push_tls_address, and DW_OP_bit_piece.
1135
11362009-07-13 Roland McGrath <roland@redhat.com>
1137
1138 * dwarf_getlocation.c: Grok DW_OP_call_frame_cfa.
1139
11402009-07-08 Roland McGrath <roland@redhat.com>
1141
1142 * libdw.map (ELFUTILS_0.142): Add dwfl_module_dwarf_cfi,
1143 dwfl_module_eh_cfi.
1144
1145 * libdwP.h (struct Dwarf): Add member `cfi'.
1146 * dwarf_end.c (dwarf_end): Call __libdw_destroy_frame_cache on it.
1147 * dwarf_getcfi.c: New file.
1148 * dwarf_getcfi_elf.c: New file.
1149 * dwarf_cfi_end.c: New file.
1150 * dwarf_cfi_addrframe.c: New file.
1151 * dwarf_frame_cfa.c: New file.
1152 * dwarf_frame_register.c: New file.
1153 * dwarf_frame_return_address_register.c: New file.
1154 * Makefile.am (libdw_a_SOURCES): Add them.
1155 * unwind.h: Declare those functions.
1156 * libdw.map (ELFUTILS_0.142): Export them.
1157
1158 * dwarf_getlocation.c (__libdw_intern_expression): New function,
1159 broken out of ...
1160 (getlocation): ... here, call it.
1161 * libdwP.h: Declare it.
1162
1163 * cie.c: New file.
1164 * fde.c: New file.
1165 * frame-cache.c: New file.
1166 * cfi.c: New file.
1167 * cfi.h: New file.
1168 * encoded-value.h: New file.
1169 * Makefile.am (libdw_a_SOURCES, noinst_HEADERS): Add them.
1170 * libdwP.h: Add DWARF_E_INVALID_CFI to errors enum.
1171 * dwarf_error.c (errmsgs): Add element for it.
1172
1173 * dwarf_next_cfi.c: New file.
1174 * Makefile.am (libdw_a_SOURCES): Add it.
Roland McGrath6e1f4652009-07-08 14:48:34 -07001175 * libdw.h (Dwarf_CIE, Dwarf_FDE, Dwarf_CIE_Entry): New types.
1176 Declare dwarf_next_cfi.
Roland McGrathcfdd86e2009-07-08 13:15:07 -07001177 * libdw.map (ELFUTILS_0.142): New set, inherits from ELFUTILS_0.136.
1178 Add dwarf_next_cfi.
1179
1180 * memory-access.h [! ALLOW_UNALIGNED]
Roland McGrath05c4e042009-06-18 13:56:02 -07001181 (read_2ubyte_unaligned): Renamed to ...
1182 (read_2ubyte_unaligned_1): ... this. Take bool rather than Dwarf *.
1183 (read_2ubyte_unaligned): Define as macro passing dbg->other_byte_order.
1184 (read_2sbyte_unaligned): Likewise.
1185 (read_4ubyte_unaligned): Likewise.
1186 (read_4sbyte_unaligned): Likewise.
1187 (read_8ubyte_unaligned): Likewise.
1188 (read_8sbyte_unaligned): Likewise.
1189
Ulrich Drepper99d23722009-06-14 20:19:45 -07001190 * libdwP.h (IDX_eh_frame): Remove it.
1191 * dwarf_begin_elf.c (dwarf_scnnames): Remove its element.
1192
11932009-07-08 Roland McGrath <roland@redhat.com>
1194
1195 * libdwP.h (struct Dwarf_Line_s): Reorder members to pack better.
1196
1197 * dwarf_getlocation.c (check_constant_offset): New function.
1198 (dwarf_getlocation, dwarf_getlocation_addr): Call it to
1199 handle DW_AT_data_member_location of data[48] as constant offset.
1200
12012009-06-18 Roland McGrath <roland@redhat.com>
1202
1203 * libdwP.h (__libdw_read_address_inc): Constify.
1204 (__libdw_read_offset_inc): Likewise.
1205 * dwarf_getaranges.c: Likewise.
1206 * dwarf_getlocation.c: Likewise.
1207 * dwarf_getsrclines.c: Likewise.
1208 * dwarf_nextcu.c: Likewise.
1209
12102009-05-05 Petr Machata <pmachata@redhat.com>
1211
1212 * libdwP.h (__libdw_formptr): Declare new function.
1213 * dwarf_formudata.c: Implement it here.
1214 * dwarf_getlocation.c (dwarf_getlocation_addr):
1215 Call it instead of hand-rolled offset handling code.
1216 * dwarf_getsrclines.c (dwarf_getsrclines): Likewise.
1217 * dwarf_ranges.c (dwarf_ranges): Likewise.
1218
12192009-05-04 Petr Machata <pmachata@redhat.com>
1220
1221 * libdwP.h (__libdw_read_begin_end_pair_inc): Declare new function.
1222 * dwarf_ranges.c: Implement it here.
1223 (dwarf_ranges): Call it.
Roland McGrathe2eabd82009-05-07 18:54:52 -07001224 * dwarf_getlocation.c (dwarf_getlocation_addr): Call it also here.
1225
12262009-04-23 Petr Machata <pmachata@redhat.com>
1227
1228 * dwarf_formaddr.c (dwarf_formaddr): Call __libdw_read_* instead
1229 of read_*ubyte_unaligned.
Petr Machataf3df61f2009-05-07 21:02:33 +02001230 * dwarf_formref_die.c (dwarf_formref_die): Likewise.
1231 * dwarf_formstring.c (dwarf_formstring): Likewise.
1232 * dwarf_formudate.c (dwarf_formudata): Likewise.
1233 * dwarf_getaranges.c (dwarf_getaranges): Likewise.
1234 * dwarf_getlocation.c (dwarf_getlocation_addr): Likewise.
Roland McGrath2fb90512009-04-15 14:47:13 -07001235 * dwarf_getpubnames.c (get_offsets): Likewise.
1236 * dwarf_nextcu.c (dwarf_nextcu): Likewise.
1237
12382009-04-23 Petr Machata <pmachata@redhat.com>
1239
Roland McGrath6a4bdd92009-04-01 14:25:29 -07001240 * libdwP.h (__libdw_read_addr_inc, __libdw_read_off_inc,
1241 __libdw_read_addr, __libdw_read_off): Add four new internal
1242 functions.
1243
Roland McGrathc5acb302009-01-28 18:28:52 -080012442009-05-07 Roland McGrath <roland@redhat.com>
1245
Roland McGrath03288f02009-01-28 22:00:54 -08001246 * dwarf_getmacros.c (dwarf_getmacros): Use absolute section offset in
1247 return value and OFFSET argument, not CU-relative. Only fetch the
1248 attribute data when called with OFFSET of 0.
Roland McGrathc5acb302009-01-28 18:28:52 -08001249
12502009-05-07 Petr Machata <pmachata@redhat.com>
Roland McGrathf46272a2009-01-26 18:36:16 -08001251
1252 * dwarf_getmacros.c (dwarf_getmacros): Take into account offset in
1253 DW_AT_macro_info attribute of CU DIE.
1254
Roland McGrathd31505f2009-01-25 19:37:33 -080012552009-04-15 Roland McGrath <roland@redhat.com>
1256
1257 * dwarf.h (DW_CIE_ID): Removed.
1258 (DW_CIE_ID_32, DW_CIE_ID_64): New constants replace it.
Roland McGrath3bf7a092009-01-23 16:34:07 -08001259
12602009-04-01 Roland McGrath <roland@redhat.com>
1261
1262 * dwarf.h: Add DW_CFA_GNU_negative_offset_extended.
1263
Roland McGrathafdd51e2009-01-22 02:26:24 -080012642009-01-28 Roland McGrath <roland@redhat.com>
1265
1266 * libdwP.h (struct Dwarf_Line_s): Move out of struct Dwarf_Lines_s
1267 defn so C++ doesn't scope the name to not match the Dwarf_Line typedef.
Roland McGrath1ea4fdc2009-01-21 19:14:37 -08001268
1269 * libdwP.h (struct Dwarf_Files_s): Replace dbg field with cu field.
1270
12712009-01-26 Roland McGrath <roland@redhat.com>
1272
1273 * dwarf_ranges.c: Return 0 when no ranges or *_pc attrs at all.
Roland McGrath24b03302009-01-17 14:34:13 -08001274
12752009-01-25 Roland McGrath <roland@redhat.com>
Roland McGrath54456d82009-01-17 14:39:35 -08001276
1277 * dwarf_getattrs.c: Correctly skip attribute values when restarting.
1278
Roland McGrath5513e642009-01-11 01:35:11 -080012792009-01-23 Roland McGrath <roland@redhat.com>
1280
1281 * Makefile.am ($(srcdir)/known-dwarf.h): Target renamed back.
1282 Put these rules under if MAINTAINER_MODE.
1283
12842009-01-22 Roland McGrath <roland@redhat.com>
1285
Roland McGrath24b03302009-01-17 14:34:13 -08001286 * dwarf.h: Add DW_OP_GNU_encoded_addr.
1287
Ulrich Drepper7e678fa2009-01-10 18:02:05 -080012882009-01-21 Roland McGrath <roland@redhat.com>
1289
1290 * Makefile.am (CLEANFILES): Renamed to ...
1291 (MOSTLYCLEANFILES): ... here.
Roland McGrathe06762c2009-01-08 13:39:08 -08001292 (CLEANFILES): New variable, add known-dwarf.h.
1293
12942009-01-17 Roland McGrath <roland@redhat.com>
1295
Roland McGrath7e827f22009-01-06 02:09:50 -08001296 * Makefile.am (known-dwarf.h): Target renamed, not in $(srcdir).
Roland McGrath1f6d2012008-12-31 00:21:04 -08001297 Make it unconditional.
1298 (BUILT_SOURCES): Updated.
1299
1300 * dwarf.h: Add description comments for DW_LANG_* values.
Roland McGrathbca43152009-01-05 23:59:32 -08001301
1302 * Makefile.am [MAINTAINER_MODE]
1303 ($(srcdir)/known-dwarf.h): New target.
Ulrich Drepperac194d02009-01-06 00:30:01 -08001304 (BUILT_SOURCES): Add it.
1305
Roland McGrathc462c632009-01-06 01:04:31 -08001306 * dwarf.h: Add DW_OP_GNU_push_tls_address, DW_OP_GNU_uninit.
Ulrich Drepperac194d02009-01-06 00:30:01 -08001307
13082009-01-10 Ulrich Drepper <drepper@redhat.com>
1309
1310 * dwarf_error.c: Always use __thread. Remove all !USE_TLS code.
Roland McGrathb4d6f0f2008-08-25 22:55:17 +00001311
13122009-01-08 Roland McGrath <roland@redhat.com>
1313
1314 * Makefile.am (libdw.so): Don't depend on $(zip_LIBS), just link it in.
1315
Ulrich Drepper8d358d92008-01-22 06:34:31 +000013162008-01-06 Roland McGrath <roland@redhat.com>
1317
1318 * libdwP.h (struct Dwarf_Abbrev): Change type of 'has_children' to bool.
1319 Reorder members.
1320 * dwarf_haschildren.c: Return -1 for error case, not 0.
1321
1322 * Makefile.am (libdw.so): Link in $(zip_LIBS).
1323
Ulrich Drepperb27ce002008-01-18 20:08:54 +000013242009-01-06 Ulrich Drepper <drepper@redhat.com>
1325
1326 * dwarf.h: Add definition for unwind and call frame information.
1327
1328 * memory-access.h: Define read_ubyte_unaligned, read_sbyte_unaligned,
Ulrich Drepper35f08c42008-01-18 19:59:08 +00001329 read_ubyte_unaligned_inc, and read_sbyte_unaligned_inc.
1330
13312008-08-15 Roland McGrath <roland@redhat.com>
1332
1333 * libdw.map (ELFUTILS_0.136): New version set, inherits from
1334 ELFUTILS_0.130. Add dwfl_addrsegment, dwfl_report_segment.
1335
13362008-01-21 Ulrich Drepper <drepper@redhat.com>
1337
1338 * dwarf_child.c: Minor optimizations.
1339 * dwarf_getattrs.c: Likewise.
1340 * dwarf_getpubnames.c: Likewise.
1341 * dwarf_siblingof.c: Likewise.
Ulrich Dreppera969d8e2008-01-22 06:15:00 +00001342 * dwarf_tag.c: Likewise.
Ulrich Drepper35f08c42008-01-18 19:59:08 +00001343
13442008-01-18 Ulrich Drepper <drepper@redhat.com>
1345
1346 * dwarf_getsrclines.c (dwarf_getsrclines): Don't require exact match
1347 of DWARF_VERSION comparison, just fail if the file's version is newer.
1348
13492008-01-17 Nick Clifton <nickc@redhat.com>
1350
1351 * dwarf.h (DWARF3_LENGTH_MIN_ESCAPE_CODE): New define.
1352 (DWARF3_LENGTH_MAX_ESCAPE_CODE): New define.
1353 (DWARF3_LENGTH_64_BIT): New define.
1354 * dwarf_getaranges (dwarf_getaranges): Use the new definitions.
1355 * dwarf_getpubnames: Include dwarf.h.
1356 (get_offsets): Use the new definitions.
1357 * dwarf_getsrclines.c (dwarf_getsrclines): Use the new defintions.
1358 * dwarf_nextcu.c: Include dwarf.h. Correct comment.
1359 (dwarf_nextcu): Use the new definitions.
1360
1361 * libdwP.h (DIE_OFFSET_FROM_CU_OFFSET): New macro.
1362 * dwarf_diecu.c (dwarf_diecu): Use the new macro.
1363 * dwarf_getaranges (dwarf_getaranges): Use the new macro.
1364 * dwarf_nextcu.c (dwarf_nextcu): Use the new macro.
1365
1366 * dwarf_getpubnames (get_offsets): Replace assertion with test and
1367 error return.
1368
1369 * dwarf_entry_breakpoints.c (dwarf_entry_breakpoints): Use CUDIE.
1370
1371 * dwarf_siblingof (dwarf_siblingof): Detect a NULL return pointer.
1372 Set the address in the return structure to the address of the next
1373 non-sibling die, if there is no sibling and the return pointer is
1374 not the same as the die pointer.
Ulrich Dreppere219f1c2008-01-09 05:49:49 +00001375 * libdw.h: Expand the description of the dwarf_siblingof prototype.
1376
1377 * dwarf_child.c: Fix typo in comment.
1378
1379 * libdwP.h (DWARF_VERSION): Change to 3.
1380
Roland McGrathe4c22ea2007-10-23 13:07:39 +00001381 * dwarf_formref.c (__libdw_formref.c): Handle attributes which do
1382 not have a initialised valp pointer.
1383
1384 * dwarf_getattrs.c (dwarf_getattrs): Return 1 rather than 0 when
1385 the end of the attributes is reached. When the callback fails,
1386 return the address of the failing attribute, not the address of
1387 its successor.
1388 * libdw.h: Expand the description of the dwarf_getattrs prototype.
1389
1390 * dwarf_child.c (__libdw_find_attr): Use the new definition.
1391 (dwarf_child): Likewise.
1392 * dwarf_tag.c (__libdw_findabbrev): Likewise.
1393 (dwarf_tag): Likewise.
1394
13952008-01-08 Roland McGrath <roland@redhat.com>
1396
1397 * Makefile.am (euinclude): Variable removed.
1398 (pkginclude_HEADERS): Set this instead of euinclude_HEADERS.
1399 (libdw.so): Pass -Wl,--enable-new-dtags,-rpath,$(pkglibdir).
Ulrich Drepperb597dfa2007-10-16 05:21:27 +00001400
14012007-10-17 Roland McGrath <roland@redhat.com>
1402
1403 * libdw.h (__deprecated_attribute__): New macro.
1404 (dwarf_formref): Mark it deprecated.
1405 * dwarf_formref.c (__libdw_formref): New function, broken out of ...
1406 (dwarf_formref): ... here. Call it. Remove INTDEF.
Roland McGrath59ea7f32007-10-04 08:50:09 +00001407 * libdwP.h: Remove INTDECL.
1408 Declare __libdw_formref.
1409 * dwarf_siblingof.c (dwarf_siblingof): Call __libdw_formref instead.
1410 * dwarf_formref_die.c: Likewise. Handle DW_FORM_ref_addr here.
1411
1412 * libdw_form.c (__libdw_form_val_len): Fix DW_FORM_ref_addr result,
1413 needs to check CU->version.
1414
Roland McGrath057ec6b2007-10-02 20:55:05 +00001415 * libdwP.h (struct Dwarf_CU): New member `version'.
1416 * libdw_findcu.c (__libdw_findcu): Initialize it.
1417
1418 * dwarf_child.c: Return 1 for null entry as first child.
1419
Roland McGrathd1a48172007-08-07 19:51:01 +000014202007-10-05 Roland McGrath <roland@redhat.com>
1421
1422 * dwarf_begin_elf.c (check_section): Punt on SHT_NOBITS sections.
1423
1424 * libdw.h (__extern_inline): Rename to __libdw_extern_inline.
1425 [__OPTIMIZE__] (dwarf_whatattr, dwarf_whatform): Update uses.
1426
14272007-10-03 Roland McGrath <roland@redhat.com>
1428
1429 * libdw.map (ELFUTILS_0.130: Add dwfl_build_id_find_elf
1430 and dwfl_build_id_find_debuginfo.
Roland McGrath87d47802007-07-16 22:23:37 +00001431
1432 * libdw.map (ELFUTILS_0.130): New version set, inherits from
1433 ELFUTILS_0.127. Add dwfl_module_build_id, dwfl_module_report_build_id.
1434
14352007-10-02 Roland McGrath <roland@redhat.com>
Roland McGrath43da9892007-04-16 23:13:37 +00001436
1437 * libdw_visit_scopes.c (classify_die): Return walk for class_type and
1438 structure_type.
1439
Roland McGrathbf2ee482007-04-05 09:27:36 +000014402007-08-07 Roland McGrath <roland@redhat.com>
1441
Roland McGrath43da9892007-04-16 23:13:37 +00001442 * dwarf_getscopes.c (pc_match): Swallow dwarf_haspc error return when
1443 error code is DWARF_E_NOERROR (0).
1444
1445 * dwarf_getscopes.c (pc_record): Always bail early if DIE->prune.
1446 Fix typo in __libdw_visit_scopes argument.
1447
1448 * dwarf_getscopes.c (pc_match): Check dwarf_haspc error return,
1449 swallow DWARF_E_NO_DEBUG_RANGES but not other errors.
1450
14512007-07-03 Roland McGrath <roland@redhat.com>
Roland McGrathbf2ee482007-04-05 09:27:36 +00001452
1453 * libdw.h (__extern_inline): New macro.
1454 [__OPTIMIZE__] (dwarf_whatattr, dwarf_whatform): Use it.
1455
Ulrich Drepperc07fbb32007-03-30 19:14:59 +000014562007-04-16 Roland McGrath <roland@redhat.com>
1457
1458 * libdw.map (ELFUTILS_0.127): Add dwfl_module_address_section.
1459
14602007-04-05 Roland McGrath <roland@redhat.com>
1461
1462 * dwarf_getsrcdirs.c: New file.
1463 * Makefile.am (libdw_a_SOURCES): Add it.
Ulrich Drepper6258e742007-03-13 06:22:40 +00001464 * libdw.h: Declare dwarf_getsrcdirs.
1465 * libdw.map (ELFUTILS_0.127): Add it.
1466
1467 * libdwP.h (struct Dwarf_Files_s): New member ndirs.
1468 * dwarf_getsrclines.c (dwarf_getsrclines): Don't clobber NDIRLIST to
1469 zero before we use it to check for DWARF_E_INVALID_DIR_IDX.
1470 Save DIRARRAY in the Dwarf_Files.
1471
1472 * dwarf_ranges.c (dwarf_ranges): Don't sign-extend 32-bit BEGIN
Ulrich Drepper903c1162007-02-15 19:40:37 +00001473 address to check for all-ones base address entry. Check directly.
1474 Reported by Sébastien Dugué <sebastien.dugue@bull.net>.
1475
14762007-03-25 Roland McGrath <roland@redhat.com>
Ulrich Drepperaa915fd2007-02-05 07:25:33 +00001477
1478 * dwarf_begin_elf.c (check_section): Return Dwarf * instead of void.
1479 Return NULL when freeing RESULT on error.
1480 (global_read, scngrp_read): Check return value from check_section,
1481 break out of loop after it has freed RESULT.
1482 (valid_p): Handle null argument.
1483
Roland McGrath8190db62006-12-17 23:56:51 +000014842007-03-12 Roland McGrath <roland@redhat.com>
1485
1486 * libdw.map (ELFUTILS_0.127): Add dwfl_report_begin_add.
1487
14882007-03-04 Roland McGrath <roland@redhat.com>
Roland McGrathc373d852006-10-10 00:25:21 +00001489
1490 * libdw.map (ELFUTILS_0.127): New version set, inherits from
1491 ELFUTILS_0.126. Add dwfl_module_addrsym.
1492
14932007-02-10 Roland McGrath <roland@redhat.com>
1494
1495 * dwarf.h (DW_OP_fbreg): Comment fix.
1496
14972007-02-03 Roland McGrath <roland@redhat.com>
1498
1499 * dwarf_getelf.c (dwarf_getelf): Renamed from dwarf_get_elf.
1500 * libdw.map (ELFUTILS_0.126): New version set, inherits from
Ulrich Drepper077c65f2006-07-12 19:54:51 +00001501 ELFUTILS_0.122. Move dwarf_getelf there; it was never truly
1502 exported in the past.
1503
15042006-12-17 Roland McGrath <roland@redhat.com>
1505
1506 * dwarf_getlocation.c (dwarf_getlocation_addr): Use zero as base
1507 address when the CU is missing attributes due to buggy GCC.
1508
Ulrich Dreppere1812e12006-07-12 07:46:03 +000015092006-08-29 Roland McGrath <roland@redhat.com>
1510
1511 * Makefile.am (CLEANFILES): Add libdw.so.$(VERSION).
1512
1513 * libdw.h (dwarf_diecu): Add __nonnull_attribute__.
1514 (dwarf_child): Don't list arg 1 in __nonnull_attribute__.
1515
Ulrich Drepper3be74472006-05-27 18:15:40 +00001516 * libdw_alloc.c (__libdw_allocate): Take new ALIGN argument, make sure
1517 result is aligned. Adjust NEWP->remaining here for this allocation.
1518 * libdwP.h: Update decl.
1519 (libdw_alloc): Update caller.
Ulrich Dreppere7a73172006-05-22 18:16:45 +00001520
15212006-07-12 Ulrich Drepper <drepper@redhat.com>
1522
1523 * dwarf_child.c: Adjust for internal_function_def removal.
1524 * dwarf_getabbrev.c: Likewise.
Ulrich Drepper4f3d2a22006-05-22 01:30:56 +00001525 * dwarf_tag.c: Likewise.
1526 * libdw_form.c: Likewise.
1527 * memory-access.c: Likewise.
1528
15292006-06-28 Roland McGrath <roland@redhat.com>
Roland McGrath2dade662006-02-28 22:13:20 +00001530
1531 * libdw.map: Export dwfl_linecu, dwfl_line_comp_dir.
1532
1533 * libdw.map: Bump to 0.122; export dwfl_module_getsymtab and
1534 dwfl_module_getsym.
1535
Roland McGrath08333122006-02-27 04:54:26 +000015362006-05-27 Ulrich Drepper <drepper@redhat.com>
1537
1538 * libdw.h: Add extern "C".
1539
Roland McGrath50ffcbf2005-12-23 01:51:43 +000015402006-05-22 Ulrich Drepper <drepper@redhat.com>
1541
1542 * dwarf_getaranges.c (dwarf_getaranges): Handle files without
1543 aranges information.
Roland McGrathdec3a242005-12-12 08:35:55 +00001544
15452006-05-21 Ulrich Drepper <drepper@redhat.com>
1546
1547 * libdw.h: Add nonnull attributes to dwarf_tag, dwarf_getattrs,
1548 dwarf_haschildren.
Roland McGrathf64a4422005-12-09 23:40:30 +00001549
15502006-02-28 Roland McGrath <roland@redhat.com>
1551
1552 * dwarf.h: Add missing DW_ATE_*, DW_TAG_*, DW_LANG_*, DW_CFA_*,
1553 DW_OP_* values, to match DWARF 3.0. Add new DW_DS_*, DW_END_*
1554 values from DWARF 3.0.
Roland McGrath994b4892005-12-05 22:46:21 +00001555
15562006-02-22 Roland McGrath <roland@redhat.com>
1557
1558 * libdw.map: Bump to 0.120; export dwfl_version.
Roland McGrathe47ab762005-11-17 03:16:00 +00001559
15602005-12-22 Roland McGrath <roland@redhat.com>
1561
1562 * libdw.map: Bump to 0.119; export dwfl_linux_proc_maps_report.
1563
15642005-12-12 Roland McGrath <roland@redhat.com>
1565
1566 * dwarf_ranges.c: Copy CU base address-finding code from
Roland McGrath07d4f2f2005-10-28 06:56:24 +00001567 dwarf_getlocation.
1568
15692005-12-09 Roland McGrath <roland@redhat.com>
1570
1571 * dwarf_getlocation.c (dwarf_getlocation_addr): Add some unlikelys.
1572 Delay CU base lookup until it's needed.
1573 If CU base lookup fails with no error, flag invalid DWARF.
1574
15752005-11-25 Roland McGrath <roland@redhat.com>
1576
1577 * libdw.map: Bump to 0.118; export dwfl_module_register_names.
1578
Roland McGrath6724c902005-10-28 07:07:19 +000015792005-11-15 Roland McGrath <roland@redhat.com>
1580
1581 * Makefile.am [BUILD_STATIC] (AM_CFLAGS): Add -fpic.
1582
15832005-11-13 Roland McGrath <roland@redhat.com>
1584
1585 * libdw.map: Bump to 0.117; export dwfl_module_return_value_location.
1586
15872005-10-27 Roland McGrath <roland@redhat.com>
1588
1589 * dwarf_entry_breakpoints.c (search_range): Fix binary search code;
1590 don't match end_sequence markers.
1591
1592 * dwarf_getsrclines.c (compare_lines): Sort end_sequence markers
1593 before normal records at the same address.
1594 * dwarf_getsrc_die.c (dwarf_getsrc_die): Don't match an end_sequence
1595 marker.
1596
15972005-10-26 Roland McGrath <roland@redhat.com>
1598
1599 * dwarf_getfuncs.c (dwarf_getfuncs): Use Dwarf_Die, not Dwarf_Func.
1600 * dwarf_func_file.c: Renamed to ...
1601 * dwarf_decl_file.c: ... here.
1602 * dwarf_func_col.c: Renamed to ...
1603 * dwarf_decl_column.c: ... here.
1604 * dwarf_func_line.c: Renamed to ...
1605 * dwarf_decl_line.c: ... here.
1606 (dwarf_func_line): Renamed to ...
1607 (dwarf_decl_line): ... this. Take a Dwarf_Die * argument.
1608 (__libdw_func_intval): Renamed __libdw_attr_intval.
1609 * dwarf_func_name.c: File removed.
1610 * dwarf_func_lowpc.c: File removed.
1611 * dwarf_func_highpc.c: File removed.
1612 * dwarf_func_entrypc.c: File removed.
1613 * dwarf_func_die.c: File removed.
1614 * Makefile.am (libdw_a_SOURCES): Updated.
1615 * libdw.h: Update decls.
1616 (Dwarf_Func): Type removed.
1617 * libdwP.h: Update decls.
Roland McGrath07d4f2f2005-10-28 06:56:24 +00001618 (struct Dwarf_Func_s): Type removed.
1619 * libdw.map: Updated.
1620
1621 * libdwP.h (CUDIE): New macro.
1622 * dwarf_getlocation.c (dwarf_getlocation_addr): Use it.
1623 * dwarf_getscopes_die.c (dwarf_getscopes_die): Likewise.
1624 * dwarf_ranges.c (dwarf_ranges): Likewise.
1625
1626 * dwarf_getloclist.c: Renamed to ...
1627 * dwarf_getlocation.c: ... here.
1628 (getloclist): Renamed to getlocation.
1629 (dwarf_getloclist): Renamed to dwarf_getlocation.
1630 (dwarf_addrloclists): Renamed to dwarf_getlocation_addr.
1631 * Makefile.am (libdw_a_SOURCES): Updated.
1632 * libdw.h (dwarf_getloclist): Renamed to dwarf_getlocation.
1633 (dwarf_addrloclists): Renamed dwarf_getlocation_addr.
1634 (Dwarf_Loc): Renamed Dwarf_Op.
1635 * libdwP.h (struct loc_s): Update use.
1636 * libdw.map: Update map.
1637
1638 * dwarf_entry_breakpoints.c: Use the second line record within the
1639 function, regardless of its source location data.
1640
16412005-10-25 Roland McGrath <roland@redhat.com>
1642
1643 * dwarf_entry_breakpoints.c: Fall back to entrypc for contiguous too.
1644
1645 * libdw.map: Add dwarf_entrypc, dwarf_entry_breakpoints.
1646
16472005-10-14 Roland McGrath <roland@redhat.com>
1648
1649 * dwarf_diecu.c (dwarf_diecu): New file.
1650 * Makefile.am (libdw_a_SOURCES): Add it.
1651 * libdw.h: Declare dwarf_diecu.
1652 * libdw.map: Export it.
1653
1654 * libdw.map: Bump to 0.116; export dwarf_ranges.
1655
16562005-09-20 Roland McGrath <roland@redhat.com>
1657
1658 * dwarf_haspc.c: Use dwarf_ranges.
1659 * dwarf_entry_breakpoints.c: Likewise.
1660
1661 * dwarf_ranges.c: New file.
1662 * Makefile.am (libdw_a_SOURCES): Add it.
1663 * libdw.h: Declare dwarf_ranges.
1664 * libdwP.h: Add INTDECL.
1665
Ulrich Drepperfbe998a2005-08-29 16:27:10 +000016662005-09-14 Roland McGrath <roland@redhat.com>
1667
1668 * dwarf_entry_breakpoints.c (dwarf_entry_breakpoints): Fix braino in
1669 prologue_end marker scanning loop.
1670
16712005-09-11 Roland McGrath <roland@redhat.com>
Roland McGrath71e15a02005-08-27 10:33:26 +00001672
1673 * dwarf.h: Comment typo fix.
1674
16752005-09-07 Roland McGrath <roland@redhat.com>
1676
1677 * dwarf_entry_breakpoints.c: New file.
1678 * Makefile.am (libdw_a_SOURCES): Add it.
1679 * libdw.h: Declare dwarf_entry_breakpoints.
1680
1681 * dwarf_entrypc.c: New file.
1682 * Makefile.am (libdw_a_SOURCES): Add it.
1683 * libdw.h: Declare dwarf_entrypc.
1684 * libdwP.h: Add INTDECL.
1685
16862005-08-28 Ulrich Drepper <drepper@redhat.com>
1687
1688 * Makefile.am: Use $(LINK) not $(CC) when creating DSO.
1689 (%.os): Use COMPILE.os.
1690 (COMPILE.os): Filter out gconv options.
1691
16922005-08-27 Roland McGrath <roland@redhat.com>
1693
Roland McGrathd17fac72005-08-23 08:20:21 +00001694 * dwarf_getscopes.c (dwarf_getscopes): Rewritten using
1695 __libdw_visit_scopes.
1696
1697 * dwarf_getscopes_die.c: New file.
1698 * Makefile.am (libdw_a_SOURCES): Add it.
1699 * libdw.h: Declare dwarf_getscopes_die.
1700 * libdw.map: Bump to 0.115 and add it.
1701
1702 * libdw_visit_scopes.c (__libdw_visit_scopes): Pass a struct
1703 containing a DIE and its parent pointer, instead of just Dwarf_Die.
1704 Take two functions for both preorder and postorder visitors.
1705 * libdwP.h: Update decl.
1706 (struct Dwarf_Die_Chain): New type.
1707 * dwarf_func_inline.c: Update uses.
1708
1709 * dwarf_diename.c (dwarf_diename): Use dwarf_attr_integrate.
1710 Add INTDEF.
Roland McGrathf5fda7d2005-08-18 22:01:57 +00001711 * libdwP.h: Add INTDECL.
1712 * dwarf_func_name.c (dwarf_func_name): Use dwarf_diename.
1713
17142005-08-23 Roland McGrath <roland@redhat.com>
1715
Roland McGrath1ecb6062005-08-15 09:53:04 +00001716 * dwarf_attr_integrate.c (dwarf_attr_integrate): Treat
1717 DW_AT_specification the same as DW_AT_abstract_origin.
1718
17192005-08-20 Roland McGrath <roland@redhat.com>
1720
1721 * libdw.map: Add dwfl_cumodule, remove dwfl_linecu.
1722 Add dwfl_linux_kernel_report_offline, dwfl_offline_section_address,
1723 and dwfl_report_offline.
1724
17252005-08-19 Roland McGrath <roland@redhat.com>
1726
1727 * libdw.map: Bump version to ELFUTILS_0.114 for libdwfl changes.
Roland McGrath1c83bf12005-08-11 07:03:55 +00001728 Add dwfl_module_relocate_address, dwfl_module_relocations,
Ulrich Drepper6d5c3bd2005-08-11 04:37:52 +00001729 dwfl_module_relocation_info.
Roland McGrath1c83bf12005-08-11 07:03:55 +00001730
17312005-08-18 Roland McGrath <roland@redhat.com>
Ulrich Drepper6d5c3bd2005-08-11 04:37:52 +00001732
Roland McGrath4959bf82005-08-09 10:31:08 +00001733 * dwarf_getscopes.c (dwarf_getscopes): Include the CU itself as
1734 outermost scope in the results.
Roland McGrathb6312e12005-08-09 10:36:01 +00001735
17362005-08-15 Roland McGrath <roland@redhat.com>
Roland McGrath4959bf82005-08-09 10:31:08 +00001737
1738 * dwarf_func_inline.c: New file.
1739 * Makefile.am (libdw_a_SOURCES): Add it.
1740 * libdw.h: Declare dwarf_func_inline, dwarf_func_inline_instances.
Roland McGratha5a89682005-08-02 01:24:01 +00001741 * libdw.map: Add them.
1742
1743 * dwarf_func_die.c: New file.
1744 * Makefile.am (libdw_a_SOURCES): Add it.
1745 * libdw.h: Declare dwarf_func_die.
Ulrich Drepper18618fd2005-07-28 21:29:22 +00001746 * libdw.map: Add it. Bump version to ELFUTILS_0.114.
1747
17482005-08-10 Ulrich Drepper <drepper@redhat.com>
1749
1750 * dwarf_getsrclines.c (dwarf_getsrclines): Correct fallout of renaming
Roland McGrath366784a2005-07-28 06:20:53 +00001751 of DW_LNS_set_epilog_begin.
1752
Roland McGrath18385902005-07-28 07:12:38 +000017532005-08-09 Roland McGrath <roland@redhat.com>
1754
1755 * dwarf.h (DW_LNS_set_epilog_begin): Renamed DW_LNS_set_epilogue_begin.
1756
1757 * dwarf_end.c: Add INTDEF.
1758 * dwarf_error.c (dwarf_errmsg): Likewise.
Roland McGrath366784a2005-07-28 06:20:53 +00001759 * libdwP.h (dwarf_end, dwarf_errmsg): Add INTDECLs.
1760
17612005-08-01 Roland McGrath <roland@redhat.com>
Ulrich Drepperb08d5a82005-07-26 05:00:05 +00001762
1763 * dwarf_getaranges.c (dwarf_getaranges): Check for bogus offset.
1764 * dwarf_getabbrev.c (__libdw_getabbrev): Likewise.
1765
17662005-07-28 Ulrich Drepper <drepper@redhat.com>
1767
1768 * Makefile.am (libdw.so): No need to link with libeu.a anymore.
1769 (libdw_a_LIBADD): Add all files from libdwfl.a.
1770
17712005-07-27 Roland McGrath <roland@redhat.com>
1772
1773 * Makefile.am (libdw.so): Link ../libdwfl/libdwfl_pic.a in,
1774 along with ../libebl/libebl.a and ../lib/libeu.a;
1775 depend on ../libelf/libelf.so.
1776 (libdw_so_LDADD): New variable.
1777 * libdw.map: Add dwfl_* symbols formerly in ../libdwfl/libdwfl.map.
1778
1779 * libdw.map: Define an empty base version and move all symbols to
1780 version ELFUTILS_0.111; don't define ELFUTILS_1.0 at all yet.
1781
17822005-07-23 Ulrich Drepper <drepper@redhat.com>
1783
1784 * dwarf_error.c: Add internal alias for dwarf_errno.
1785 * libdwP.h: Declare __dwarf_errno_internal.
1786 * dwarf_getloclist.c: Use INTDEF for dwarf_errno.
1787
1788 * dwarf_error.c [USE_TLS]: Actually use __thread in definition of
1789 global_error.
1790
17912005-06-01 Roland McGrath <roland@redhat.com>
1792
1793 * dwarf_getaranges.c (dwarf_getaranges): Sort result array.
1794 * dwarf_getarange_addr.c (dwarf_getarange_addr): Use binary search.
1795
17962005-06-08 Roland McGrath <roland@redhat.com>
1797
1798 * memory-access.h (get_uleb128_step, get_uleb128): Remove casts.
1799 (get_sleb128_step, get_sleb128): Likewise.
1800 * dwarf_getattrs.c (dwarf_getattrs): Add consts.
1801 * dwarf_getloclist.c (getloclist): Likewise.
1802 * dwarf_formblock.c (dwarf_formblock): Likewise.
1803 * dwarf_getsrclines.c (dwarf_getsrclines): Likewise.
1804 * dwarf_getabbrevattr.c (dwarf_getabbrevattr): Likewise.
1805 * dwarf_formref.c (dwarf_formref): Likewise.
1806 * dwarf_formsdata.c (dwarf_formsdata): Likewise.
1807 * dwarf_formudata.c (dwarf_formudata): Likewise.
1808 * dwarf_haschildren.c (dwarf_haschildren): Likewise.
1809 * dwarf_child.c (__libdw_find_attr, __libdw_find_attr): Likewise.
1810 * dwarf_tag.c (dwarf_tag): Likewise.
1811 * dwarf_getabbrev.c (__libdw_getabbrev): Likewise.
1812 * memory-access.c (__libdw_get_uleb128, __libdw_get_sleb128): Likewise.
1813 * libdw_form.c (__libdw_form_val_len): Likewise.
1814 * libdwP.h: Update decl.
1815
18162005-06-04 Roland McGrath <roland@redhat.com>
1817
1818 * memory-access.h (get_uleb128_rest_return): New macro.
1819 [! IS_LIBDW] (__libdw_get_uleb128): New static, defined using it.
1820 (get_sleb128_rest_return): New macro.
1821 [! IS_LIBDW] (__libdw_get_sleb128): New static, defined using it.
1822 * memory-access.c: New file.
1823 * Makefile.am (libdw_a_SOURCES): Add it.
1824 (DEFS): Add -DIS_LIBDW.
1825
18262005-05-31 Roland McGrath <roland@redhat.com>
1827
1828 * dwarf_formref_die.c (dwarf_formref_die): Add CU header offset to
1829 formref offset.
1830
18312005-05-30 Roland McGrath <roland@redhat.com>
1832
1833 * dwarf_getloclist.c (dwarf_addrloclists): Use DW_AT_entry_pc for base
1834 address if DW_AT_low_pc is missing. Not to spec, but GCC generates it.
1835
1836 * dwarf_getloclist.c (dwarf_addrloclists): Don't sign-extend 4-byte
1837 BEGIN value. Instead, match base address entries separately for
1838 32/64 size cases.
1839
18402005-05-28 Roland McGrath <roland@redhat.com>
1841
1842 * dwarf_getloclist.c (dwarf_addrloclists): Fix decoding to advance
1843 past location expression contents.
1844
18452005-05-23 Roland McGrath <roland@redhat.com>
1846
1847 * dwarf_getsrclines.c: Comment typo fix.
1848
1849 * dwarf_haspc.c (dwarf_haspc): Fix CU DIE address calculation.
1850 * dwarf_getloclist.c (dwarf_addrloclists): Likewise.
1851
18522005-05-22 Ulrich Drepper <drepper@redhat.com>
1853
1854 * libdwP.h: Only use INTDECL for alias prototypes.
1855
18562005-05-19 Roland McGrath <roland@redhat.com>
1857
1858 * dwarf_getloclist.c (attr_ok): Permit DW_AT_static_link too.
1859
1860 * dwarf_getscopevar.c: New file.
1861 * Makefile.am (libdw_a_SOURCES): Add it.
1862 * libdw.h: Declare dwarf_getscopevar.
1863
1864 * dwarf_getsrcfiles.c: Add INTDEF.
1865 * dwarf_haschildren.c: Likewise.
1866 * libdwP.h (dwarf_getsrcfiles, dwarf_haschildren): Add INTDECL.
1867
1868 * dwarf_getscopes.c: New file.
1869 * Makefile.am (libdw_a_SOURCES): Add it.
1870 * libdw.h: Declare dwarf_getscopes.
1871 * libdw.map: Add it.
1872
18732005-05-18 Roland McGrath <roland@redhat.com>
1874
1875 * libdwP.h (IDX_debug_ranges): New enum constant.
1876 * dwarf_begin_elf.c (dwarf_scnnames): Add it for ".debug_ranges".
1877 * libdwP.h (DWARF_E_NO_DEBUG_RANGES): New enum constant.
1878 * dwarf_error.c (errmsgs): Add it.
1879 * dwarf_haspc.c: New file.
1880 * libdw.h: Declare dwarf_haspc.
1881 * libdw.map: Add it.
1882 * libdwP.h: Add INTDECL.
1883
1884 * dwarf_attr_integrate.c: New file.
1885 * dwarf_hasattr_integrate.c: New file.
1886 * Makefile.am (libdw_a_SOURCES): Add them.
1887 * libdw.h: Declare dwarf_attr_integrate, dwarf_hasattr_integrate.
1888 * libdw.map: Add them.
1889
1890 * dwarf_hasattr.c: Add INTDEF.
1891 * libdwP.h: Add INTDECL for it.
1892
1893 * dwarf_formref_die.c: New file.
1894 * Makefile.am (libdw_a_SOURCES): Add it.
1895 * libdw.h (dwarf_formref_die): Declare it.
1896 * libdwP.h (dwarf_formref_die): Add INTDECL.
1897 * libdw.map: Add it.
1898
1899 * dwarf_getloclist.c (attr_ok, getloclist): New functions, broken out
1900 of ...
1901 (dwarf_getloclist): ... here. Call them.
1902 (dwarf_addrloclists): New function.
1903 * libdw.h: Declare it.
1904 * libdw.map: Add it.
1905
1906 * dwarf_getmacros.c (dwarf_getmacros): Don't bail at
1907 DW_MACINFO_end_file. Recognize type 0 as terminator.
1908
19092005-05-05 Roland McGrath <roland@redhat.com>
1910
1911 * dwarf_getsrc_die.c (dwarf_getsrc_die): Use binary search.
1912
1913 * dwarf_getsrclines.c (dwarf_getsrclines): Sort result array, since
1914 the line program does not produce all entries in ascending order.
1915
19162005-04-25 Ulrich Drepper <drepper@redhat.com>
1917
1918 * dwarf_getsrc_file.c (dwarf_getsrc_file): Handle multiple
1919 occurences (e.g., inlines) better.
1920
19212005-04-24 Ulrich Drepper <drepper@redhat.com>
1922
1923 * libdw.h (DWARF_END_ABBREV): Define.
1924 * dwarf_getabbrev.c (__libdw_getabbrev): Return DWARF_END_ABBREV if
1925 end is reached.
1926 * dwarf_offabbrev.c (dwarf_offabbrev): Return -1 on error, 1 if end
1927 of records reached.
1928 * dwarf_tag.c (__libdw_findabbrev): Also recognize DWARF_END_ABBREV
1929 as error of __libdw_getabbrev.
1930
19312005-04-04 Ulrich Drepper <drepper@redhat.com>
1932
1933 * dwarf_getsrc_file.c (dwarf_getsrc_file): Minor optimization.
1934
1935 * dwarf_getsrc_file.c (dwarf_getsrc_file): Always pass number of
1936 results back to caller.
1937
19382005-04-04 Roland McGrath <roland@redhat.com>
1939
1940 * dwarf_getsrc_file.c (dwarf_getsrc_file): Use size_t for CUHL.
1941
1942 * dwarf_func_line.c (__libdw_func_intval): Use internal_function in
1943 defn.
1944
19452005-04-04 Ulrich Drepper <drepper@redhat.com>
1946
1947 * dwarf_getsrc_file.c (dwarf_getsrc_file): Use INTUSE.
1948
1949 * dwarf_getsrc_file.c: New file.
1950 * Makefile.am (libdw_a_SOURCES): Add dwarf_getsrc_file.c.
1951 * libdw.h: Declare dwarf_getsrc_file.
1952 * libdw.map: Add dwarf_getsrc_file.
1953
19542005-04-02 Ulrich Drepper <drepper@redhat.com>
1955
1956 * dwarf_func_entrypc.c: New file.
1957 * dwarf_func_col.c: New file.
1958 * dwarf_func_line.c: New file.
1959 * dwarf_func_file.c: New file.
1960 * libdw.h: Add prototypes for new functions.
1961 * libdw.map: Add dwarf_func_entrypc, dwarf_func_col, dwarf_func_line,
1962 dwarf_func_file.
1963 * Makefile.am (libdw_a_SOURCES): Add dwarf_func_entrypc.c,
1964 dwarf_func_col.c, dwarf_func_line.c, dwarf_func_file.c.
1965 * libdwP.h (struct Dwarf_Func_s): Add cudie element.
1966 Declare __libdw_func_intval and __dwarf_formsdata_internal.
1967 * dwarf_getfuncs.c: Also fill in cudie in Dwarf_Func object.
1968 * dwarf_formsdata.c: Use INTUSE and INTDEF to avoid PLTs.
1969
1970 * dwarf.h: Add some DWARF3 definitions.
1971
19722005-04-01 Ulrich Drepper <drepper@redhat.com>
1973
1974 * dwarf_getfuncs.c: New file.
1975 * dwarf_func_highpc.c: New file.
1976 * dwarf_func_lowpc.c: New file.
1977 * dwarf_func_name.c: New file.
1978 * Makefile.am (libdw_a_SOURCES): Add dwarf_getfuncs.c,
1979 dwarf_func_highpc.c, dwarf_func_lowpc.c, and dwarf_func_name.c.
1980 * libdw.map: Add dwarf_getfuncs, dwarf_func_highpc, dwarf_func_lowpc,
1981 and dwarf_func_name.
1982 * libdw.h: Add prototypes for new functions.
1983 * dwarf_child.c: Use INTUSE and INTDEF to avoid PLTs.
1984 * dwarf_siblingof.c: Likewise.
1985 * dwarf_dieoffset.c: Likewise.
1986 * dwarf_highpc.c: Likewise.
1987 * dwarf_lowpc.c: Likewise.
1988 * libdwP.h: Add prototypes for internal functions.
1989 Define Dwarf_Func_s structure.
1990
19912005-03-29 Ulrich Drepper <drepper@redhat.com>
1992
1993 * libdw.h: Add padding in Dwarf_die.
1994
1995 * dwarf_arrayorder.c: Use INTUSE and INTDEF to avoid PLTs.
1996 * dwarf_attr.c: Likewise.
1997 * dwarf_begin.c: Likewise.
1998 * dwarf_begin_elf.c: Likewise.
1999 * dwarf_bitoffset.c: Likewise.
2000 * dwarf_bitsize.c: Likewise.
2001 * dwarf_bytesize.c: Likewise.
2002 * dwarf_diename.c: Likewise.
2003 * dwarf_formaddr.c: Likewise.
2004 * dwarf_formblock.c: Likewise.
2005 * dwarf_formref.c: Likewise.
2006 * dwarf_formstring.c: Likewise.
2007 * dwarf_formudata.c: Likewise.
2008 * dwarf_getarange_addr.c: Likewise.
2009 * dwarf_getarangeinfo.c: Likewise.
2010 * dwarf_getaranges.c: Likewise.
2011 * dwarf_getloclist.c: Likewise.
2012 * dwarf_getmacros.c: Likewise.
2013 * dwarf_getsrc_die.c: Likewise.
2014 * dwarf_getsrcfiles.c: Likewise.
2015 * dwarf_getsrclines.c: Likewise.
2016 * dwarf_highpc.c: Likewise.
2017 * dwarf_lowpc.c: Likewise.
2018 * dwarf_nextcu.c: Likewise.
2019 * dwarf_offdie.c: Likewise.
2020 * dwarf_siblingof.c: Likewise.
2021 * dwarf_srclang.c: Likewise.
2022 * dwarf_tag.c: Likewise.
2023 * libdw_findcu.c: Likewise.
2024 * libdwP.h: Add prototypes for internal functions.
2025
2026 * dwarf_addrdie.c: New file.
2027 * dwarf_macro_opcode.c: New file.
2028 * dwarf_macro_param1.c: New file.
2029 * dwarf_macro_param2.c: New file.
2030 * libdw.h: Add declarations. Move Dwarf_Macro definition to libdwP.h.
2031 * libdwP.h: Remove Dwarf_Macro definition.
2032 * Makefile.am (libdw_a_SOURCES): Add dwarf_addrdie.c,
2033 dwarf_macro_opcode.c, dwarf_macro_param1.c, and dwarf_macro_param2.c.
2034 * libdw.map: Add entries for new functions.
2035
20362005-03-21 Ulrich Drepper <drepper@redhat.com>
2037
2038 * libdw.h: Handle broken gcc < 4.
2039
20402005-02-15 Ulrich Drepper <drepper@redhat.com>
2041
2042 * Makefile (AM_CFLAGS): Add -Wunused -Wextra -Wformat=2.
2043
2044 * dwarf_begin_elf.c: Fix warnings.
2045 * dwarf_dieoffset.c: Likewise.
2046 * dwarf_end.c: Likewise.
2047 * dwarf_error.c: Likewise.
2048 * dwarf_getpubnames.c: Likewise.
2049
2050 * libdwP.h: Add new error values.
2051 * dwarf_error.c: Support new error values.
2052 * dwarf_getpubnames.c: Check parameter value.
2053
20542005-02-05 Ulrich Drepper <drepper@redhat.com>
2055
2056 * Makefile.am: Check for text relocations in constructed DSO.
2057
2058 * Makefile.am [MUDFLAP] (AM_CFLAGS): Add -fmudflap.
2059
20602005-02-04 Ulrich Drepper <drepper@redhat.com>
2061
2062 * dwarf_siblingof.c (dwarf_siblingof): Add some buffer boundary
2063 checks to not read over buffer boundaries for ill-formed DWARF data.
2064
20652004-09-25 Ulrich Drepper <drepper@redhat.com>
2066
2067 * dwarf_child.c: Make compile with gcc 4.0.
2068 * dwarf_error.c: Likewise.
2069 * dwarf_formblock.c: Likewise.
2070 * dwarf_getabbrev.c: Likewise.
2071 * dwarf_getattrs.c: Likewise.
2072 * dwarf_getsrclines.c: Likewise.
2073 * dwarf_tag.c: Likewise.
2074 * libdw_form.c: Likewise.
2075
20762004-01-20 Ulrich Drepper <drepper@redhat.com>
2077
2078 * Makefile.am: Support building with mudflap.
2079
2080 * dwarf_getloclist.c: Fix warnings gcc 3.4 spits out.
2081 * dwarf_getsrclines.c: Likewise.
2082 * dwarf_memory-access.h: Likewise.
2083
20842004-01-19 Ulrich Drepper <drepper@redhat.com>
2085
2086 * dwarf_getsrcfiles.c: Third parameter can be NULL.
2087
2088 * libdw.h: Define Dwarf_macro. Declare dwarf_getmacros.
2089 Third parameter of dwarf_getsrcfiles can be NULL.
2090
2091 * libdw.map: Add dwarf_getmacros.
2092 * Makefile.am (libdw_a_SOURCES): Add dwarf_getmacros.
2093 * dwarf_getmacros.c: New file.
2094
20952004-01-18 Ulrich Drepper <drepper@redhat.com>
2096
2097 * libdw.h: Second parameter of dwarf_getaranges can be NULL.
2098
2099 * dwarf_nextcu.c: Return -1 if dwarf parameter is NULL.
2100
2101 * dwarf_getsrclines.c:
2102 Use read_2ubyte_unaligned_inc instead of _inc-less variant.
2103
2104 * dwarf_getaranges.c: Allow naranges parameter to be NULL.
2105
2106 * libdwP.h (_): Use elfutils domain.
2107
2108 * dwarf_getsrclines.c (dwarf_getsrclines): Add more branch prediction.
2109
2110 * dwarf_getsrclines.c: Fix typo in comment.
2111
21122004-01-17 Ulrich Drepper <drepper@redhat.com>
2113
2114 * Makefile.am: Support building with mudflap.
2115
21162004-01-16 Ulrich Drepper <drepper@redhat.com>
2117
2118 * memory-access.h: Add lots of const in case a pointer passed is const.
2119
2120 * dwarf_formflag.c: New file.
2121 * dwarf_getattrs.c: New file.
2122 * dwarf_error.c: Add new error value.
2123 * libdw.h: Add prototypes for new functions. Adjust prototype for
2124 dwarf_getpubnames.
2125 * libdw.map: Add new functions.
2126 * dwarf_getpubnames.c: Change type of return value and fourth parameter
2127 to ptrdiff_t.
2128 * libdwP.h: Add new error value.
2129 * Makefile.am (libdw_a_SOURCES): Add dwarf_getattrs.c and
2130 dwarf_formflag.c.
2131
2132 * dwarf_getpubnames.c (dwarf_getpubnames): Just fail if dbg is NULL.
2133
21342004-01-12 Ulrich Drepper <drepper@redhat.com>
2135
2136 * dwarf_getarange_addr.c: New file
2137 * dwarf_getarangeinfo.c: New file.
2138 * dwarf_getaranges.c: New file.
2139 * dwarf_onerange.c: New file.
2140 * libdw.h: Declare new functions. Define Dwarf_Arange and
2141 Dwarf_Aranges.
2142 * libdw.map: Add new functions.
2143 * libdwP.h: Add new errors. Add aranges member to struct Dwarf.
2144 Define Dwarf_Aranges_s and Dwarf_Arange_s.
2145 * Makefile.am (libdw_a_SOURCES): Add dwarf_getaranges.c,
2146 dwarf_onearange.c, dwarf_getarangeinfo.c, dwarf_getarange_addr.c.
2147 * dwarf_error.c: Add new message.
2148
21492004-01-11 Ulrich Drepper <drepper@redhat.com>
2150
2151 * Makefile.am (libdw_a_SOURCES): Add dwarf_lineaddr.c, dwarf_linecol.c,
2152 dwarf_linebeginstatement.c, dwarf_lineendsequence.c, dwarf_lineblock.c,
2153 dwarf_lineprologueend.c, dwarf_lineepiloguebegin.c, dwarf_onesrcline.c.
2154 * dwarf_error.c: Add another message.
2155 * dwarf_getsrc_die.c: Adjust for Dwarf_Files and Dwarf_Lines
2156 introduction.
2157 * dwarf_filesrc.c: Likewise.
2158 * dwarf_getsrcfiles.c: Likewise.
2159 * dwarf_getsrclines.c: Likewise.
2160 * dwarf_lineaddr.c: New file.
2161 * dwarf_linebeginstatement.c: New file.
2162 * dwarf_lineblock.c: New file.
2163 * dwarf_linecol.c: New file.
2164 * dwarf_lineendsequence.c: New file.
2165 * dwarf_lineepiloguebegin.c: New file.
2166 * dwarf_lineno.c: New file.
2167 * dwarf_lineprologueend.c: New file.
2168 * dwarf_onesrcline.c: New file.
2169 * dwarf_lineno.c: Change interface to store result in object pointed
2170 to by second parameter.
2171 * libdw.h: Add prototypes for new functions. Change dwarf_lineno
2172 prototype. Define Dwarf_Files and Dwarf_Lines.
2173 * libdw.map: Add new functions.
2174 * libdwP.h: Define Dwarf_Files_s and Dwarf_Lines_s.
2175 * libdw_findcu.c: Don't initialize nlines field.
2176
2177 * dwarf_siblingof: Little optimization.
2178
2179 * dwarf_begin.c: Remember that the ELF descriptor must be closed.
2180 * dwarf_end.c: Close ELF descriptor if free_elf is set.
2181 * libdwP.h (struct Dwarf): Add free_elf field.
2182
2183 * Makefile.am (libdw_a_SOURCES): Add dwarf_getstring.c and
2184 dwarf_offabbrev.c.
2185 * dwarf_getstring.c: New file.
2186 * dwarf_offabbrev.c: New file.
2187 * libdw.map: Add dwarf_getstring and dwarf_offabbrev.
2188 * dwarf_getabbrev.c (__libdw_getabbrev): Add new dbg and result
2189 parameters. Don't allocate memory if not necessary and don't lookup
2190 previous results if no CU given.
2191 (dwarf_getabbrev): Adjust call to __libdw_getabbrev.
2192 * dwarf_tag.c: Adjust call to __libdw_getabbrev.
2193 * libdw.h: Declare dwarf_offabbrev and dwarf_getstring.
2194 * libdwP.h: Change prototype for __libdw_getabbrev.
2195
2196 * dwarf_getabbrevattr.c: Add offsetp parameter. Fill in before
2197 returning if this is wanted.
2198
21992004-01-09 Ulrich Drepper <drepper@redhat.com>
2200
2201 * dwarf_nextcu.c: Add new parameter offset_sizep. Initialize it
2202 with offset_size value.
2203 * libdw.h: Adjust dwarf_nextcu prototype.
2204 * libdwP.h (struct Dwarf_CU): Add offset_size member.
2205 * libdw_findcu.c: Adjust dwarf_nextcu call. Initialize offset_size
2206 member of new CU struct.
2207 * dwarf_formstring.c: Depend on offset_size not address_size for
2208 DW_FORM_strp handling.
2209 * dwarf_form.c: Likewise for DW_FORM_strp and DW_FORM_ref_addr.
2210
2211 * dwarf_tag.c (__libdw_findabbrev): Return correct value for
2212 failing lookup.
2213 (dwarf_tag): Correctly recognize failed lookup.
2214
2215 * dwarf_end.c (cu_free): Call tdestroy for locs member. Use new
2216 function noop_free.
2217 * dwarf_error.c: Add message for DWARF_E_NO_BLOCK.
2218 * dwarf_formblock.c: New file.
2219 * dwarf_getloclist.c: Rewrite to handle a single block.
2220 * libdw.h: Define Dwarf_Block. Rename Dwarf_Loc members. Remove
2221 Dwarf_Locdesc definition. Declare dwarf_formblock. Remove
2222 dwarf_getloclistent declaration.
2223 * libdw.map: Add dwarf_formblock, remove dwarf_getloclistent.
2224 * libdwP.h: Define struct loc_s and DWARF_E_NO_BLOCK.
2225 Add locs member to struct Dwarf_CU.
2226 * libdw_fundcu.c: Initialize locs member of new CU.
2227 * Makefile.am (libdw_a_SOURCES): Add dwarf_formblock.c.
2228 Remove dwarf_getloclistent.c.
2229
22302004-01-07 Ulrich Drepper <drepper@redhat.com>
2231
2232 * libdw.h: Use __nonnull__ attribute only for gcc >= 3.3.
2233 * libdwP.h: Likewise.
2234
2235 * dwarf_getloclist.c: New file.
2236 * dwarf_getloclistent.c: New file.
2237 * libdw.h: Define Dwarf_Loc and Dwarf_Locdesc.
2238 Declare dwarf_getloclistent and dwarf_getloclist.
2239 * libdw.map: Add dwarf_getloclistent and dwarf_getloclist.
2240 * libdwP.h: Define DWARF_E_NO_LOCLIST.
2241 * Makefile.am (libdw_a_SOURCES): Add dwarf_getloclistent.c and
2242 dwarf_getloclist.c.
2243
2244 * dwarf_error.c: More error messages.
2245
22462004-01-06 Ulrich Drepper <drepper@redhat.com>
2247
2248 * dwarf_getsrclines.c: Remove debugging support.
2249
2250 * dwarf_getsrcfiles.c: New file.
2251 * dwarf_filesrc.c: New file.
2252 * libdw.h: Declare these functions. Define Dwarf_File.
2253 * libdwP.c: Adjust Dwarf_File_s definition.
2254 * libdw.map: Add these functions.
2255 * Makefile.am (libdw_a_SOURCES): Add dwarf_getsrcfiles.c and
2256 dwarf_filesrc.c.
2257 * dwarf_getsrclines.c: Initialize cu->files.
2258
22592004-01-05 Ulrich Drepper <drepper@redhat.com>
2260
2261 * libdw.h: Add more nonnull function attributes.
2262
2263 * dwarf_begin_elf.c (dwarf_begin_elf): Don't initialize mem_tail->next.
2264 * dwarf_end.c (cu_free): New function.
2265 (dwarf_end): Also free CU tree. Correct freeing of memory blocks.
2266 * dwarf_error.c (errmsgs): Add new messages.
2267 * dwarf_getsrc_die.c: New file.
2268 * dwarf_getsrclines.c: New file.
2269 * dwarf_lineno.c: New file.
2270 * dwarf_linesrc.c: New file.
2271 * dwarf_nextcu.c (dwarf_nextcu): Use read_*byte_unaligned_inc
2272 instead of the *_inc-less variants.
Ulrich Drepper6fb34512010-05-28 20:28:04 -07002273 * libdw.h: Define Dwarf_Line. Add some function attributes. Declare
Ulrich Drepperb08d5a82005-07-26 05:00:05 +00002274 dwarf_getsrclines, dwarf_getsrc_die, dwarf_lineno, and dwarf_linesrc.
2275 * libdw.map: Add dwarf_getsrclines, dwarf_getsrc_die, dwarf_lineno,
2276 and dwarf_linesrc.
2277 * libdwP.h: Add more error codes.
2278 (struct Dwarf): Remove mem_tail.next member.
2279 (Dwarf_File): Define type.
2280 (struct Dwarf_Line_s): Define type.
2281 (struct Dwarf_CU): Add lines and nlines members.
2282 (libdw_alloc): Define local variable _tail and use it.
2283 Add some function attributes.
2284 * libdw_alloc.c (__libdw_allocate): Don't initialize next member.
2285 * libdw_findcu.c (__libdw_findcu): Initialize lines and nlines members.
2286 * memory-access.h: Add unlikely for the endian conversion paths.
2287 * Makefile.am (AM_CFLAGS): Add -std parameter.
2288 (libdw_a_SOURCES): Add dwarf_getsrclines, dwarf_getsrc_die,
2289 dwarf_lineno, and dwarf_linesrc.
2290
22912003-08-11 Ulrich Drepper <drepper@redhat.com>
2292
2293 * Moved to CVS archive.