mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-01-07 03:40:35 +00:00
Clear preference when it no longer makes sense.
llvm-svn: 56019
This commit is contained in:
parent
ed0ea8049f
commit
f3a3ee6d01
@ -1317,6 +1317,14 @@ bool SimpleRegisterCoalescing::JoinCopy(CopyRec &TheCopy, bool &Again) {
|
||||
}
|
||||
}
|
||||
|
||||
// If resulting interval has a preference that no longer fits because of subreg
|
||||
// coalescing, just clear the preference.
|
||||
if (ResDstInt->preference && (isExtSubReg || isInsSubReg)) {
|
||||
const TargetRegisterClass *RC = mri_->getRegClass(ResDstInt->reg);
|
||||
if (!RC->contains(ResDstInt->preference))
|
||||
ResDstInt->preference = 0;
|
||||
}
|
||||
|
||||
DOUT << "\n\t\tJoined. Result = "; ResDstInt->print(DOUT, tri_);
|
||||
DOUT << "\n";
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user