Re: Re: Zend JIT Open Sourced
| From: | Xinchen Hui | Date: | Wed, 04 Mar 2015 08:03:29 +0000 |
| Subject: | Re: Re: Zend JIT Open Sourced | ||
| References: | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-84277@lists.php.net to get a copy of this message | ||
On Wed, Mar 4, 2015 at 3:44 PM, Dmitry Stogov <dmitry@zend.com> wrote:
> On Tue, Mar 3, 2015 at 10:55 PM, Anthony Ferrara <ircmaxell@gmail.com>
> wrote:
>
>> Dmitry,
>>
>> >> So, let's put that to the test, shall we. I compiled and ran the
>> >> "JIT"
>> >> compiler (can we please stop calling it that, it's not).
>> >
>> >
>> > This is JIT!
>>
>> My apologies. I interpreted your reply to an earlier email that you
>> were doing all of the code generation at compile time, not at runtime.
>> I should have dug into the code a bit more earlier, but what I looked
>> at briefly before supported that interpretation.
>>
>> However after digging through zend_jit_llvm.cpp a bit more I can see
>> what you're doing now. You're basically AOT compiling from PHP
>> directly to LLVM bytecode (a file at a time), then using LLVM's VM and
>> jit compile to compile to native at runtime. Is that the correct
>> interpretation?
>>
>
> More or less right, except that term AOT is not correct.
> We compile PHP file when it's requested (just in time).
> We compile one PHP file at once, similar to what AOT compiler would do, but
> we compile directly to memory and then execute it,
With the type inference result we get in runtime.
thanks
>
> Thanks. Dmitry.
>
>
>
>>
>> Thanks,
>>
>> Anthony
>>
--
Xinchen Hui
@Laruence
http://www.laruence.com/