From 29c231a2a760d78de22afbaf5fcb33dee57670eb Mon Sep 17 00:00:00 2001 From: erichkeane Date: Tue, 22 Jul 2025 11:30:24 -0700 Subject: [PATCH] Fix two issues in parallel_create_zero These tests have a few issues, but this patch fixes two of them: First, it adds the close paren on the 'copyout' clause that was missing. Second, it corrects the capitalization on the call to 'Test1', which was resulting in the test not being run properly. This does NOT fix the ill-formed use of `loop` however. --- Tests/parallel_create_zero.c | 6 +++--- Tests/parallel_create_zero.cpp | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/Tests/parallel_create_zero.c b/Tests/parallel_create_zero.c index 33c88e7..8d4503a 100644 --- a/Tests/parallel_create_zero.c +++ b/Tests/parallel_create_zero.c @@ -12,7 +12,7 @@ int Test1(){ b[x] = 0.0; } - #pragma acc data copyin(a[0:n]) copyout(b[0:n] + #pragma acc data copyin(a[0:n]) copyout(b[0:n]) { #pragma acc parallel create(zero: b[0:n]) { @@ -40,11 +40,11 @@ int main(){ #ifndef T1 failed = 0; for (int x = 0; x < NUM_TEST_CALLS; ++x){ - failed = failed + test1(); + failed = failed + Test1(); } if (failed != 0){ failcode = failcode + (1 << 0); } #endif return failcode; -} \ No newline at end of file +} diff --git a/Tests/parallel_create_zero.cpp b/Tests/parallel_create_zero.cpp index 8464874..323216c 100644 --- a/Tests/parallel_create_zero.cpp +++ b/Tests/parallel_create_zero.cpp @@ -12,7 +12,7 @@ int Test1(){ b[x] = 0.0; } - #pragma acc data copyin(a[0:n]) copyout(b[0:n] + #pragma acc data copyin(a[0:n]) copyout(b[0:n]) { #pragma acc parallel create(zero: b[0:n]) { @@ -40,11 +40,11 @@ int main(){ #ifndef T1 failed = 0; for (int x = 0; x < NUM_TEST_CALLS; ++x){ - failed = failed + test1(); + failed = failed + Test1(); } if (failed != 0){ failcode = failcode + (1 << 0); } #endif return failcode; -} \ No newline at end of file +}