19 ms·
Interesting. Does WebKit run its JIT compiler in a separate thread from the actual execution? > In general, we're happy to pay compile time to get peak through
by amelius 9y ago
Interesting. Does WebKit run its JIT compiler in a separate thread from the actual execution?
> In general, we're happy to pay compile time to get peak throughput.
Shouldn't a program which runs a UI (which WebKit basically is) optimize for lowest latency instead?
- chrisseaton 9y ago> Shouldn't a program which runs a UI (which WebKit basically is) optimize for lowest latency instead? Do you want to achieve low latency with low latency, or do you want low latency and it's so important that you don't mind high latency to get it :) What I mean is yes people want lowest latency. But you can either compile quickly, to get to a reasonably low latency when using the app and to get to that point itself with low latency, or you can compile with optimisations, and get lower latency when the compilation is done but have to wait with high latency to get to that point. Both approaches are 'optimising for latency' so you'd need to be more specific. The practical compromise is tiers of compilation, each taking higher latency to apply but producing lower latency when they're done.
- gsnedders 9y ago> Shouldn't a program which runs a UI (which WebKit basically is) optimize for lowest latency instead? Note that this is only the third (top) tier JIT (or fourth if you include the interpreter). By that point, you're really optimising for throughput and not compile time.
- bzbarsky 9y agoAll the browsers do their top-tier jit on a separate thread (if not multiple threads), as far as I know, precisely so it doesn't interfere with execution.