-
Notifications
You must be signed in to change notification settings - Fork 15.2k
Description
| Bugzilla Link | 797 |
| Resolution | FIXED |
| Resolved on | Feb 22, 2010 12:47 |
| Version | 1.0 |
| OS | All |
| Reporter | LLVM Bugzilla Contributor |
| CC | @lattner |
Extended Description
We might be able to reduce the size of libVMCore.a by compiling it with the
-fno-exceptions flag. This prevents the compiler from generating functions that
know how to propagate exceptions. VMCore is very close to being exception
handling free. With a little work, we could make it exception free and turn
this flag on permanently in the lib/VMCore/Makefile.
Here are the outstanding issues:
Pass.cpp in the constructor of FunctionPass needs to handle exceptions coming
from the bytecode reader when its function is materialized. Possible solutions:
- Don't have bytecode reader throw exceptions (big change). This actually
implies that any ModuleProvider would not be able to throw exceptions. - Move Pass.cpp out of VMCore
- Rearrange the code so that Pass.cpp is not the thing doing the function
materialization.
Verifier.cpp throws an exception when it checks abortIfBroken(). This is a
feature used by the bcanalyzer and llvm-as. Both programs could be made to just
abort if the verifier fails.
The libraries VMCore depends upon (Support, bzip2, System) do not throw in
anything that VMCore includes or calls.
Since VMCore has a lot of functions, this could be a big win for library size.