[Mlir-commits] [clang] [llvm] [mlir] [Clang][CodeGen] Start migrating away from assuming the Default AS is 0 (PR #88182)

Alex Voicu llvmlistbot at llvm.org
Sun May 12 05:08:34 PDT 2024


https://github.com/AlexVlx commented:

> Please fix the commit message before you merge; otherwise LGTM 

For the commit message I was thinking something along the following lines: `At the moment, Clang is rather liberal in assuming that 0 (and by extension unqualified) is always a safe default. This does not work for targets that actually use a different value for the default / generic AS (for example, the SPIRV that obtains from HIPSPV or SYCL). This patch is a first, fairly safe step towards trying to clear things up by querying a modules default AS from the target, rather than assuming it's 0, alongside fixing a few places where things break / we encode the 0 AS assumption. A bunch of existing tests are extended to check for non-zero default AS usage.`

https://github.com/llvm/llvm-project/pull/88182


More information about the Mlir-commits mailing list