about summary refs log tree commit diff homepage
diff options
context:
space:
mode:
authorJiri Slaby <jirislaby@gmail.com>2017-02-24 09:24:06 +0100
committerJiri Slaby <jirislaby@gmail.com>2017-03-01 20:41:17 +0100
commitd2aa830f8334464a1087e6dd6f093cf81aba0a55 (patch)
tree2f31589d19f75e89ccbb337d000620d94ec77ced
parent4f5ea494986689dd89f97f9a64082527557c71c9 (diff)
downloadklee-d2aa830f8334464a1087e6dd6f093cf81aba0a55.tar.gz
Core: explicitly create CallSite from Instruction
Newer LLVMs do not allow implicit conversion from Instruction to
CallSite. We see this error:
Internal/Support/ModuleUtil.h:36:19: note: candidate function not viable: no known conversion from 'llvm::Instruction *' to 'llvm::CallSite' for 1st argument
  llvm::Function *getDirectCallTarget(llvm::CallSite);
                  ^
So explicitly create a CallSite from Instruction.

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
-rw-r--r--lib/Core/StatsTracker.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Core/StatsTracker.cpp b/lib/Core/StatsTracker.cpp
index ccf6e04d..e8192a8e 100644
--- a/lib/Core/StatsTracker.cpp
+++ b/lib/Core/StatsTracker.cpp
@@ -168,7 +168,7 @@ static bool instructionIsCoverable(Instruction *i) {
       Instruction *prev = static_cast<Instruction *>(--it);
       if (isa<CallInst>(prev) || isa<InvokeInst>(prev)) {
         Function *target =
-            getDirectCallTarget(prev, /*moduleIsFullyLinked=*/true);
+            getDirectCallTarget(CallSite(prev), /*moduleIsFullyLinked=*/true);
         if (target && target->doesNotReturn())
           return false;
       }