From 222e2a7620e6520ffaf4fc4e69d79c18da31542e Mon Sep 17 00:00:00 2001 From: "Zancanaro; Carlo" Date: Mon, 24 Sep 2012 09:58:17 +1000 Subject: Add the clang library to the repo (with some of my changes, too). --- clang/test/Driver/altivec.cpp | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 clang/test/Driver/altivec.cpp (limited to 'clang/test/Driver/altivec.cpp') diff --git a/clang/test/Driver/altivec.cpp b/clang/test/Driver/altivec.cpp new file mode 100644 index 0000000..6059ad0 --- /dev/null +++ b/clang/test/Driver/altivec.cpp @@ -0,0 +1,14 @@ +// Check that we error when -faltivec is specified on non-ppc platforms. + +// RUN: %clang -ccc-clang-archs powerpc -target powerpc-apple-darwin -faltivec -fsyntax-only %s +// RUN: %clang -ccc-clang-archs powerpc64 -target powerpc64-linux-gnu -faltivec -fsyntax-only %s + +// RUN: %clang -target i386-pc-win32 -faltivec -fsyntax-only %s 2>&1 | FileCheck %s +// RUN: %clang -target x86_64-unknown-freebsd -faltivec -fsyntax-only %s 2>&1 | FileCheck %s +// RUN: %clang -target armv6-apple-darwin -faltivec -fsyntax-only %s 2>&1 | FileCheck %s +// RUN: %clang -target armv7-apple-darwin -faltivec -fsyntax-only %s 2>&1 | FileCheck %s +// RUN: %clang -ccc-clang-archs mips -target mips-linux-gnu -faltivec -fsyntax-only %s 2>&1 | FileCheck %s +// RUN: %clang -ccc-clang-archs mips64 -target mips64-linux-gnu -faltivec -fsyntax-only %s 2>&1 | FileCheck %s +// RUN: %clang -ccc-clang-archs sparc -target sparc-unknown-solaris -faltivec -fsyntax-only %s 2>&1 | FileCheck %s + +// CHECK: invalid argument '-faltivec' only allowed with 'ppc/ppc64' -- cgit v1.2.3