sangeeta chowdhary via llvm-dev
2018-Aug-30 22:31 UTC
[llvm-dev] Instruction does not dominate all uses!
Hello All, I am instrumenting IR to pass addres of the function to runtime but I am getting error - Instruction does not dominate all uses. I used M.dump() to get below dump, not able to figure out what I am doing wrong. Any help would be much appreciated. define dso_local double @mysqrt(double %val1) local_unnamed_addr #0 { entry: %0 = bitcast double (double)* @mysqrt to i8* %1 = call i64 @getAddr(i8* %0) call void @funcInit(i64 %1) %2 = call i64 @getRealFunArg(i32 0, i64 %1) %mul = fmul double %val1, %val1 ret double %mul } !llvm.module.flags = !{!0} !llvm.ident = !{!1} !0 = !{i32 1, !"wchar_size", i32 4} !1 = !{!"clang version 7.0.0 (trunk 336308)"} Instruction does not dominate all uses! %1 = call i64 @getAddr(i8* %0) %2 = call i64 @getRealFunArg(i32 0, i64 %1) Instruction does not dominate all uses! %1 = call i64 @getAddr(i8* %0) call void @trackReturn(i64 %1, i64 %4) LLVM ERROR: Broken function found, compilation aborted! -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20180830/e08d7231/attachment.html>
Craig Topper via llvm-dev
2018-Aug-30 23:05 UTC
[llvm-dev] Instruction does not dominate all uses!
The dump of the function seems to be from before some transformation. The trackReturn mention in the error message does not appear in it. Can you provide the dump at the failure? ~Craig On Thu, Aug 30, 2018 at 3:31 PM sangeeta chowdhary via llvm-dev < llvm-dev at lists.llvm.org> wrote:> > Hello All, > > > I am instrumenting IR to pass addres of the function to runtime but I am > getting error - Instruction does not dominate all uses. I used M.dump() to > get below dump, not able to figure out what I am doing wrong. Any help > would be much appreciated. > > > define dso_local double @mysqrt(double %val1) local_unnamed_addr #0 { > > entry: > > %0 = bitcast double (double)* @mysqrt to i8* > > %1 = call i64 @getAddr(i8* %0) > > call void @funcInit(i64 %1) > > %2 = call i64 @getRealFunArg(i32 0, i64 %1) > > > > %mul = fmul double %val1, %val1 > > > > ret double %mul > > } > > > > !llvm.module.flags = !{!0} > > !llvm.ident = !{!1} > > > !0 = !{i32 1, !"wchar_size", i32 4} > > !1 = !{!"clang version 7.0.0 (trunk 336308)"} > > Instruction does not dominate all uses! > > %1 = call i64 @getAddr(i8* %0) > > %2 = call i64 @getRealFunArg(i32 0, i64 %1) > > > Instruction does not dominate all uses! > > %1 = call i64 @getAddr(i8* %0) > > call void @trackReturn(i64 %1, i64 %4) > > LLVM ERROR: Broken function found, compilation aborted! > _______________________________________________ > LLVM Developers mailing list > llvm-dev at lists.llvm.org > http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20180830/c554df36/attachment.html>
Quentin Colombet via llvm-dev
2018-Aug-31 17:24 UTC
[llvm-dev] Instruction does not dominate all uses!
On this snippet:> Instruction does not dominate all uses! > %1 = call i64 @getAddr(i8* %0) > call void @trackReturn(i64 %1, i64 %4)We don't see the def of %4, could it be the problem? Le jeu. 30 août 2018 à 16:05, Craig Topper via llvm-dev <llvm-dev at lists.llvm.org> a écrit :> > The dump of the function seems to be from before some transformation. The trackReturn mention in the error message does not appear in it. Can you provide the dump at the failure? > > ~Craig > > > On Thu, Aug 30, 2018 at 3:31 PM sangeeta chowdhary via llvm-dev <llvm-dev at lists.llvm.org> wrote: >> >> >> Hello All, >> >> >> I am instrumenting IR to pass addres of the function to runtime but I am getting error - Instruction does not dominate all uses. I used M.dump() to get below dump, not able to figure out what I am doing wrong. Any help would be much appreciated. >> >> >> define dso_local double @mysqrt(double %val1) local_unnamed_addr #0 { >> >> entry: >> >> %0 = bitcast double (double)* @mysqrt to i8* >> >> %1 = call i64 @getAddr(i8* %0) >> >> call void @funcInit(i64 %1) >> >> %2 = call i64 @getRealFunArg(i32 0, i64 %1) >> >> >> >> %mul = fmul double %val1, %val1 >> >> >> >> ret double %mul >> >> } >> >> >> >> !llvm.module.flags = !{!0} >> >> !llvm.ident = !{!1} >> >> >> !0 = !{i32 1, !"wchar_size", i32 4} >> >> !1 = !{!"clang version 7.0.0 (trunk 336308)"} >> >> Instruction does not dominate all uses! >> >> %1 = call i64 @getAddr(i8* %0) >> >> %2 = call i64 @getRealFunArg(i32 0, i64 %1) >> >> >> Instruction does not dominate all uses! >> >> %1 = call i64 @getAddr(i8* %0) >> >> call void @trackReturn(i64 %1, i64 %4) >> >> LLVM ERROR: Broken function found, compilation aborted! >> >> _______________________________________________ >> LLVM Developers mailing list >> llvm-dev at lists.llvm.org >> http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev > > _______________________________________________ > LLVM Developers mailing list > llvm-dev at lists.llvm.org > http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev