Fix verification that a PhysReg is live in to an MBB.
isLiveIn does not handle reg units, so cannot identify when a
register would be defined because its super register is partially
defined.
Additionally a PhysReg may be partial defined at block entry and
then fully defined before any use.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Unit Tests
Event Timeline
Could you still check that at least one aliasing registers is in the liveins? (Much as I am loath to suggest new uses of MCRegAliasIterator.)
Do you have a test case? Does it only show up before PHIElimination, and if so why?
Yes, we can check aliases -- this is only compiled with debug and so it's probably acceptable.
Do you have a test case? Does it only show up before PHIElimination, and if so why?
This happens during / post-RA; however, normally we do not generate/regenerate LiveIntervals at this point hence this is an edge case.
Seems reasonable. I wonder if you could get an IR test with llc -early-live-intervals.
llvm/lib/CodeGen/LiveRangeCalc.cpp | ||
---|---|---|
223 | This looks like a job for /*IncludeSelf=*/true, but I guess it wouldn't actually shorten the code much the way you've written it. |
This looks like a job for /*IncludeSelf=*/true, but I guess it wouldn't actually shorten the code much the way you've written it.