Skip to content

Commit 8bc30e8

Browse files
authored
[SOL] Inform stack size in error message (#100)
1 parent 7d055ed commit 8bc30e8

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

llvm/lib/Target/SBF/SBFRegisterInfo.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,10 +60,12 @@ static void WarnSize(int Offset, MachineFunction &MF, DebugLoc& DL)
6060
dbgs() << " ";
6161
DL.print(dbgs());
6262
}
63+
uint64_t StackSize = MF.getFrameInfo().getStackSize();
6364
dbgs() << " Function " << MF.getFunction().getName()
6465
<< " Stack offset of " << -Offset << " exceeded max offset of "
6566
<< -MaxOffset << " by " << MaxOffset - Offset
66-
<< " bytes, please minimize large stack variables\n";
67+
<< " bytes, please minimize large stack variables. "
68+
<< "Estimated function frame size: " << StackSize << " bytes.\n\n";
6769
} else {
6870
DiagnosticInfoUnsupported DiagStackSize(
6971
MF.getFunction(),

0 commit comments

Comments
 (0)