[PATCH] Mangling for intrinsic names w/function type parameters

Andrew Trick atrick at apple.com
Tue Jul 22 10:51:58 PDT 2014


> On Jul 22, 2014, at 9:33 AM, Philip Reames <listmail at philipreames.com> wrote:
> 
> On 07/21/2014 06:07 PM, Andrew Trick wrote:
>> I might be missing something. But I think that LLVM should have a small finite number of intrinsics for patchpoint, and the frontend (JIT client) should be able to pass it a symbolic target with any signature. In other words, we should always treat the target arguments as varargs from the intrinsic's point of view. That doesn't change the actual calling convention used.
> Andy, I think you may have misread the change.  The suggestion is not changing either the calling convention or the encoding of the arguments passed to the target function.  It's changing the type of the target function itself.  Instead of being an i8*, it could be a void(int)* for example.  The intrinsic would become parametric with the type of the target.
> 
> Currently, you have to explicitly bitcast your function type to an i8* before passing it to the patchpoint.  This change would remove that requirement.

Sure, but why can’t the function type be varargs so you don’t need an intrinsic for every function signature?

-Andy


>> 
>> http://reviews.llvm.org/D4608
>> 
>> 
> 





More information about the llvm-commits mailing list