mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-02-22 13:32:09 +00:00
Fix PR637
llvm-svn: 23784
This commit is contained in:
parent
d21885e6c9
commit
fb0fa6792e
@ -216,12 +216,10 @@ int llvm::GenerateBytecode(Module *M, int StripLevel, bool Internalize,
|
||||
addPass(Passes, createFunctionResolvingPass());
|
||||
|
||||
if (!DisableOptimizations) {
|
||||
if (Internalize) {
|
||||
// Now that composite has been compiled, scan through the module, looking
|
||||
// for a main function. If main is defined, mark all other functions
|
||||
// internal.
|
||||
addPass(Passes, createInternalizePass());
|
||||
}
|
||||
// Now that composite has been compiled, scan through the module, looking
|
||||
// for a main function. If main is defined, mark all other functions
|
||||
// internal.
|
||||
addPass(Passes, createInternalizePass(Internalize));
|
||||
|
||||
// Now that we internalized some globals, see if we can hack on them!
|
||||
addPass(Passes, createGlobalOptimizerPass());
|
||||
|
@ -111,12 +111,10 @@ void Optimize(Module* M) {
|
||||
addPass(Passes, createFunctionResolvingPass());
|
||||
|
||||
if (!DisableOptimizations) {
|
||||
if (!DisableInternalize) {
|
||||
// Now that composite has been compiled, scan through the module, looking
|
||||
// for a main function. If main is defined, mark all other functions
|
||||
// internal.
|
||||
addPass(Passes, createInternalizePass());
|
||||
}
|
||||
// Now that composite has been compiled, scan through the module, looking
|
||||
// for a main function. If main is defined, mark all other functions
|
||||
// internal.
|
||||
addPass(Passes, createInternalizePass(!DisableInternalize));
|
||||
|
||||
// Now that we internalized some globals, see if we can hack on them!
|
||||
addPass(Passes, createGlobalOptimizerPass());
|
||||
|
Loading…
x
Reference in New Issue
Block a user