AMDGPU/SI: Fix bug in SIInstrInfo::insertWaitStates() uncovered by r268260
authorTom Stellard <thomas.stellard@amd.com>
Mon, 2 May 2016 18:02:24 +0000 (18:02 +0000)
committerTom Stellard <thomas.stellard@amd.com>
Mon, 2 May 2016 18:02:24 +0000 (18:02 +0000)
commit341e293d67541115a7eeb235e94ad5e1e82f6c73
tree533c3581c4a28e5d12225929ff58ec63bc87aa86
parent456177b98fa3d807007ccfe671aae02691480e5a
AMDGPU/SI: Fix bug in SIInstrInfo::insertWaitStates() uncovered by r268260

We can't use MI->getDebugLoc() when MI is an iterator that could be
MBB.end().

llvm-svn: 268265
llvm/lib/Target/AMDGPU/SIInstrInfo.cpp