[Bug libc/24268] bench-ffsll performance degradation on glibc 2.29
kangshan0910 at hotmail dot com
sourceware-bugzilla@sourceware.org
Thu Feb 28 05:28:00 GMT 2019
https://sourceware.org/bugzilla/show_bug.cgi?id=24268
--- Comment #2 from Shan <kangshan0910 at hotmail dot com> ---
Thanks for your quick response. I tried perf to collect the performance data,
the cache miss is very little and the cycle counts are like the following.
With the commit
Samples: 40K of event 'cycles', Event count (approx.): 46652464962
Children Samples Command Shared Object Symbol
42.00% 17166 bench-ffsll libc-2.28.so [.] ffsll
23.90% 9766 bench-ffsll bench-ffsll [.] main
Samples: 40K of event 'cycles', 4000 Hz, Event count (approx.): 46652464962
ffsll /usr/lib64/haswell/libc-2.28.so [Percent: local period]
Percent│
│
│
│ Disassembly of section .text:
│
│ 00000000000a07f0 <ffsll@@GLIBC_2.2.5>:
24.81 │ endbr64
│ mov $0xffffffff,%edx
│ bsf %rdi,%rax
50.39 │ cmove %rdx,%rax
0.36 │ inc %eax
24.45 │ ← retq
Witout the commit
Samples: 40K of event 'cycles', Event count (approx.): 46691907747
Children Samples Command Shared Object Symbol
34.97% 14297 bench-ffsll libc-2.28.so [.] ffsll
26.78% 10932 bench-ffsll bench-ffsll [.] main
Samples: 40K of event 'cycles', 4000 Hz, Event count (approx.): 46691907747
ffsll /usr/lib64/haswell/libc-2.28.so [Percent: local period]
Percent│
│
│
│ Disassembly of section .text:
│
│ 00000000000a0310 <ffsll@@GLIBC_2.2.5>:
33.00 │ endbr64
0.04 │ mov $0xffffffff,%edx
0.10 │ bsf %rdi,%rax
0.12 │ cmove %rdx,%rax
33.93 │ inc %eax
32.81 │ ← retq
I also suspected that it was caused by the libc binary layout change. But I
failed to prove that. Do you have any suggestions?
--
You are receiving this mail because:
You are on the CC list for the bug.
More information about the Glibc-bugs
mailing list