diff options
-rw-r--r-- | llvm/include/llvm/Support/CallSite.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/llvm/include/llvm/Support/CallSite.h b/llvm/include/llvm/Support/CallSite.h index 0650b61fbcf..c4d442a5f9c 100644 --- a/llvm/include/llvm/Support/CallSite.h +++ b/llvm/include/llvm/Support/CallSite.h @@ -273,7 +273,9 @@ private: // of the op_*() functions here. See CallSite::getCallee. // if (isCall()) - return getInstruction()->op_begin(); // Unchanged (ATM) + return CallInst::ArgOffset + ? getInstruction()->op_begin() // Unchanged + : getInstruction()->op_end() - 1; // Skip Function else return getInstruction()->op_end() - 3; // Skip BB, BB, Function } |