[llvm] [NVPTX] Aggressively try to replace image handles with references (PR #119730)

Artem Belevich via llvm-commits llvm-commits at lists.llvm.org
Fri Dec 13 13:33:17 PST 2024


================
@@ -55,19 +55,9 @@ NVPTXSubtarget::NVPTXSubtarget(const Triple &TT, const std::string &CPU,
                                const std::string &FS,
                                const NVPTXTargetMachine &TM)
     : NVPTXGenSubtargetInfo(TT, CPU, /*TuneCPU*/ CPU, FS), PTXVersion(0),
-      FullSmVersion(200), SmVersion(getSmVersion()), TM(TM),
+      FullSmVersion(200), SmVersion(getSmVersion()),
       TLInfo(TM, initializeSubtargetDependencies(CPU, FS)) {}
 
-bool NVPTXSubtarget::hasImageHandles() const {
-  // Enable handles for Kepler+, where CUDA supports indirect surfaces and
-  // textures
-  if (TM.getDrvInterface() == NVPTX::CUDA)
----------------
Artem-B wrote:

> I think the minimum supported by nvcc is sm_50.

The bar here is what hardware is still out there in quantities sufficient to keep support for them around. AWS still seems to list P2 instances with K80: 
![image](https://github.com/user-attachments/assets/ea1d3885-6443-4c90-b50b-fe309af17a6e)

I think it's the current practical low bar on the support.

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


More information about the llvm-commits mailing list