Skip to content

Commit 0fd385c

Browse files
slydimantstellar
authored andcommitted
[CodeGen] Fixed undeclared MISchedCutoff in case of NDEBUG and LLVM_ENABLE_ABI_BREAKING_CHECKS
This patch fixes the error llvm/lib/CodeGen/MachineScheduler.cpp(755): error C2065: 'MISchedCutoff': undeclared identifier in case of NDEBUG and LLVM_ENABLE_ABI_BREAKING_CHECKS. Note MISchedCutoff is declared under #ifndef NDEBUG. Reviewed By: RKSimon Differential Revision: https://reviews.llvm.org/D130425 (cherry picked from commit adc3874)
1 parent 8371a29 commit 0fd385c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

llvm/lib/CodeGen/MachineScheduler.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -750,7 +750,7 @@ void ScheduleDAGMI::moveInstruction(
750750
}
751751

752752
bool ScheduleDAGMI::checkSchedLimit() {
753-
#if LLVM_ENABLE_ABI_BREAKING_CHECKS
753+
#if LLVM_ENABLE_ABI_BREAKING_CHECKS && !defined(NDEBUG)
754754
if (NumInstrsScheduled == MISchedCutoff && MISchedCutoff != ~0U) {
755755
CurrentTop = CurrentBottom;
756756
return false;

0 commit comments

Comments
 (0)