[llvm-dev] Instruction does not dominate all uses!
Dipanjan Das via llvm-dev
llvm-dev at lists.llvm.org
Fri Jun 9 21:00:23 PDT 2017
LLVM 3.8.0, Ubuntu 16.04.2, 64 bit is being used to instrument IR.
====================================================
define i32 @bar() #0 {
entry:
%var = alloca [3 x i32], align 4
%0 = bitcast [3 x i32]* %var to i8*
call void @llvm.memcpy.p0i8.p0i8.i64(i8* %0, i8* bitcast ([3 x i32]*
@bar.var to i8*), i64 12, i32 4, i1 false)
%arrayidx = getelementptr inbounds [3 x i32], [3 x i32]* %var, i64 0, i64
0
%1 = load i32, i32* %arrayidx, align 4
ret i32 %1
}
=====================================================
if (AllocaInst *alloca_inst = dyn_cast<AllocaInst>(&I)) {
.
.
.
Value* var_addr = builder.CreateBitCast(alloca_inst,
Type::getInt8PtrTy(Ctx));
.
.
.
}
=====================================================
I am receiving the following error:
Instruction does not dominate all uses!
%var = alloca [3 x i32], align 4
%0 = bitcast [3 x i32]* %var to i8*
=====================================================
I can't even see any conditional statement in the IR. Can someone please
point out what I am missing?
--
Thanks & Regards,
Dipanjan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20170609/abc9d789/attachment.html>
More information about the llvm-dev
mailing list