aboutsummaryrefslogtreecommitdiff
path: root/instrumentation/SanitizerCoveragePCGUARD.so.cc
diff options
context:
space:
mode:
authortoka <tokazerkje@outlook.com>2023-10-14 11:14:10 +0200
committertoka <tokazerkje@outlook.com>2023-10-14 11:14:10 +0200
commit9db9cc80e39789a2b4fd11a4631576c9a0cbb0d8 (patch)
treeccc518285daf9f62d0bc2ffd7f434b80caf325a3 /instrumentation/SanitizerCoveragePCGUARD.so.cc
parentaf18f2c7325551e8045a6156cb5b0ed2f4841dbf (diff)
downloadAFLplusplus-9db9cc80e39789a2b4fd11a4631576c9a0cbb0d8.tar.gz
EarlyEPCallback for llvm16
Diffstat (limited to 'instrumentation/SanitizerCoveragePCGUARD.so.cc')
-rw-r--r--instrumentation/SanitizerCoveragePCGUARD.so.cc6
1 files changed, 5 insertions, 1 deletions
diff --git a/instrumentation/SanitizerCoveragePCGUARD.so.cc b/instrumentation/SanitizerCoveragePCGUARD.so.cc
index 98c5973c..4f81ac4f 100644
--- a/instrumentation/SanitizerCoveragePCGUARD.so.cc
+++ b/instrumentation/SanitizerCoveragePCGUARD.so.cc
@@ -214,7 +214,11 @@ llvmGetPassPluginInfo() {
#if LLVM_VERSION_MAJOR == 13
using OptimizationLevel = typename PassBuilder::OptimizationLevel;
#endif
- PB.registerOptimizerLastEPCallback(
+#if LLVM_VERSION_MAJOR >= 16
+ PB.registerOptimizerEarlyEPCallback(
+#else
+ PB.registerOptimizerLastEPCallback()
+#endif
[](ModulePassManager &MPM, OptimizationLevel OL) {
MPM.addPass(ModuleSanitizerCoverageAFL());