about summary refs log tree commit diff homepage
path: root/lib/Core
diff options
context:
space:
mode:
authorLukas Zaoral <lzaoral@redhat.com>2021-08-24 13:59:32 +0200
committerMartinNowack <2443641+MartinNowack@users.noreply.github.com>2021-12-20 14:36:51 +0000
commit49935def640a19b6dccf69c33be65d3798ea218a (patch)
tree193c54d50da8e5a39fd4082ffd6b8e1fead4eabc /lib/Core
parentebba5c50806d2c67a357ce8091ad861dfa0f434f (diff)
downloadklee-49935def640a19b6dccf69c33be65d3798ea218a.tar.gz
llvm13: CreateGEP no longer accepts nullptr
See: https://reviews.llvm.org/D105653
Diffstat (limited to 'lib/Core')
-rw-r--r--lib/Core/ExternalDispatcher.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Core/ExternalDispatcher.cpp b/lib/Core/ExternalDispatcher.cpp
index b1bfff47..e43a8a83 100644
--- a/lib/Core/ExternalDispatcher.cpp
+++ b/lib/Core/ExternalDispatcher.cpp
@@ -303,7 +303,7 @@ Function *ExternalDispatcherImpl::createDispatcher(Function *target,
     auto argTy =
         (i < FTy->getNumParams() ? FTy->getParamType(i) : (*ai)->getType());
     auto argI64p =
-        Builder.CreateGEP(nullptr, argI64s,
+        Builder.CreateGEP(argI64s->getType()->getPointerElementType(), argI64s,
                           ConstantInt::get(Type::getInt32Ty(ctx), idx));
 
     auto argp = Builder.CreateBitCast(argI64p, PointerType::getUnqual(argTy));