[LLVMdev] Compatible Return Type for Intrinsics

aditya vishnubhotla vvaditya12 at yahoo.com
Tue Feb 26 03:53:09 PST 2008



Hi,
I tried creating  intrinsics which
are to be placeholders for a set of instructions which
should not be executed by the backend.

In this process I want to replace the uses of each
instruction with the intrinsic(Call) instruction.

I am puzzled about the return type to be used in the
intrinsic defintion(for creating the intrinsic) which
is to be included in the Intrinsics.td file.

Do we need to create a number of intrinsics with
different  return types?
If so i want to know the set of types which
collectively encompass all the possibilities posed by
the instruction type

I would for example try to map all dependencies via
overloading to
 three 
intrinsic types: anyint,anyfloat and ptr_ty. Would
that be sufficient
 or is 
there any simpler approach to this? As far as i
understand void_ty
 means "no 
return value" and not the C semantics of void. The
strong type system
 makes 
me fear that this approach won't work either?

Thank You
Aditya



      ____________________________________________________________________________________
Looking for last minute shopping deals?  
Find them fast with Yahoo! Search.  http://tools.search.yahoo.com/newsearch/category.php?category=shopping



More information about the llvm-dev mailing list