[clang] 7577284 - [OpenACC][NFC] Update varlist-ast test to check serialization
via cfe-commits
cfe-commits at lists.llvm.org
Tue Nov 26 07:35:22 PST 2024
Author: erichkeane
Date: 2024-11-26T07:35:17-08:00
New Revision: 7577284c4f3cb81a8ac648683bd3af292827391f
URL: https://github.com/llvm/llvm-project/commit/7577284c4f3cb81a8ac648683bd3af292827391f
DIFF: https://github.com/llvm/llvm-project/commit/7577284c4f3cb81a8ac648683bd3af292827391f.diff
LOG: [OpenACC][NFC] Update varlist-ast test to check serialization
I noticed while working on another test that I never used the PCH
trickery to get this to validate that serialization/deserialization
works correctly. It DOES, but we weren't testing it with this test like
the others.
Added:
Modified:
clang/test/SemaOpenACC/compute-construct-varlist-ast.cpp
Removed:
################################################################################
diff --git a/clang/test/SemaOpenACC/compute-construct-varlist-ast.cpp b/clang/test/SemaOpenACC/compute-construct-varlist-ast.cpp
index e057678d924957..1bfd4e8af64818 100644
--- a/clang/test/SemaOpenACC/compute-construct-varlist-ast.cpp
+++ b/clang/test/SemaOpenACC/compute-construct-varlist-ast.cpp
@@ -1,5 +1,12 @@
// RUN: %clang_cc1 %s -fopenacc -Wno-openacc-deprecated-clause-alias -ast-dump | FileCheck %s
+// Test this with PCH.
+// RUN: %clang_cc1 %s -fopenacc -emit-pch -Wno-openacc-deprecated-clause-alias -o %t %s
+// RUN: %clang_cc1 %s -fopenacc -include-pch %t -Wno-openacc-deprecated-clause-alias -ast-dump-all | FileCheck %s
+
+#ifndef PCH_HELPER
+#define PCH_HELPER
+
int Global;
short GlobalArray[5];
@@ -435,7 +442,7 @@ void TemplUses(T t, U u, T*PointerParam) {
// CHECK-NEXT: TemplateArgument type 'int'
// CHECK-NEXT: BuiltinType{{.*}} 'int'
// CHECK-NEXT: TemplateArgument type 'int[1]'
- // CHECK-NEXT: ConstantArrayType{{.*}} 'int[1]' 1
+ // CHECK-NEXT: ConstantArrayType{{.*}} 'int[1]'{{.*}} 1
// CHECK-NEXT: BuiltinType{{.*}} 'int'
// CHECK-NEXT: ParmVarDecl{{.*}} used t 'int'
// CHECK-NEXT: ParmVarDecl{{.*}} used u 'int *'
@@ -979,3 +986,4 @@ void Inst() {
STempl<int> stempl;
stempl.bar<int>();
}
+#endif
More information about the cfe-commits
mailing list