mirror of
https://github.com/RPCS3/llvm.git
synced 2024-12-15 16:09:57 +00:00
AMDGPU: Change unreachable into reported error
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@239943 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
a2495334bd
commit
dd8f10201c
@ -338,8 +338,10 @@ void AMDGPUAsmPrinter::getSIProgramInfo(SIProgramInfo &ProgInfo,
|
||||
ProgInfo.NumSGPR = MaxSGPR + 1;
|
||||
|
||||
if (STM.hasSGPRInitBug()) {
|
||||
if (ProgInfo.NumSGPR > AMDGPUSubtarget::FIXED_SGPR_COUNT_FOR_INIT_BUG)
|
||||
llvm_unreachable("Too many SGPRs used with the SGPR init bug");
|
||||
if (ProgInfo.NumSGPR > AMDGPUSubtarget::FIXED_SGPR_COUNT_FOR_INIT_BUG) {
|
||||
LLVMContext &Ctx = MF.getFunction()->getContext();
|
||||
Ctx.emitError("too many SGPRs used with the SGPR init bug");
|
||||
}
|
||||
|
||||
ProgInfo.NumSGPR = AMDGPUSubtarget::FIXED_SGPR_COUNT_FOR_INIT_BUG;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user