mirror of
https://github.com/AFLplusplus/AFLplusplus.git
synced 2025-06-08 16:21:32 +00:00
fix cmplog for llvm 11-dev
This commit is contained in:
parent
5b9dfa0600
commit
a5ef93c83a
@ -23,6 +23,7 @@ sending a mail to <afl-users+subscribe@googlegroups.com>.
|
|||||||
feature is used.
|
feature is used.
|
||||||
- lowered minimum required llvm version to 3.4 (except LLVMInsTrim,
|
- lowered minimum required llvm version to 3.4 (except LLVMInsTrim,
|
||||||
which needs 3.8.0)
|
which needs 3.8.0)
|
||||||
|
- small change to cmplog to make it work with current llvm 11-dev
|
||||||
- fixed afl-gcc/afl-as that could break on fast systems reusing pids in
|
- fixed afl-gcc/afl-as that could break on fast systems reusing pids in
|
||||||
the same second
|
the same second
|
||||||
- added lots of dictionaries from oss-fuzz, go-fuzz and Jakub Wilk
|
- added lots of dictionaries from oss-fuzz, go-fuzz and Jakub Wilk
|
||||||
|
@ -892,7 +892,7 @@ static int area_is_mapped(void *ptr, size_t len) {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void __cmplog_rtn_hook(void *ptr1, void *ptr2) {
|
void __cmplog_rtn_hook(u8 *ptr1, u8 *ptr2) {
|
||||||
|
|
||||||
if (!__afl_cmp_map) return;
|
if (!__afl_cmp_map) return;
|
||||||
|
|
||||||
|
@ -93,16 +93,17 @@ bool CmpLogRoutines::hookRtns(Module &M) {
|
|||||||
std::vector<CallInst *> calls;
|
std::vector<CallInst *> calls;
|
||||||
LLVMContext & C = M.getContext();
|
LLVMContext & C = M.getContext();
|
||||||
|
|
||||||
Type * VoidTy = Type::getVoidTy(C);
|
Type *VoidTy = Type::getVoidTy(C);
|
||||||
PointerType *VoidPtrTy = PointerType::get(VoidTy, 0);
|
// PointerType *VoidPtrTy = PointerType::get(VoidTy, 0);
|
||||||
|
IntegerType *Int8Ty = IntegerType::getInt8Ty(C);
|
||||||
|
PointerType *i8PtrTy = PointerType::get(Int8Ty, 0);
|
||||||
|
|
||||||
#if LLVM_VERSION_MAJOR < 9
|
#if LLVM_VERSION_MAJOR < 9
|
||||||
Constant *
|
Constant *
|
||||||
#else
|
#else
|
||||||
FunctionCallee
|
FunctionCallee
|
||||||
#endif
|
#endif
|
||||||
c = M.getOrInsertFunction("__cmplog_rtn_hook", VoidTy, VoidPtrTy,
|
c = M.getOrInsertFunction("__cmplog_rtn_hook", VoidTy, i8PtrTy, i8PtrTy
|
||||||
VoidPtrTy
|
|
||||||
#if LLVM_VERSION_MAJOR < 5
|
#if LLVM_VERSION_MAJOR < 5
|
||||||
,
|
,
|
||||||
NULL
|
NULL
|
||||||
|
Loading…
x
Reference in New Issue
Block a user