summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Stellard <thomas.stellard@amd.com>2014-03-24 18:21:35 +0000
committerTom Stellard <thomas.stellard@amd.com>2014-03-24 18:21:35 +0000
commite359701ec27f168c31b456d069714005070ba42c (patch)
tree30ed9dacde0054d5721280e3d6f5ab7e4cbf81b3
parent4ac0136bbede0f7786eb89c8cb372a3f78c55933 (diff)
downloadllvm-e359701ec27f168c31b456d069714005070ba42c.tar.gz
llvm-e359701ec27f168c31b456d069714005070ba42c.tar.bz2
llvm-e359701ec27f168c31b456d069714005070ba42c.tar.xz
Merging r200775:
------------------------------------------------------------------------ r200775 | thomas.stellard | 2014-02-04 09:18:42 -0800 (Tue, 04 Feb 2014) | 5 lines R600/SI: Don't assume copies will be coalesced in SIFixSGPRCopies There is no lit test for this, because it would be too big and complicated, but it does fix a crash in the Arithm/Absdiff.* OpenCV test. git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_34@204644 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--lib/Target/R600/SIFixSGPRCopies.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Target/R600/SIFixSGPRCopies.cpp b/lib/Target/R600/SIFixSGPRCopies.cpp
index 3370c7955b..f0065ea13c 100644
--- a/lib/Target/R600/SIFixSGPRCopies.cpp
+++ b/lib/Target/R600/SIFixSGPRCopies.cpp
@@ -187,7 +187,7 @@ bool SIFixSGPRCopies::isVGPRToSGPRCopy(const MachineInstr &Copy,
DstRC == &AMDGPU::M0RegRegClass)
return false;
- SrcRC = inferRegClassFromDef(TRI, MRI, SrcReg, SrcSubReg);
+ SrcRC = TRI->getSubRegClass(MRI.getRegClass(SrcReg), SrcSubReg);
return TRI->isSGPRClass(DstRC) && TRI->hasVGPRs(SrcRC);
}