about summary refs log tree commit diff homepage
path: root/lib/Module/Passes.h
diff options
context:
space:
mode:
authorJulian Büning <julian.buening@rwth-aachen.de>2018-11-04 11:34:10 +0100
committerCristian Cadar <c.cadar@imperial.ac.uk>2019-03-05 15:15:39 +0000
commit7e33d5cb292c88ae10f4a0ffa86c498168fbe16a (patch)
tree769f3ff2ba656810198fe7a4416058c68f6096f0 /lib/Module/Passes.h
parentd5de3df2c7e481426c39220072b42dfd307a3526 (diff)
downloadklee-7e33d5cb292c88ae10f4a0ffa86c498168fbe16a.tar.gz
workaround for LLVM PR39177
provides a workaround for LLVM bug PR39177, which affects LLVM
versions 3.9 - 7.0.0: https://bugs.llvm.org/show_bug.cgi?id=39177

This commit is intended to be reverted once support for LLVM
versions <= 7 is dropped from KLEE.
Diffstat (limited to 'lib/Module/Passes.h')
-rw-r--r--lib/Module/Passes.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/lib/Module/Passes.h b/lib/Module/Passes.h
index 9d39e8f2..417ebe7d 100644
--- a/lib/Module/Passes.h
+++ b/lib/Module/Passes.h
@@ -173,6 +173,18 @@ public:
   bool runOnModule(llvm::Module &M) override;
   bool checkPassed() const { return instructionOperandsConform; }
 };
+
+#ifdef USE_WORKAROUND_LLVM_PR39177
+/// WorkaroundLLVMPR39177Pass - Workaround for LLVM PR39177 within KLEE repo.
+/// For more information on this, please refer to the comments in
+/// cmake/workaround_llvm_pr39177.cmake
+class WorkaroundLLVMPR39177Pass : public llvm::ModulePass {
+public:
+  static char ID;
+  WorkaroundLLVMPR39177Pass() : llvm::ModulePass(ID) {}
+  bool runOnModule(llvm::Module &M) override;
+};
+#endif
 } // namespace klee
 
 #endif