r341118 - Revert the tests that should've been reverted in rL341115

Artem Belevich via cfe-commits cfe-commits at lists.llvm.org
Thu Aug 30 13:53:15 PDT 2018


Author: tra
Date: Thu Aug 30 13:53:15 2018
New Revision: 341118

URL: http://llvm.org/viewvc/llvm-project?rev=341118&view=rev
Log:
Revert the tests that should've been reverted in rL341115

Removed:
    cfe/trunk/test/Preprocessor/aux-triple.c
Modified:
    cfe/trunk/test/Preprocessor/predefined-macros.c
    cfe/trunk/test/SemaCUDA/builtins.cu

Removed: cfe/trunk/test/Preprocessor/aux-triple.c
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Preprocessor/aux-triple.c?rev=341117&view=auto
==============================================================================
--- cfe/trunk/test/Preprocessor/aux-triple.c (original)
+++ cfe/trunk/test/Preprocessor/aux-triple.c (removed)
@@ -1,64 +0,0 @@
-// Ensure that Clang sets some very basic target defines based on -aux-triple.
-
-// RUN: %clang_cc1 -E -dM -ffreestanding < /dev/null \
-// RUN:     -triple nvptx64-none-none \
-// RUN:   | FileCheck -match-full-lines -check-prefixes NVPTX64,NONE %s
-// RUN: %clang_cc1 -x c++ -E -dM -ffreestanding < /dev/null \
-// RUN:     -triple nvptx64-none-none \
-// RUN:   | FileCheck -match-full-lines -check-prefixes NVPTX64,NONE %s
-// RUN: %clang_cc1 -x cuda -E -dM -ffreestanding < /dev/null \
-// RUN:     -triple nvptx64-none-none \
-// RUN:   | FileCheck -match-full-lines -check-prefixes NVPTX64,NONE %s
-
-// CUDA:
-// RUN: %clang_cc1 -x cuda -E -dM -ffreestanding < /dev/null \
-// RUN:     -triple nvptx64-none-none -aux-triple powerpc64le-unknown-linux-gnu \
-// RUN:   | FileCheck -match-full-lines %s \
-// RUN:     -check-prefixes NVPTX64,PPC64LE,LINUX,LINUX-CPP
-// RUN: %clang_cc1 -x cuda -E -dM -ffreestanding < /dev/null \
-// RUN:     -triple nvptx64-none-none -aux-triple x86_64-unknown-linux-gnu \
-// RUN:   | FileCheck -match-full-lines %s \
-// RUN:     -check-prefixes NVPTX64,X86_64,LINUX,LINUX-CPP
-
-// OpenMP:
-// RUN: %clang_cc1 -E -dM -ffreestanding < /dev/null \
-// RUN:     -fopenmp -fopenmp-is-device -triple nvptx64-none-none \
-// RUN:     -aux-triple powerpc64le-unknown-linux-gnu \
-// RUN:   | FileCheck -match-full-lines -check-prefixes NVPTX64,PPC64LE,LINUX %s
-// RUN: %clang_cc1 -E -dM -ffreestanding < /dev/null \
-// RUN:     -fopenmp -fopenmp-is-device -triple nvptx64-none-none \
-// RUN:     -aux-triple x86_64-unknown-linux-gnu \
-// RUN:   | FileCheck -match-full-lines -check-prefixes NVPTX64,X86_64,LINUX %s
-// RUN: %clang_cc1 -x c++ -E -dM -ffreestanding < /dev/null \
-// RUN:     -fopenmp -fopenmp-is-device -triple nvptx64-none-none \
-// RUN:     -aux-triple powerpc64le-unknown-linux-gnu \
-// RUN:   | FileCheck -match-full-lines %s \
-// RUN:     -check-prefixes NVPTX64,PPC64LE,LINUX,LINUX-CPP
-// RUN: %clang_cc1 -x c++ -E -dM -ffreestanding < /dev/null \
-// RUN:     -fopenmp -fopenmp-is-device -triple nvptx64-none-none \
-// RUN:     -aux-triple x86_64-unknown-linux-gnu \
-// RUN:   | FileCheck -match-full-lines %s \
-// RUN:     -check-prefixes NVPTX64,X86_64,LINUX,LINUX-CPP
-
-// PPC64LE:#define _CALL_ELF 2
-
-// NONE-NOT:#define _GNU_SOURCE
-// LINUX-CPP:#define _GNU_SOURCE 1
-
-// NVPTX64:#define _LP64 1
-
-// NONE-NOT:#define __ELF__
-// LINUX:#define __ELF__ 1
-
-// NVPTX64:#define __LP64__ 1
-// NVPTX64:#define __NVPTX__ 1
-// NVPTX64:#define __PTX__ 1
-
-// NONE-NOT:#define __linux__
-// LINUX:#define __linux__ 1
-
-// NONE-NOT:#define __powerpc64__
-// PPC64LE:#define __powerpc64__ 1
-
-// NONE-NOT:#define __x86_64__
-// X86_64:#define __x86_64__ 1

Modified: cfe/trunk/test/Preprocessor/predefined-macros.c
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Preprocessor/predefined-macros.c?rev=341118&r1=341117&r2=341118&view=diff
==============================================================================
--- cfe/trunk/test/Preprocessor/predefined-macros.c (original)
+++ cfe/trunk/test/Preprocessor/predefined-macros.c Thu Aug 30 13:53:15 2018
@@ -183,11 +183,9 @@
 // CHECK-HIP: #define __HIP__ 1
 
 // RUN: %clang_cc1 %s -E -dM -o - -x hip -triple amdgcn-amd-amdhsa \
-// RUN:   -aux-triple x86_64-unknown-linux -fcuda-is-device \
+// RUN:   -fcuda-is-device \
 // RUN:   | FileCheck -match-full-lines %s --check-prefix=CHECK-HIP-DEV
 // CHECK-HIP-DEV-NOT: #define __CUDA_ARCH__
 // CHECK-HIP-DEV: #define __HIPCC__ 1
 // CHECK-HIP-DEV: #define __HIP_DEVICE_COMPILE__ 1
 // CHECK-HIP-DEV: #define __HIP__ 1
-// CHECK_HIP-DEV: #define __linux__ 1
-// CHECK_HIP-DEV: #define __gnu_linux__ 1

Modified: cfe/trunk/test/SemaCUDA/builtins.cu
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/SemaCUDA/builtins.cu?rev=341118&r1=341117&r2=341118&view=diff
==============================================================================
--- cfe/trunk/test/SemaCUDA/builtins.cu (original)
+++ cfe/trunk/test/SemaCUDA/builtins.cu Thu Aug 30 13:53:15 2018
@@ -12,8 +12,8 @@
 // RUN:     -aux-triple x86_64-unknown-unknown \
 // RUN:     -fsyntax-only -verify %s
 
-#if !defined(__x86_64__)
-#error "Expected to see preprocessor macros from the host."
+#if !(defined(__amd64__) && defined(__PTX__))
+#error "Expected to see preprocessor macros from both sides of compilation."
 #endif
 
 void hf() {




More information about the cfe-commits mailing list