[PATCH] libdw: Add overflow checking to __libdw_form_val_len.
Josh Stone
jistone at redhat.com
Wed Dec 10 02:44:48 UTC 2014
On 12/07/2014 05:23 PM, Petr Machata wrote:
> Josh Stone <jistone at redhat.com> writes:
>
>> I'll see if I can grab that old kernel debuginfo to do a more direct
>> comparison.
>
> You could grab the old code and compare that. If you're still in the
> 80's, it's the data, not the code.
Ok, well my former optimizations went into 0.158. Here are some quick
runs of "varlocs -k >/dev/null" on kernel-3.17.4-301.fc21.x86_64:
0.157 96.00user 0.12system 1:36.08elapsed
0.158 70.22user 0.12system 1:10.32elapsed
0.159 71.40user 0.11system 1:11.48elapsed
0.160 73.24user 0.12system 1:13.33elapsed
master 77.65user 0.10system 1:17.72elapsed
patched 77.87user 0.10system 1:17.93elapsed
So each release has ceded a bit of performance, but this particular
patch isn't much of an issue. Correctness trumps performance anyway.
For fun, here are the counts from dwgrep -e 'entry attribute form':
3.11.9-300.fc20.x86_64/vmlinux:
2 DW_FORM_block2
252 DW_FORM_block1
24975 DW_FORM_data4
182227 DW_FORM_data8
259701 DW_FORM_sdata
330195 DW_FORM_addr
387491 DW_FORM_sec_offset
537586 DW_FORM_exprloc
558135 DW_FORM_string
1397719 DW_FORM_flag_present
3353170 DW_FORM_data2
5220907 DW_FORM_strp
9263689 DW_FORM_ref4
13543053 DW_FORM_data1
3.17.4-301.fc21.x86_64/vmlinux:
2 DW_FORM_block2
256 DW_FORM_block1
26740 DW_FORM_data4
112315 DW_FORM_exprloc
197526 DW_FORM_data8
213497 DW_FORM_sec_offset
340039 DW_FORM_sdata
358462 DW_FORM_addr
641163 DW_FORM_string
1578298 DW_FORM_flag_present
3857598 DW_FORM_data2
6023993 DW_FORM_strp
10463444 DW_FORM_ref4
15532042 DW_FORM_data1
Also .text size grew from 10082549 to 11513127.
So it's all bigger, but roughly proportional.
More information about the elfutils-devel
mailing list