Please use GitHub pull requests for new patches. Phabricator shutdown timeline
Changeset View
Changeset View
Standalone View
Standalone View
compiler-rt/test/lit.common.cfg
Show First 20 Lines • Show All 45 Lines • ▼ Show 20 Lines | |||||
elif compiler_id == 'GNU': | elif compiler_id == 'GNU': | ||||
config.cxx_mode_flags = ["-x c++"] | config.cxx_mode_flags = ["-x c++"] | ||||
config.debug_info_flags = ["-g"] | config.debug_info_flags = ["-g"] | ||||
else: | else: | ||||
lit_config.fatal("Unsupported compiler id: %r" % compiler_id) | lit_config.fatal("Unsupported compiler id: %r" % compiler_id) | ||||
# Add compiler ID to the list of available features. | # Add compiler ID to the list of available features. | ||||
config.available_features.add(compiler_id) | config.available_features.add(compiler_id) | ||||
# Set cflags required for -fsanitize=address. | |||||
config.sanitize_address_cflags = ["-fsanitize=address"] | |||||
if config.asan_shadow_scale != '': | |||||
config.sanitize_address_cflags += ["-mllvm", "-asan-mapping-scale", | |||||
"-mllvm", config.asan_shadow_scale] | |||||
# BFD linker in 64-bit android toolchains fails to find libm.so, which is a | # BFD linker in 64-bit android toolchains fails to find libm.so, which is a | ||||
# transitive shared library dependency (via asan runtime). | # transitive shared library dependency (via asan runtime). | ||||
if config.android: | if config.android: | ||||
config.target_cflags += " -pie -fuse-ld=gold -Wl,--enable-new-dtags" | config.target_cflags += " -pie -fuse-ld=gold -Wl,--enable-new-dtags" | ||||
# Clear some environment variables that might affect Clang. | # Clear some environment variables that might affect Clang. | ||||
possibly_dangerous_env_vars = ['ASAN_OPTIONS', 'DFSAN_OPTIONS', 'LSAN_OPTIONS', | possibly_dangerous_env_vars = ['ASAN_OPTIONS', 'DFSAN_OPTIONS', 'LSAN_OPTIONS', | ||||
'MSAN_OPTIONS', 'UBSAN_OPTIONS', | 'MSAN_OPTIONS', 'UBSAN_OPTIONS', | ||||
▲ Show 20 Lines • Show All 262 Lines • Show Last 20 Lines |