[LLVMdev] Return Type of Call Function with nested bitcast
Manish Gupta
manishg at cs.ucsd.edu
Mon Jul 7 16:47:46 PDT 2014
Hi All,
I am facing an issue with CallInst with nested bitcast instruction. I want
to check if the return type of a call is void or non-void the below line
works well for CallInst without bit cast.
*cast<CallInst>(I)->getCalledFunction()->getReturnType()->isVoidTy()*
But for Call instructions like
*call void bitcast (void (%struct.jpeg_compress_struct.131*, i32)*
@jinit_c_master_control to void (%struct.jpeg_compress_struct.109*,
i32)*)(%struct.jpeg_compress_struct.109* %0, i32 0)*
getCalledFuncion returns null and the pass crashes.
Thanks!
Manish
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20140707/0b83ba57/attachment.html>
More information about the llvm-dev
mailing list