This is a set of register units intended to track register liveness, it
is similar in spirit to LivePhysRegs.
You can also think of this as the liveness tracking parts of the
RegisterScavenger factored out into an own class.
This was proposed in http://llvm.org/PR27609
- Many of the current LivePhysRegs uses can be replaced by this (I will do that in upcoming patches). This patch only switches the internal RegisterScavenger state to show the concept. Using LiveRegUnits should be slightly more efficient than LivePhysRegs.
- It cannot completely LivePhysRegs right now, because some cases like %xmm0 vs. %ymm0 on x86 have the exact same register units but need to be differntiated for ABI reasons. (We may be able to introduce additional register units for this in another patch).
- I decided not to add forward walking support as that only works reliably with kill flags which are intended to be remove long term.
- This patch applies on top of http://reviews.llvm.org/D21885 but it shouldn't be too hard to rebase if