[LLVMbugs] [Bug 5334] New: Implement feature to allow easy manipulation of inlining

bugzilla-daemon at cs.uiuc.edu bugzilla-daemon at cs.uiuc.edu
Wed Oct 28 16:56:42 PDT 2009


http://llvm.org/bugs/show_bug.cgi?id=5334

           Summary: Implement feature to allow easy manipulation of inlining
           Product: tools
           Version: trunk
          Platform: PC
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: llvm-g++
        AssignedTo: unassignedbugs at nondot.org
        ReportedBy: daniel at zuster.org
                CC: evan.cheng at apple.com, gohman at apple.com,
                    llvmbugs at cs.uiuc.edu, bob.wilson at apple.com


When investigation codegen performance on large C++ apps (i.e. Clang) it is
very difficult to compare the LLVM results to GCC, particularly due to
inlining.

I propose we implement a new flag backend flag (only for debugging and most
certainly not documented) --inline-override-file=PATH which would be an input
of the form ({+,-}SYMBOLNAME)*, e.g.,
--
+foo
-bar
...
--
where +foo would mean that any symbol named foo would get marked as
always_inline, and -bar would mean to mark any symbol named bar as noinline. We
could make foo and bar regexps.

The idea is that the the user can make one such file and tweak the build system
to pass it to llvm-gcc (using -mllvm). Given binaries produced by gcc and
llvm-gcc, it should be possible to semi-automatically produce an inline
override file which will cause the llvm-gcc binary to more closely match gcc.
The idea would be to add any symbol present in the gcc binary and not the
llvm-gcc binary as a noinline symbol and any symbol present in the llvm-gcc
binary and not the gcc binary as an always_inline symbol.

Assuming this worked, it would allow more direct comparison of the binaries
with standard performance tools, and would help isolating various codegen
problem from performance differences due to different inlining choices.


-- 
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