Stackmaps [6/6] JavaScript calling convention.

Andrew Trick atrick at apple.com
Fri Oct 18 13:25:01 PDT 2013


On Oct 18, 2013, at 12:00 PM, Rafael Espíndola <rafael.espindola at gmail.com> wrote:

> On 18 October 2013 01:45, Andrew Trick <atrick at apple.com> wrote:
>> This one of a series of patches to support webkit intrinsics. See the llvm-dev thread "Stackmap and Patchpoint Intrinsic Proposal".
>> 
>> This patch introduces a very simple calling convention for JavaScript that pushes arguments on the stack and returns a value in RAX.
>> 
> 
> Why can't the JS engine use the regular C calling convention?

It could, with more work on the WebKit side. The WebKit_JS convention just matches the expected argument layout. It seems consistent with other language-specific conventions defined by LLVM. I’d be happy to generalize it and just call it a stack-based convention.

-Andy



More information about the llvm-commits mailing list