[LLVMbugs] [Bug 815] NEW: Build LLVM with -fno-exceptions and -fno-rtti

bugzilla-daemon at cs.uiuc.edu bugzilla-daemon at cs.uiuc.edu
Mon Jul 3 09:56:02 PDT 2006


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

           Summary: Build LLVM with -fno-exceptions and -fno-rtti
           Product: Build scripts
           Version: cvs
          Platform: Macintosh
        OS/Version: MacOS X
            Status: NEW
          Severity: enhancement
          Priority: P2
         Component: Makefiles
        AssignedTo: unassignedbugs at nondot.org
        ReportedBy: sabre at nondot.org


EH info is responsible for about 20% of the footprint of LLVM and RTTI info is about 5% of the footprint.  
It would obviously be nice to eliminate this.  :)

I propose that we change the LLVM makefiles to default to -fno-rtti -fno-exceptions, unless 
LLVM_USES_RTTI=1 or LLVM_USES_EXCEPTIONS=1 is specified.  This way we have those directories that 
use RTTI and Exceptions explicitly marked, and can systematically reduce the number of places the 
uses exceptions.  libsupport, f.e., only uses exceptions in a couple of .o files.  Since huge chunks of 
llvm don't use exceptions today (e.g. the transformations, code generator, and targets), so this will be a 
big win without changing anything.

In pratice, we probably want to do this in two steps: first with exceptions, then with RTTI.  RTTI is 
currently used by the pass manager, so all llvm passes use RTTI implicitly.  I will fix this next week, at 
which point we can start using disabling RTTI.

-Chris



------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.



More information about the llvm-bugs mailing list