mirror of
https://github.com/Gericom/teak-llvm.git
synced 2025-06-25 06:18:56 -04:00

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
16 lines
890 B
Common Lisp
16 lines
890 B
Common Lisp
// RUN: %clang -### -target amdgcn-amd-amdhsa -x cl -c -emit-llvm %s 2>&1 | FileCheck -check-prefix=DEFAULT %s
|
|
// RUN: %clang -### -target amdgcn-amd-amdhsa -x cl -c -emit-llvm -fvisibility=protected %s 2>&1 | FileCheck -check-prefix=OVERRIDE-PROTECTED %s
|
|
// RUN: %clang -### -target amdgcn-amd-amdhsa -x cl -c -emit-llvm -fvisibility-ms-compat %s 2>&1 | FileCheck -check-prefix=OVERRIDE-MS %s
|
|
|
|
// DEFAULT-DAG: "-fvisibility" "hidden"
|
|
// DEFAULT-DAG: "-fapply-global-visibility-to-externs"
|
|
|
|
// OVERRIDE-PROTECTED-NOT: "-fapply-global-visibility-to-externs"
|
|
// OVERRIDE-PROTECTED: "-fvisibility" "protected"
|
|
// OVERRIDE-PROTECTED-NOT: "-fapply-global-visibility-to-externs"
|
|
|
|
// OVERRIDE-MS-NOT: "-fapply-global-visibility-to-externs"
|
|
// OVERRIDE-MS-DAG: "-fvisibility" "hidden"
|
|
// OVERRIDE-MS-DAG: "-ftype-visibility" "default"
|
|
// OVERRIDE-MS-NOT: "-fapply-global-visibility-to-externs"
|