[llvm] Set shader analysis flags EnableRawAndStructuredBuffers and ComputeShadersPlusRawAndStructuredBuffers for RWBuffers (PR #114449)
Cooper Partin via llvm-commits
llvm-commits at lists.llvm.org
Thu Oct 31 11:47:09 PDT 2024
coopp wrote:
Hopefully this PR helps validate my approach for setting these flags. I have not figured out how to get strcuturedbuffers to work/be detected yet. I thought I had the correct IR, but they are not being picked up for some reason.
I had this logic in the code which is not in this PR
```
// StructuredRWBuffer
for (const ResourceInfo &RI : DRM.srvs()) {
if (RI.getResourceKind() == ResourceKind::RawBuffer) {
Flags.EnableRawAndStructuredBuffers = true;
Flags.ComputeShadersPlusRawAndStructuredBuffers =
(SP == Triple::EnvironmentType::Compute && SM.getMajor() == 4);
break;
}
}
```
https://github.com/llvm/llvm-project/pull/114449
More information about the llvm-commits
mailing list