From: Fangrui Song Date: Thu, 31 Dec 2020 18:04:21 +0000 (-0800) Subject: [ThinLTO] Default -enable-import-metadata to false X-Git-Tag: llvmorg-13-init~2308 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=a90b42b0fec618124a3ed573ecd0e192a61815f7;p=platform%2Fupstream%2Fllvm.git [ThinLTO] Default -enable-import-metadata to false The default value is dependent on `-DLLVM_ENABLE_ASSERTIONS={off,on}` (D22167), which is error-prone. The few tests checking `!thinlto_src_module` can specify -enable-import-metadata explicitly. Reviewed By: tejohnson Differential Revision: https://reviews.llvm.org/D93959 --- diff --git a/llvm/lib/Transforms/IPO/FunctionImport.cpp b/llvm/lib/Transforms/IPO/FunctionImport.cpp index 3015a5f..1834303 100644 --- a/llvm/lib/Transforms/IPO/FunctionImport.cpp +++ b/llvm/lib/Transforms/IPO/FunctionImport.cpp @@ -124,14 +124,8 @@ static cl::opt ComputeDead("compute-dead", cl::init(true), cl::Hidden, cl::desc("Compute dead symbols")); static cl::opt EnableImportMetadata( - "enable-import-metadata", cl::init( -#if !defined(NDEBUG) - true /*Enabled with asserts.*/ -#else - false -#endif - ), - cl::Hidden, cl::desc("Enable import metadata like 'thinlto_src_module'")); + "enable-import-metadata", cl::init(false), cl::Hidden, + cl::desc("Enable import metadata like 'thinlto_src_module'")); /// Summary file to use for function importing when using -function-import from /// the command line.