Teach RegisterCoalescer to handle symmetric sub-register copies.
authorJakob Stoklund Olesen <stoklund@2pi.dk>
Tue, 15 May 2012 22:26:28 +0000 (22:26 +0000)
committerJakob Stoklund Olesen <stoklund@2pi.dk>
Tue, 15 May 2012 22:26:28 +0000 (22:26 +0000)
commitceacd6da8c31106333952f6dc4fd6e6aa98312f1
tree94f29fdf91d4537defd0d4610fb1ae6e8a5bad0d
parent70724aaf7329b8de8e53648b2a3afcbbf46ddbb7
Teach RegisterCoalescer to handle symmetric sub-register copies.

It is possible to coalesce two overlapping registers to a common
super-register that it larger than both of the original registers.

The important difference is that it may be necessary to rewrite DstReg
operands as well as SrcReg operands because the sub-register index has
changed.

This behavior is still disabled by CoalescerPair.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@156869 91177308-0d34-0410-b5e6-96231b3b80d8
lib/CodeGen/RegisterCoalescer.cpp