[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: Challenges in JIT compiling Lua
- From: Dibyendu Majumdar <mobile@...>
- Date: Wed, 22 Feb 2017 15:24:48 +0000
On 22 February 2017 at 09:19, Javier Guerra Giraldez <firstname.lastname@example.org> wrote:
> On 21 February 2017 at 23:52, Dibyendu Majumdar <email@example.com> wrote:
>> Specialise a Lua function by observing the types during execution.
>> JIT compile the specialised version.
> that's what LuaJIT does, it leaves guards (conditional branches out of
> the trace) as assertions about types, ranges, and a few other stuff
> that allows it to emit much simpler code.
Yes the approach is similar. I am thinking of function specialization
rather than specializing fragments of code, in the hope that most
functions typically could be converted to statically typed versions as
developers tend to write code that way.