mirror of
https://github.com/RPCS3/llvm.git
synced 2025-01-22 02:05:01 +00:00
Reflow code, no functionality change.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@151262 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
9f78379aee
commit
6a1c7796d3
@ -980,30 +980,25 @@ public:
|
||||
for (SmallVector<DbgValueInst *, 4>::const_iterator I = DVIs.begin(),
|
||||
E = DVIs.end(); I != E; ++I) {
|
||||
DbgValueInst *DVI = *I;
|
||||
Value *Arg = NULL;
|
||||
if (StoreInst *SI = dyn_cast<StoreInst>(Inst)) {
|
||||
Instruction *DbgVal = NULL;
|
||||
// If an argument is zero extended then use argument directly. The ZExt
|
||||
// may be zapped by an optimization pass in future.
|
||||
Argument *ExtendedArg = NULL;
|
||||
if (ZExtInst *ZExt = dyn_cast<ZExtInst>(SI->getOperand(0)))
|
||||
ExtendedArg = dyn_cast<Argument>(ZExt->getOperand(0));
|
||||
Arg = dyn_cast<Argument>(ZExt->getOperand(0));
|
||||
if (SExtInst *SExt = dyn_cast<SExtInst>(SI->getOperand(0)))
|
||||
ExtendedArg = dyn_cast<Argument>(SExt->getOperand(0));
|
||||
if (ExtendedArg)
|
||||
DbgVal = DIB->insertDbgValueIntrinsic(ExtendedArg, 0,
|
||||
DIVariable(DVI->getVariable()),
|
||||
SI);
|
||||
else
|
||||
DbgVal = DIB->insertDbgValueIntrinsic(SI->getOperand(0), 0,
|
||||
DIVariable(DVI->getVariable()),
|
||||
SI);
|
||||
DbgVal->setDebugLoc(DVI->getDebugLoc());
|
||||
Arg = dyn_cast<Argument>(SExt->getOperand(0));
|
||||
if (!Arg)
|
||||
Arg = SI->getOperand(0);
|
||||
} else if (LoadInst *LI = dyn_cast<LoadInst>(Inst)) {
|
||||
Instruction *DbgVal =
|
||||
DIB->insertDbgValueIntrinsic(LI->getOperand(0), 0,
|
||||
DIVariable(DVI->getVariable()), LI);
|
||||
DbgVal->setDebugLoc(DVI->getDebugLoc());
|
||||
Arg = LI->getOperand(0);
|
||||
} else {
|
||||
continue;
|
||||
}
|
||||
Instruction *DbgVal =
|
||||
DIB->insertDbgValueIntrinsic(Arg, 0, DIVariable(DVI->getVariable()),
|
||||
Inst);
|
||||
DbgVal->setDebugLoc(DVI->getDebugLoc());
|
||||
}
|
||||
}
|
||||
};
|
||||
|
Loading…
x
Reference in New Issue
Block a user