[llvm] [SPIR-V] Fix environment resolution causing legalization crash (PR #179052)

Dmitry Sidorov via llvm-commits llvm-commits at lists.llvm.org
Tue Feb 3 04:50:14 PST 2026


================
@@ -76,6 +74,11 @@ class SPIRVSubtarget : public SPIRVGenSubtargetInfo {
 
   void initAvailableExtensions(
       const std::set<SPIRV::Extension::Extension> &AllowedExtIds);
+  void initAvailableExtInstSets();
+
+  // If Env is Unknown, scan module for "hlsl.shader" attributes to resolve it.
+  // Must be called before any pass that depends on isShader()/isKernel().
----------------
MrSidims wrote:

Actually, removed the entire comment

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


More information about the llvm-commits mailing list