OSDN Git Service

AMDGPU: Fix assert on ttmp registers
authorMatt Arsenault <Matthew.Arsenault@amd.com>
Wed, 18 May 2016 15:19:50 +0000 (15:19 +0000)
committerMatt Arsenault <Matthew.Arsenault@amd.com>
Wed, 18 May 2016 15:19:50 +0000 (15:19 +0000)
Use register class that does not include them when looking
for unallocated registers.

This is hit by the udiv v8i64 test in the opencl integer
conformance test, and takes a few seconds to compile in
a debug build so no test included.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@269938 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Target/AMDGPU/SIFrameLowering.cpp

index d068b8d..5c219c8 100644 (file)
@@ -26,8 +26,8 @@ static bool hasOnlySGPRSpills(const SIMachineFunctionInfo *FuncInfo,
 }
 
 static ArrayRef<MCPhysReg> getAllSGPR128() {
-  return makeArrayRef(AMDGPU::SReg_128RegClass.begin(),
-                      AMDGPU::SReg_128RegClass.getNumRegs());
+  return makeArrayRef(AMDGPU::SGPR_128RegClass.begin(),
+                      AMDGPU::SGPR_128RegClass.getNumRegs());
 }
 
 static ArrayRef<MCPhysReg> getAllSGPRs() {