From 7716075a1729ead67844574fdb34579894122992 Mon Sep 17 00:00:00 2001 From: James Y Knight Date: Fri, 1 Feb 2019 20:44:47 +0000 Subject: [opaque pointer types] Pass value type to GetElementPtr creation. This cleans up all GetElementPtr creation in LLVM to explicitly pass a value type rather than deriving it from the pointer's element-type. Differential Revision: https://reviews.llvm.org/D57173 llvm-svn: 352913 --- llvm/lib/Transforms/Instrumentation/DataFlowSanitizer.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'llvm/lib/Transforms/Instrumentation/DataFlowSanitizer.cpp') diff --git a/llvm/lib/Transforms/Instrumentation/DataFlowSanitizer.cpp b/llvm/lib/Transforms/Instrumentation/DataFlowSanitizer.cpp index 72f1e2ad253..3f166b11341 100644 --- a/llvm/lib/Transforms/Instrumentation/DataFlowSanitizer.cpp +++ b/llvm/lib/Transforms/Instrumentation/DataFlowSanitizer.cpp @@ -1015,7 +1015,8 @@ Value *DFSanFunction::getRetvalTLS() { Value *DFSanFunction::getArgTLS(unsigned Idx, Instruction *Pos) { IRBuilder<> IRB(Pos); - return IRB.CreateConstGEP2_64(getArgTLSPtr(), 0, Idx); + return IRB.CreateConstGEP2_64(ArrayType::get(DFS.ShadowTy, 64), + getArgTLSPtr(), 0, Idx); } Value *DFSanFunction::getShadow(Value *V) { -- cgit v1.2.3