diff options
author | evan@chromium.org <evan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-02-23 19:10:51 +0000 |
---|---|---|
committer | evan@chromium.org <evan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-02-23 19:10:51 +0000 |
commit | 987a742097b07657c50f97849c1550efbf7a548b (patch) | |
tree | 9ea8ec9dca6d02c472ca477c51ee8413a2958d65 /build | |
parent | f52a0729191ddef51bfa54aec61a3cc0083e2570 (diff) | |
download | chromium_src-987a742097b07657c50f97849c1550efbf7a548b.zip chromium_src-987a742097b07657c50f97849c1550efbf7a548b.tar.gz chromium_src-987a742097b07657c50f97849c1550efbf7a548b.tar.bz2 |
linux: don't instrument mmx functions
Shadow stacks use -finstrument-functions to hook all function entry/exit.
But mmx-related functions expect to be inlined so the compiler can
compile them out into mmx instructions.
This change excludes the mmx intrinsics header file from instrumentation.
Without it, builds wil fail with errors like the following:
../../third_party/gold/gold64: obj/media/libyuv_convert.a(obj/media/base/yuv_convert.yuv_convert.o): in function media::EmptyRegisterState():yuv_convert.cc(.text._ZN5media18EmptyRegisterStateEv+0x29): error: undefined reference to '_mm_empty()'
(_mm_empty() is an mmx intrinsic function.)
Review URL: http://codereview.chromium.org/9416068
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@123289 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'build')
-rw-r--r-- | build/common.gypi | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/build/common.gypi b/build/common.gypi index fa82663..cede6f1 100644 --- a/build/common.gypi +++ b/build/common.gypi @@ -1986,7 +1986,12 @@ }], ['linux_keep_shadow_stacks==1', { 'defines': ['KEEP_SHADOW_STACKS'], - 'cflags': ['-finstrument-functions'], + 'cflags': [ + '-finstrument-functions', + # Allow mmx intrinsics to inline, so that the compiler can expand + # the intrinsics. + '-finstrument-functions-exclude-file-list=mmintrin.h', + ], }], ['linux_use_gold_flags==1', { 'ldflags': [ |