diff options
Diffstat (limited to 'clang/test/Driver/ppc-abi.c')
-rw-r--r-- | clang/test/Driver/ppc-abi.c | 38 |
1 files changed, 35 insertions, 3 deletions
diff --git a/clang/test/Driver/ppc-abi.c b/clang/test/Driver/ppc-abi.c index cebc90d3f99..34fe269dc37 100644 --- a/clang/test/Driver/ppc-abi.c +++ b/clang/test/Driver/ppc-abi.c @@ -24,10 +24,42 @@ // RUN: %clang -target powerpc64le-unknown-linux-gnu %s -### -o %t.o 2>&1 \ // RUN: -mabi=altivec | FileCheck -check-prefix=CHECK-ELFv2 %s -// CHECK-ELFv1: "-mrelocation-model" "pic" "-pic-level" "2" +// CHECK-ELFv1: "-mrelocation-model" "static" // CHECK-ELFv1: "-target-abi" "elfv1" -// CHECK-ELFv1-QPX: "-mrelocation-model" "pic" "-pic-level" "2" +// CHECK-ELFv1-QPX: "-mrelocation-model" "static" // CHECK-ELFv1-QPX: "-target-abi" "elfv1-qpx" -// CHECK-ELFv2: "-mrelocation-model" "pic" "-pic-level" "2" +// CHECK-ELFv2: "-mrelocation-model" "static" // CHECK-ELFv2: "-target-abi" "elfv2" +// RUN: %clang -fPIC -target powerpc64-unknown-linux-gnu %s -### -o %t.o 2>&1 \ +// RUN: | FileCheck -check-prefix=CHECK-ELFv1-PIC %s +// RUN: %clang -fPIC -target powerpc64-unknown-linux-gnu %s -### -o %t.o 2>&1 \ +// RUN: -mabi=elfv1 | FileCheck -check-prefix=CHECK-ELFv1-PIC %s +// RUN: %clang -fPIC -target powerpc64-unknown-linux-gnu %s -### -o %t.o 2>&1 \ +// RUN: -mabi=elfv1-qpx | FileCheck -check-prefix=CHECK-ELFv1-QPX-PIC %s +// RUN: %clang -fPIC -target powerpc64-unknown-linux-gnu %s -### -o %t.o 2>&1 \ +// RUN: -mcpu=a2q | FileCheck -check-prefix=CHECK-ELFv1-QPX-PIC %s +// RUN: %clang -fPIC -target powerpc64-unknown-linux-gnu %s -### -o %t.o 2>&1 \ +// RUN: -mcpu=a2 -mqpx | FileCheck -check-prefix=CHECK-ELFv1-QPX-PIC %s +// RUN: %clang -fPIC -target powerpc64-unknown-linux-gnu %s -### -o %t.o 2>&1 \ +// RUN: -mcpu=a2q -mno-qpx | FileCheck -check-prefix=CHECK-ELFv1-PIC %s +// RUN: %clang -fPIC -target powerpc64-unknown-linux-gnu %s -### -o %t.o 2>&1 \ +// RUN: -mabi=elfv2 | FileCheck -check-prefix=CHECK-ELFv2-PIC %s + +// RUN: %clang -fPIC -target powerpc64le-unknown-linux-gnu %s -### -o %t.o 2>&1 \ +// RUN: | FileCheck -check-prefix=CHECK-ELFv2-PIC %s +// RUN: %clang -fPIC -target powerpc64le-unknown-linux-gnu %s -### -o %t.o 2>&1 \ +// RUN: -mabi=elfv1 | FileCheck -check-prefix=CHECK-ELFv1-PIC %s +// RUN: %clang -fPIC -target powerpc64le-unknown-linux-gnu %s -### -o %t.o 2>&1 \ +// RUN: -mabi=elfv2 | FileCheck -check-prefix=CHECK-ELFv2-PIC %s +// RUN: %clang -fPIC -target powerpc64le-unknown-linux-gnu %s -### -o %t.o 2>&1 \ +// RUN: -mabi=altivec | FileCheck -check-prefix=CHECK-ELFv2-PIC %s + +// CHECK-ELFv1-PIC: "-mrelocation-model" "pic" "-pic-level" "2" +// CHECK-ELFv1-PIC: "-target-abi" "elfv1" +// CHECK-ELFv1-QPX-PIC: "-mrelocation-model" "pic" "-pic-level" "2" +// CHECK-ELFv1-QPX-PIC: "-target-abi" "elfv1-qpx" +// CHECK-ELFv2-PIC: "-mrelocation-model" "pic" "-pic-level" "2" +// CHECK-ELFv2-PIC: "-target-abi" "elfv2" + + |