[LLVMdev] target specific ways to extend ConstantExpr

Chris Lattner clattner at apple.com
Mon Dec 17 12:48:03 PST 2012


On Dec 17, 2012, at 11:26 AM, Yuan Lin <yulin at nvidia.com> wrote:

> I am looking for a way to allow ConstantExpr to express target specific operations, which will be used in global initializers.
>  
> The recommended way to extend LLVM IR is using intrinsic functions. But this does not work for ConstantExpr, which the global initializer uses.
>  
> Should we make ConstantExpr to support some kind of side-effect free intrinsic function calls? If we want to work on such a patch, what are the things we should look out for?
>  
> http://llvm.org/bugs/show_bug.cgi?id=10368 seems also express this desire.
>  

That PR is still accurate as to the direction I think ConstantExprs should go.  What specifically does this target-specific constant need to look like?

-Chris

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20121217/88dcb0ea/attachment.html>


More information about the llvm-dev mailing list