[llvm] [HLSL] Fix Root signature test error (PR #127261)
Justin Bogner via llvm-commits
llvm-commits at lists.llvm.org
Fri Feb 14 13:51:40 PST 2025
================
@@ -186,9 +186,9 @@ PreservedAnalyses RootSignatureAnalysisPrinter::run(Module &M,
OS << "Root Signature Definitions"
<< "\n";
uint8_t Space = 0;
- for (const auto &P : RSDMap) {
- const auto &[Function, RSD] = P;
- OS << "Definition for '" << Function->getName() << "':\n";
+ for (const auto &F : M) {
+ const auto RSD = RSDMap.at(&F);
----------------
bogner wrote:
This will crash if there are functions in the module without root signatures (ie, if the root signature metadata isn't present, or if there are helper functions without their own root signatures)
https://github.com/llvm/llvm-project/pull/127261
More information about the llvm-commits
mailing list