diff options
author | earthdok@chromium.org <earthdok@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-07-14 16:27:24 +0000 |
---|---|---|
committer | earthdok@chromium.org <earthdok@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-07-14 16:27:24 +0000 |
commit | f1b252f7ca363ef1fa56118570fb0c44efa83f6d (patch) | |
tree | 8979c4cd502cb1933ce647d0ea1f3555add13798 /third_party | |
parent | 71bd2a125313625cf231df6c07438fc7b8af3ab8 (diff) | |
download | chromium_src-f1b252f7ca363ef1fa56118570fb0c44efa83f6d.zip chromium_src-f1b252f7ca363ef1fa56118570fb0c44efa83f6d.tar.gz chromium_src-f1b252f7ca363ef1fa56118570fb0c44efa83f6d.tar.bz2 |
Instrumented libraries: use package-specific sanitizer blacklists.
Previously we used a single blacklist file per sanitizer. The same file was used
for Chromium and for every instrumented package. This change allows choosing a
different blacklist file for each package, which means that package targets may
now depend on the blacklist files, avoiding expensive clobbers.
This CL also blacklists two known issues in instrumented libraries.
BUG=313751, 367509
R=glider@chromium.org
NOTRY=true
TEST=MSan interactive_ui_tests, ASan compile
Review URL: https://codereview.chromium.org/390093002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@282959 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'third_party')
5 files changed, 24 insertions, 7 deletions
diff --git a/third_party/instrumented_libraries/blacklists/asan/libglib2.0-0.txt b/third_party/instrumented_libraries/blacklists/asan/libglib2.0-0.txt new file mode 100644 index 0000000..8989568 --- /dev/null +++ b/third_party/instrumented_libraries/blacklists/asan/libglib2.0-0.txt @@ -0,0 +1,2 @@ +# http://crbug.com/367509 +fun:g_utf8_to_ucs4_fast diff --git a/third_party/instrumented_libraries/blacklists/msan/libx11-6.txt b/third_party/instrumented_libraries/blacklists/msan/libx11-6.txt new file mode 100644 index 0000000..a72a39d --- /dev/null +++ b/third_party/instrumented_libraries/blacklists/msan/libx11-6.txt @@ -0,0 +1,2 @@ +# https://bugs.freedesktop.org/show_bug.cgi?id=81236 +fun:XIconifyWindow diff --git a/third_party/instrumented_libraries/download_build_install.py b/third_party/instrumented_libraries/download_build_install.py index 4ea25d7..3a2062d 100755 --- a/third_party/instrumented_libraries/download_build_install.py +++ b/third_party/instrumented_libraries/download_build_install.py @@ -229,7 +229,7 @@ def build_environment(parsed_arguments, product_directory, install_prefix): cflags = unescape_flags(parsed_arguments.cflags) if parsed_arguments.sanitizer_blacklist: cflags += ' -fsanitize-blacklist=%s/%s' % ( - product_directory, + get_script_absolute_path(), parsed_arguments.sanitizer_blacklist) environment['CFLAGS'] = cflags environment['CXXFLAGS'] = cflags diff --git a/third_party/instrumented_libraries/instrumented_libraries.gyp b/third_party/instrumented_libraries/instrumented_libraries.gyp index 847f378..47e7874 100644 --- a/third_party/instrumented_libraries/instrumented_libraries.gyp +++ b/third_party/instrumented_libraries/instrumented_libraries.gyp @@ -48,15 +48,16 @@ ], 'patch': '', 'run_before_build': '', + 'asan_blacklist': '', + 'msan_blacklist': '', + 'tsan_blacklist': '', 'conditions': [ ['asan==1', { - 'sanitizer_blacklist': '', 'package_cflags': ['-fsanitize=address'], 'package_ldflags': ['-fsanitize=address'], }], ['msan==1', { - 'sanitizer_blacklist': '<(msan_blacklist)', 'package_cflags': [ '-fsanitize=memory', '-fsanitize-memory-track-origins=<(msan_track_origins)' @@ -64,7 +65,6 @@ 'package_ldflags': ['-fsanitize=memory'], }], ['tsan==1', { - 'sanitizer_blacklist': '<(tsan_blacklist)', 'package_cflags': ['-fsanitize=thread'], 'package_ldflags': ['-fsanitize=thread'], }], @@ -241,6 +241,7 @@ '--disable-gtk-doc-html', '--disable-gtk-doc-pdf', ], + 'asan_blacklist': 'blacklists/asan/libglib2.0-0.txt', 'includes': ['standard_instrumented_package_target.gypi'], }, { @@ -289,6 +290,7 @@ 'package_name': 'libx11-6', 'dependencies=': [], 'extra_configure_flags': ['--disable-specs'], + 'msan_blacklist': 'blacklists/msan/libx11-6.txt', 'includes': ['standard_instrumented_package_target.gypi'], }, { diff --git a/third_party/instrumented_libraries/standard_instrumented_package_target.gypi b/third_party/instrumented_libraries/standard_instrumented_package_target.gypi index 195adab..2d01aa8 100644 --- a/third_party/instrumented_libraries/standard_instrumented_package_target.gypi +++ b/third_party/instrumented_libraries/standard_instrumented_package_target.gypi @@ -27,13 +27,10 @@ '--extra-configure-flags=>(_extra_configure_flags)', '--cflags=>(_package_cflags)', '--ldflags=>(_package_ldflags)', - '--patch=>(_patch)', - '--run-before-build=>(_run_before_build)', '--cc=<(_cc)', '--cxx=<(_cxx)', '--jobs=>(_jobs)', '--build-method=>(_build_method)', - '--sanitizer-blacklist=>(_sanitizer_blacklist)', ], 'conditions': [ ['verbose_libraries_build==1', { @@ -44,15 +41,29 @@ ], 'target_conditions': [ ['">(_patch)"!=""', { + 'action+': [ + '--patch=>(_patch)', + ], 'inputs+': [ '>(_patch)', ], }], ['">(_run_before_build)"!=""', { + 'action+': [ + '--run-before-build=>(_run_before_build)', + ], 'inputs+': [ '>(_run_before_build)', ], }], + ['">(_<(_sanitizer_type)_blacklist)"!=""', { + 'action+': [ + '--sanitizer-blacklist=>(_<(_sanitizer_type)_blacklist)', + ], + 'inputs+': [ + '>(_<(_sanitizer_type)_blacklist)', + ], + }], ], }, ], |