[llvm] [SPIRV] Change how to detect OpenCL/Vulkan Env and update tests accordingly. (PR #129689)
Marcos Maronas via llvm-commits
llvm-commits at lists.llvm.org
Wed May 28 06:36:52 PDT 2025
================
@@ -78,14 +83,22 @@ class SPIRVSubtarget : public SPIRVGenSubtargetInfo {
unsigned getPointerSize() const { return PointerSize; }
unsigned getBound() const { return GR->getBound(); }
bool canDirectlyComparePointers() const;
- // TODO: this environment is not implemented in Triple, we need to decide
- // how to standardize its support. For now, let's assume SPIR-V with physical
- // addressing is OpenCL, and Logical addressing is Vulkan.
- bool isOpenCLEnv() const {
+ void setEnv(SPIRVEnvType E) {
+ assert(E != Unknown && "Unknown environment is not allowed");
----------------
maarquitos14 wrote:
Done in fcc219ad79d4.
https://github.com/llvm/llvm-project/pull/129689
More information about the llvm-commits
mailing list