Skip to content

Commit

Permalink
CodeGen: Fix assertion in ScheduleDAGMILive::scheduleMI due to llvm.d…
Browse files Browse the repository at this point in the history
…bg.value

Fix a bug in ScheduleDAGMILive::scheduleMI which causes BotRPTracker not tracking CurrentBottom in some rare cases involving llvm.dbg.value.

This issues causes amdgcn target to assert when compiling some user codes with -g.

Differential Revision: https://reviews.llvm.org/D42394

llvm-svn: 323214
  • Loading branch information
yxsamliu committed Jan 23, 2018
1 parent c58c2b5 commit 8b7454a
Show file tree
Hide file tree
Showing 2 changed files with 437 additions and 0 deletions.
1 change: 1 addition & 0 deletions llvm/lib/CodeGen/MachineScheduler.cpp
Expand Up @@ -1449,6 +1449,7 @@ void ScheduleDAGMILive::scheduleMI(SUnit *SU, bool IsTopNode) {
}
moveInstruction(MI, CurrentBottom);
CurrentBottom = MI;
BotRPTracker.setPos(CurrentBottom);
}
if (ShouldTrackPressure) {
RegisterOperands RegOpers;
Expand Down

0 comments on commit 8b7454a

Please sign in to comment.