diff options
author | Scott Linder <scott@scottlinder.com> | 2019-01-28 17:12:19 +0000 |
---|---|---|
committer | Scott Linder <scott@scottlinder.com> | 2019-01-28 17:12:19 +0000 |
commit | bef2663751fd1f9ad12ddcbea2da87f47f1f42c7 (patch) | |
tree | 182f1d59e8b9f1a4e49d94a835c39169c7d1034a /clang/lib/Driver/ToolChains/AMDGPU.cpp | |
parent | 23019f946d413a4a22351c7e96ce84872ac17560 (diff) | |
download | bcm5719-llvm-bef2663751fd1f9ad12ddcbea2da87f47f1f42c7.tar.gz bcm5719-llvm-bef2663751fd1f9ad12ddcbea2da87f47f1f42c7.zip |
Add -fapply-global-visibility-to-externs for -cc1
Introduce an option to request global visibility settings be applied to
declarations without a definition or an explicit visibility, rather than
the existing behavior of giving these default visibility. When the
visibility of all or most extern definitions are known this allows for
the same optimisations -fvisibility permits without updating source code
to annotate all declarations.
Differential Revision: https://reviews.llvm.org/D56868
llvm-svn: 352391
Diffstat (limited to 'clang/lib/Driver/ToolChains/AMDGPU.cpp')
-rw-r--r-- | clang/lib/Driver/ToolChains/AMDGPU.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/clang/lib/Driver/ToolChains/AMDGPU.cpp b/clang/lib/Driver/ToolChains/AMDGPU.cpp index a03a6073303..b9300bcc42e 100644 --- a/clang/lib/Driver/ToolChains/AMDGPU.cpp +++ b/clang/lib/Driver/ToolChains/AMDGPU.cpp @@ -108,5 +108,6 @@ void AMDGPUToolChain::addClangTargetOptions( options::OPT_fvisibility_ms_compat)) { CC1Args.push_back("-fvisibility"); CC1Args.push_back("hidden"); + CC1Args.push_back("-fapply-global-visibility-to-externs"); } } |