[LLVMbugs] [Bug 6009] New: Improved switch conversion
bugzilla-daemon at cs.uiuc.edu
bugzilla-daemon at cs.uiuc.edu
Tue Jan 12 04:31:29 PST 2010
http://llvm.org/bugs/show_bug.cgi?id=6009
Summary: Improved switch conversion
Product: new-bugs
Version: 2.6
Platform: PC
OS/Version: Windows XP
Status: NEW
Keywords: code-quality
Severity: normal
Priority: P2
Component: new bugs
AssignedTo: unassignedbugs at nondot.org
ReportedBy: bearophile at mailas.com
CC: llvmbugs at cs.uiuc.edu
<baldrick> on the IRC channel has suggested me to put this here, despite this
doesn't come from a performance problem in real code (usually I report things
here after I have seen an actual performance problem in some of my code).
In the attach there's a small C program, compiled with gcc 4.3, gcc 4.4 and
llvm-gcc 2.6, it shows an improvement in the compilation of switch tables done
by gcc 4.4 and absent in llvm 2.6.
It looks like a cute optimization, but:
1) It's easy to manually do this optimization (using a constant mapping array
that generally doesn't start from index 0, shifting the starting pointer)
2) I don't think this situation happens often enough in real code.
--
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
More information about the llvm-bugs
mailing list