[PATCH] D118124: [regalloc] Fix assertion error when LiveInterval is empty
Matthias Braun via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Jan 25 12:38:31 PST 2022
MatzeB accepted this revision.
MatzeB added a comment.
This revision is now accepted and ready to land.
In D118124#3270429 <https://reviews.llvm.org/D118124#3270429>, @MatzeB wrote:
> The thing that confuses me is that the very first thing in `LiveRegMatrix::checkInterference()` is this:
>
> if (VirtReg.empty())
> return IK_Free;
>
> so I don't see how we would even reach the `intervalIsInOneMBB` test if the live interval is empty...
Oh wait, I confused the intention of that `if` in `canEvictInterferenceBasedOnCost`.
It's still odd to have the empty interval. But adding the check for `empty()` is fine with me then. LGTM
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D118124/new/
https://reviews.llvm.org/D118124
More information about the llvm-commits
mailing list