mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2026-04-26 12:20:42 +00:00
Ignore debug info while evaluating function.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66490 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -2199,6 +2199,13 @@ static bool EvaluateFunction(Function *F, Constant *&RetVal,
|
||||
AI->getName()));
|
||||
InstResult = AllocaTmps.back();
|
||||
} else if (CallInst *CI = dyn_cast<CallInst>(CurInst)) {
|
||||
|
||||
// Debug info can safely be ignored here.
|
||||
if (isa<DbgInfoIntrinsic>(CI)) {
|
||||
++CurInst;
|
||||
continue;
|
||||
}
|
||||
|
||||
// Cannot handle inline asm.
|
||||
if (isa<InlineAsm>(CI->getOperand(0))) return false;
|
||||
|
||||
@@ -2224,7 +2231,6 @@ static bool EvaluateFunction(Function *F, Constant *&RetVal,
|
||||
return false;
|
||||
|
||||
Constant *RetVal;
|
||||
|
||||
// Execute the call, if successful, use the return value.
|
||||
if (!EvaluateFunction(Callee, RetVal, Formals, CallStack,
|
||||
MutatedMemory, AllocaTmps))
|
||||
|
||||
Reference in New Issue
Block a user