Refactor SourceInfo into Source.
A Script object is associated with a Source object (HAS-A relation.)
A Source object describes the source code (more specifically, the LLVM
module) that is going to be compiled.
BCCContext contains the context used in a Source object.
BCCContext is now managed by the user not the libbcc itself. That is,
user should supply the context object when they create a Source object.
Change-Id: Icb8980d6f15cf30aa0415e69e3ae585d990dc156
diff --git a/lib/ExecutionEngine/CompilerOption.h b/lib/ExecutionEngine/CompilerOption.h
index 75278c7..f7c1e50 100644
--- a/lib/ExecutionEngine/CompilerOption.h
+++ b/lib/ExecutionEngine/CompilerOption.h
@@ -82,6 +82,9 @@
CodeModelOpt = llvm::CodeModel::Small;
#endif
+ //-- Run LTO passes --//
+ RunLTO = true;
+
//-- Load the result object after successful compilation --//
LoadAfterCompile = true;
}
@@ -89,6 +92,7 @@
llvm::TargetOptions TargetOpt;
llvm::CodeModel::Model CodeModelOpt;
llvm::Reloc::Model RelocModelOpt;
+ bool RunLTO;
bool LoadAfterCompile;
};