Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(117)

Side by Side Diff: build/config/sanitizers/BUILD.gn

Issue 1508403002: Revert of roll clang 254049:254793 (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 # Copyright 2014 The Chromium Authors. All rights reserved. 1 # Copyright 2014 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 import("//build/config/chrome_build.gni") 5 import("//build/config/chrome_build.gni")
6 import("//build/config/sanitizers/sanitizers.gni") 6 import("//build/config/sanitizers/sanitizers.gni")
7 7
8 # Contains the dependencies needed for sanitizers to link into executables and 8 # Contains the dependencies needed for sanitizers to link into executables and
9 # shared_libraries. Unconditionally depend upon this target as it is empty if 9 # shared_libraries. Unconditionally depend upon this target as it is empty if
10 # |is_asan|, |is_lsan|, |is_tsan|, |is_msan| and |use_custom_libcxx| are false. 10 # |is_asan|, |is_lsan|, |is_tsan|, |is_msan| and |use_custom_libcxx| are false.
(...skipping 18 matching lines...) Expand all
29 if (is_asan) { 29 if (is_asan) {
30 ldflags += [ "-fsanitize=address" ] 30 ldflags += [ "-fsanitize=address" ]
31 } 31 }
32 if (is_lsan) { 32 if (is_lsan) {
33 ldflags += [ "-fsanitize=leak" ] 33 ldflags += [ "-fsanitize=leak" ]
34 } 34 }
35 if (is_tsan) { 35 if (is_tsan) {
36 ldflags += [ "-fsanitize=thread" ] 36 ldflags += [ "-fsanitize=thread" ]
37 } 37 }
38 if (is_msan) { 38 if (is_msan) {
39 ldflags += [ "-fsanitize=memory" ] 39 ldflags += [
40 "-fsanitize=memory",
41
42 # TODO(eugenis): Remove when msan migrates to new ABI (crbug.com/560589).
43 "-pie",
44 ]
40 } 45 }
41 if (is_ubsan) { 46 if (is_ubsan) {
42 ldflags += [ "-fsanitize=undefined" ] 47 ldflags += [ "-fsanitize=undefined" ]
43 } 48 }
44 if (is_ubsan_vptr) { 49 if (is_ubsan_vptr) {
45 ldflags += [ "-fsanitize=vptr" ] 50 ldflags += [ "-fsanitize=vptr" ]
46 } 51 }
47 } 52 }
48 53
49 source_set("options_sources") { 54 source_set("options_sources") {
(...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after
132 "-fsanitize-blacklist=$tsan_blacklist_path", 137 "-fsanitize-blacklist=$tsan_blacklist_path",
133 ] 138 ]
134 } 139 }
135 if (is_msan) { 140 if (is_msan) {
136 msan_blacklist_path = 141 msan_blacklist_path =
137 rebase_path("//tools/msan/blacklist.txt", root_build_dir) 142 rebase_path("//tools/msan/blacklist.txt", root_build_dir)
138 cflags += [ 143 cflags += [
139 "-fsanitize=memory", 144 "-fsanitize=memory",
140 "-fsanitize-memory-track-origins=$msan_track_origins", 145 "-fsanitize-memory-track-origins=$msan_track_origins",
141 "-fsanitize-blacklist=$msan_blacklist_path", 146 "-fsanitize-blacklist=$msan_blacklist_path",
147
148 # TODO(eugenis): Remove when msan migrates to new ABI (crbug.com/560589) .
149 "-fPIC",
142 ] 150 ]
143 } 151 }
144 if (is_ubsan) { 152 if (is_ubsan) {
145 ubsan_blacklist_path = 153 ubsan_blacklist_path =
146 rebase_path("//tools/ubsan/blacklist.txt", root_build_dir) 154 rebase_path("//tools/ubsan/blacklist.txt", root_build_dir)
147 cflags += [ 155 cflags += [
148 # Yasm dies with an "Illegal instruction" error when bounds checking is 156 # Yasm dies with an "Illegal instruction" error when bounds checking is
149 # enabled. See http://crbug.com/489901 157 # enabled. See http://crbug.com/489901
150 # "-fsanitize=bounds", 158 # "-fsanitize=bounds",
151 "-fsanitize=float-divide-by-zero", 159 "-fsanitize=float-divide-by-zero",
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after
242 250
243 config("default_sanitizer_coverage_flags") { 251 config("default_sanitizer_coverage_flags") {
244 cflags = [] 252 cflags = []
245 253
246 if (use_sanitizer_coverage) { 254 if (use_sanitizer_coverage) {
247 # FIXME: make this configurable. 255 # FIXME: make this configurable.
248 cflags += 256 cflags +=
249 [ "-fsanitize-coverage=edge,indirect-calls,8bit-counters,trace-cmp" ] 257 [ "-fsanitize-coverage=edge,indirect-calls,8bit-counters,trace-cmp" ]
250 } 258 }
251 } 259 }
OLDNEW
« no previous file with comments | « build/common.gypi ('k') | third_party/instrumented_libraries/binaries/msan-chained-origins-precise.tgz.sha1 » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698