[llvm] [SPIRV] Add radians intrinsic (PR #110800)

Farzon Lotfi via llvm-commits llvm-commits at lists.llvm.org
Wed Oct 2 17:42:07 PDT 2024


================
@@ -2534,6 +2534,8 @@ bool SPIRVInstructionSelector::selectIntrinsic(Register ResVReg,
   }
   case Intrinsic::spv_step:
     return selectExtInst(ResVReg, ResType, I, CL::step, GL::Step);
+  case Intrinsic::spv_radians:
+    return selectExtInst(ResVReg, ResType, I, CL::radians, GL::Radians);
----------------
farzonl wrote:

We don't use the opencl extension in hlsl though. Even though this is an easy test change `llvm/test/CodeGen/SPIRV/hlsl-intrinsics` tests should be devoted to how HLSL does things.

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


More information about the llvm-commits mailing list