Commit 09cdfd6
authored
[flang][cuda] Avoid hlfir.declare verifier error when creating temps (#89984)
When creating temporaries for implicit transfer, the newly create
hlfir.declare operation was missing some information like the shape and
the verifier was throwing an error. Fix it by making sure we have an
ExtendedValue when calling addSymbol to register the temp.
```
error: loc("cuda-data-transfer.cuf":67:22): 'hlfir.declare' op of array entity
with a raw address base must have a shape operand that is a shape or shapeshift
```
Thanks @jeanPerier for the advice!
FYI @ImanHosseini1 parent 5cfd5d1 commit 09cdfd6
File tree
2 files changed
+4
-2
lines changed- flang
- lib/Lower
- test/Lower/CUDA
2 files changed
+4
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3794 | 3794 | | |
3795 | 3795 | | |
3796 | 3796 | | |
3797 | | - | |
| 3797 | + | |
| 3798 | + | |
| 3799 | + | |
3798 | 3800 | | |
3799 | 3801 | | |
3800 | 3802 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
98 | 98 | | |
99 | 99 | | |
100 | 100 | | |
101 | | - | |
| 101 | + | |
102 | 102 | | |
103 | 103 | | |
104 | 104 | | |
| |||
0 commit comments