Skip to content

Commit c222fb5

Browse files
committed
merge main into amd-stg-open
reverts: breaks 3 sollve tests: [OpenMP] Simplify parallel reductions (llvm#70983) Change-Id: I6b4bd37c359f0227fd4ce63e99f46f2c3d3d60c1
2 parents f4cca3f + e9a48f9 commit c222fb5

File tree

2 files changed

+30
-1
lines changed

2 files changed

+30
-1
lines changed
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
// RUN: %libomptarget-compilexx-run-and-check-generic
2+
// RUN: %libomptarget-compileoptxx-run-and-check-generic
3+
4+
#include <omp.h>
5+
#include <stdio.h>
6+
__attribute__((optnone)) void optnone(void) {}
7+
8+
int main() {
9+
int sum = 0, nt;
10+
#pragma omp target teams map(tofrom : sum, nt) num_teams(1)
11+
{
12+
nt = 3 * omp_get_max_threads();
13+
optnone();
14+
#pragma omp parallel reduction(+ : sum)
15+
sum += 1;
16+
#pragma omp parallel reduction(+ : sum)
17+
sum += 1;
18+
#pragma omp parallel reduction(+ : sum)
19+
sum += 1;
20+
}
21+
// CHECK: nt: [[NT:.*]]
22+
// CHECK: sum: [[NT]]
23+
printf("nt: %i\n", nt);
24+
printf("sum: %i\n", sum);
25+
}

revert_patches.txt

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,4 +15,8 @@ Revert: waiting on pip install myst-parser
1515
Revert: breaks qmcpack ISEL
1616
"[X86][EVEX512] Restrict attaching EVEX512 for default CPU only, NFCI (#65920)"
1717

18-
18+
Johannes: revert breaks 3 sollve tests
19+
[OpenMP] Simplify parallel reductions (#70983)
20+
test_loop_reduction_and_device.c
21+
test_loop_reduction_bitand_device.c
22+
test_loop_reduction_multiply_device.c

0 commit comments

Comments
 (0)