Chromium Code Reviews| Index: build/common.gypi |
| diff --git a/build/common.gypi b/build/common.gypi |
| index e84856a9512bfbb7c2ce67d9b649f5951c833cde..424c2617140c32ee466d3fb2a20639cb1f6b5d4d 100644 |
| --- a/build/common.gypi |
| +++ b/build/common.gypi |
| @@ -3005,12 +3005,6 @@ |
| ['v8_use_external_startup_data==1', { |
| 'defines': ['V8_USE_EXTERNAL_STARTUP_DATA'], |
| }], |
| - ['use_lto==1 and (target_arch=="ia32" or target_arch=="x64")', { |
| - # Required for third_party/zlib/crc_folding.c and various other code |
| - # that uses SSE. TODO(pcc): Remove this once we properly support |
| - # subtarget specific code generation in LLVM. |
| - 'ldflags': ['-Wl,-plugin-opt,mcpu=corei7-avx'], |
| - }], |
| ], # conditions for 'target_defaults' |
| 'target_conditions': [ |
| ['<(use_libpci)==1', { |
| @@ -5941,6 +5935,41 @@ |
| ], |
| }, |
| }], |
| + ['use_lto==1 and clang==1 and (target_arch=="ia32" or target_arch=="x64")', { |
| + 'target_defaults': { |
| + 'target_conditions': [ |
| + # Required for third_party/zlib/crc_folding.c and various other code |
| + # that uses SSE. TODO(pcc): Remove this once we properly support |
| + # subtarget specific code generation in LLVM. |
| + ['_toolset=="target"', { |
| + 'ldflags': [ |
| + '-Wl,-plugin-opt,mcpu=corei7-avx', |
| + ], |
| + }], |
| + ['_toolset=="target" and _type!="static_library"', { |
| + 'xcode_settings': { |
| + 'OTHER_LDFLAGS': [ |
| + '-Wl,-mcpu,corei7-avx', |
| + ], |
| + }, |
| + }], |
| + ], |
| + }, |
| + }], |
| + ['use_lto==1 and clang==1 and target_arch=="arm"', { |
| + 'target_defaults': { |
| + 'target_conditions': [ |
| + ['_toolset=="target"', { |
| + # Without this flag, LTO produces a .text section that is larger |
| + # than the maximum call displacement, preventing the linker from |
|
Nico
2015/03/21 03:48:23
Huh, shouldn't this work without special linker fl
pcc
2015/03/23 18:17:43
Done.
|
| + # relocating calls. |
| + 'ldflags': [ |
| + '-Wl,-plugin-opt,-function-sections', |
| + ], |
| + }], |
| + ], |
| + }, |
| + }], |
| ['(use_lto==1 or use_lto_o2==1) and clang==0', { |
| 'target_defaults': { |
| 'target_conditions': [ |