[flang-commits] [flang] [mlir] [flang][openacc] Support multiple device_type when lowering (PR #78634)
Valentin Clement バレンタイン クレメン via flang-commits
flang-commits at lists.llvm.org
Thu Jan 18 21:05:16 PST 2024
================
@@ -40,5 +40,9 @@ subroutine sub1()
! CHECK: acc.parallel num_gangs({%c2{{.*}} : i32}, {%c1{{.*}} : i32, %c1{{.*}} : i32, %c1{{.*}} : i32} [#acc.device_type<nvidia>])
+ !$acc parallel device_type(nvidia, default) num_gangs(1, 1, 1)
+ !$acc end parallel
+
+! CHECK: acc.parallel num_gangs({%c1_i32_9 : i32, %c1_i32_10 : i32, %c1_i32_11 : i32} [#acc.device_type<nvidia>], {%c1_i32_9 : i32, %c1_i32_10 : i32, %c1_i32_11 : i32} [#acc.device_type<default>])
----------------
clementval wrote:
```suggestion
! CHECK: acc.parallel num_gangs({%c1{{.*}} : i32, %c1{{.*}} : i32, %c1{{.*}} : i32} [#acc.device_type<nvidia>], {%c1{{.*}} : i32, %c1{{.*}} : i32, %c1{{.*}} : i32} [#acc.device_type<default>])
```
https://github.com/llvm/llvm-project/pull/78634
More information about the flang-commits
mailing list