[PATCH] D134641: [AMDGPU][Backend] Fix user-after-free in AMDGPUReleaseVGPRs::isLastVGPRUseVMEMStore
Matt Arsenault via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Oct 18 09:38:26 PDT 2022
arsenm accepted this revision.
arsenm added a comment.
This revision is now accepted and ready to land.
LGTM with nit
================
Comment at: llvm/lib/Target/AMDGPU/AMDGPUReleaseVGPRs.cpp:70-71
+
+ df_iterator_default_set<MachineBasicBlock const *> Visited;
+ SmallVector<MachineBasicBlock const *> EndWithVMEMStoreBlocks;
+
----------------
east const?
================
Comment at: llvm/lib/Target/AMDGPU/AMDGPUReleaseVGPRs.cpp:86
+ for (MachineBasicBlock const *MBB : EndWithVMEMStoreBlocks) {
+ for (MachineBasicBlock const *Succ : depth_first_ext(MBB, Visited)) {
+ BlockVMEMStore[Succ->getNumber()] = true;
----------------
Passing a pre-filled set to visited is a bit weird, but I think this is OK
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D134641/new/
https://reviews.llvm.org/D134641
More information about the llvm-commits
mailing list