projects
/
oota-llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c6f00e7
)
reformulate CallSite::getCallee to adapt to CallInst::ArgOffset, and make it work...
author
Gabor Greif
<ggreif@gmail.com>
Thu, 1 Jul 2010 10:41:37 +0000
(10:41 +0000)
committer
Gabor Greif
<ggreif@gmail.com>
Thu, 1 Jul 2010 10:41:37 +0000
(10:41 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107390
91177308
-0d34-0410-b5e6-
96231b3b80d8
lib/VMCore/Instructions.cpp
patch
|
blob
|
history
diff --git
a/lib/VMCore/Instructions.cpp
b/lib/VMCore/Instructions.cpp
index e8ac392d71fb50599073c28dc7fdcaee858ec0da..a06365921808930026f6150b385fd98c170e88e8 100644
(file)
--- a/
lib/VMCore/Instructions.cpp
+++ b/
lib/VMCore/Instructions.cpp
@@
-33,7
+33,9
@@
using namespace llvm;
User::op_iterator CallSite::getCallee() const {
Instruction *II(getInstruction());
return isCall()
- ? cast<CallInst>(II)->op_begin()
+ ? (CallInst::ArgOffset
+ ? cast</*FIXME: CallInst*/User>(II)->op_begin()
+ : cast</*FIXME: CallInst*/User>(II)->op_end() - 1)
: cast<InvokeInst>(II)->op_end() - 3; // Skip BB, BB, Function
}