llvm-project
ad422cd1 - [flang][cuda] Handle Constant and Shared attributes in CUDA generic matching distance (#201451)

Commit
103 days ago
[flang][cuda] Handle Constant and Shared attributes in CUDA generic matching distance (#201451) The CUDA generic resolution matching distance function did not handle actual arguments with the `Constant` or `Shared` data attribute. These attributes represent device memory but were unhandled, causing the distance to fall through to infinity. Under `-gpu=mem:unified`, this led to spurious ambiguity errors when multiple specifics (e.g. host-to-device and device-to-device overloads) both became candidates with tied infinite distances. Treat Constant and Shared actuals the same as Device in the matching distance table, since all three reside in device memory.
Author
Parents
Loading