[whatwg] Proposal for separating script downloads and execution
Boris Zbarsky
bzbarsky at MIT.EDU
Tue Feb 8 13:16:24 PST 2011
On 2/8/11 4:13 PM, Boris Zbarsky wrote:
> On 2/8/11 3:56 PM, Kyle Simpson wrote:
>> Yes, it's important to note that it's not even the *execution* of
>> JavaScript code that's actually the particular issue, but rather just
>> the parsing of it (even if invoking of the functionality is deferred
>> until later) that causes the biggest slowdown, in most cases.
>
> Here's the thing. Parsing is a black-box behavior. Nothing says a
> browser needs to do it right before execution, that it needs to happen
> on the main thread, or that it's happening at all.
Maybe I should clarify. The above is the case now. If you have
normative language that requires parsing to happen or not happen at
particular times, then presumably you also expose a way to tell whether
it's happened (otherwise the requirement is vacuous). And if you do so,
then I think you overconstrain things and prevent some browser-side
optimizations that I'd like to see happen.
-Boris
More information about the whatwg
mailing list