[llvm] [DirectX] Add support for typedBufferLoad and Store for RWBuffer<double2> and RWBuffer<double> (PR #139996)
Justin Bogner via llvm-commits
llvm-commits at lists.llvm.org
Wed May 14 22:04:46 PDT 2025
================
@@ -660,6 +743,14 @@ static bool expandIntrinsic(Function &F, CallInst *Orig) {
case Intrinsic::dx_radians:
Result = expandRadiansIntrinsic(Orig);
break;
+ case Intrinsic::dx_resource_load_typedbuffer:
+ expandTypedBufferLoadIntrinsic(Orig);
+ Orig->eraseFromParent();
+ return true;
+ case Intrinsic::dx_resource_store_typedbuffer:
+ expandTypedBufferStoreIntrinsic(Orig);
+ Orig->eraseFromParent();
+ return true;
----------------
bogner wrote:
This feels like a bit of a break in abstraction from the other intrinsics here and I think it would be surprising that these just return if we were to add any other logic after the switch here. Can we adjust the structure of this function so that we don't need to do a special case here?
https://github.com/llvm/llvm-project/pull/139996
More information about the llvm-commits
mailing list