diff options
author | Igor Murashkin <iam@google.com> | 2014-10-16 18:36:16 -0700 |
---|---|---|
committer | Igor Murashkin <iam@google.com> | 2014-10-16 18:36:16 -0700 |
commit | d6dee676acdd1ab0aa4e5ba6834ee7c40a6dd8ab (patch) | |
tree | 727a86edd5ecbcdf60639b5dff5490e9573b5b56 /compiler/driver/compiler_options.h | |
parent | 58e51f38e2304a08aa9ec380383e0b3614f96a96 (diff) |
dex2oat: Add a --compile-pic option
Change-Id: I80e03613e3b6ac079bcbc7e068bbaae760c364c9
Diffstat (limited to 'compiler/driver/compiler_options.h')
-rw-r--r-- | compiler/driver/compiler_options.h | 17 |
1 files changed, 13 insertions, 4 deletions
diff --git a/compiler/driver/compiler_options.h b/compiler/driver/compiler_options.h index eb3de975d2..3a50bfdb83 100644 --- a/compiler/driver/compiler_options.h +++ b/compiler/driver/compiler_options.h @@ -28,7 +28,7 @@ class CompilerOptions { kBalanced, // Try to get the best performance return on compilation investment. kSpeed, // Maximize runtime performance. kEverything, // Force compilation (Note: excludes compilation of class initializers). - kTime // Compile methods, but minimize compilation time. + kTime, // Compile methods, but minimize compilation time. }; // Guide heuristics to determine whether to compile method if profile data not available. @@ -59,7 +59,8 @@ class CompilerOptions { include_debug_symbols_(kDefaultIncludeDebugSymbols), implicit_null_checks_(false), implicit_so_checks_(false), - implicit_suspend_checks_(false) + implicit_suspend_checks_(false), + compile_pic_(false) #ifdef ART_SEA_IR_MODE , sea_ir_mode_(false) #endif @@ -77,7 +78,8 @@ class CompilerOptions { bool include_debug_symbols, bool implicit_null_checks, bool implicit_so_checks, - bool implicit_suspend_checks + bool implicit_suspend_checks, + bool compile_pic #ifdef ART_SEA_IR_MODE , bool sea_ir_mode #endif @@ -94,7 +96,8 @@ class CompilerOptions { include_debug_symbols_(include_debug_symbols), implicit_null_checks_(implicit_null_checks), implicit_so_checks_(implicit_so_checks), - implicit_suspend_checks_(implicit_suspend_checks) + implicit_suspend_checks_(implicit_suspend_checks), + compile_pic_(compile_pic) #ifdef ART_SEA_IR_MODE , sea_ir_mode_(sea_ir_mode) #endif @@ -197,6 +200,11 @@ class CompilerOptions { return include_patch_information_; } + // Should the code be compiled as position independent? + bool GetCompilePic() const { + return compile_pic_; + } + private: CompilerFilter compiler_filter_; size_t huge_method_threshold_; @@ -212,6 +220,7 @@ class CompilerOptions { bool implicit_null_checks_; bool implicit_so_checks_; bool implicit_suspend_checks_; + bool compile_pic_; #ifdef ART_SEA_IR_MODE bool sea_ir_mode_; #endif |