http://llvm.org/bugs/show_bug.cgi?id=20154
Bug ID: 20154
Summary: LLVM fails to inline/clone recursive function, leading
to 3x slowdown compared to gcc
Product: libraries
Version: trunk
Hardware: PC
OS: Linux
Status: NEW
Severity: normal
Priority: P
Component: Interprocedural Optimizations
Assignee: [email protected]
Reporter: [email protected]
CC: [email protected]
Classification: Unclassified
Created attachment 12716
--> http://llvm.org/bugs/attachment.cgi?id=12716&action=edit
test case
The attached (big test case) when compiled with trunk clang doesnt have
cpu_search() function inlined (or cloned?) into its callers even when marked
always_inline.
This is because the function is (indirectly) recursive. When compiling the same
file with gcc49, the cpu_search function is inlined.
This file is implementation of scheduler from FreeBSD and as reported
(https://kib.kiev.ua/kib/pgsql_perf.pdf) inlining it results in massive
improvement in performance (25% -> 8%).
--
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
LLVMbugs mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/llvmbugs