Bug 68237 - [V8] REGRESSION(94783): calling the binding script during V8 context creation slows down page loads
Summary: [V8] REGRESSION(94783): calling the binding script during V8 context creation...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebGL (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Ulan Degenbaev
URL:
Keywords:
Depends on: 63644 68015
Blocks: 68890
  Show dependency treegraph
 
Reported: 2011-09-16 03:48 PDT by Ulan Degenbaev
Modified: 2011-09-27 05:04 PDT (History)
4 users (show)

See Also:


Attachments
Call the binding script lazily (11.57 KB, patch)
2011-09-16 03:55 PDT, Ulan Degenbaev
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Ulan Degenbaev 2011-09-16 03:48:11 PDT
See http://code.google.com/p/chromium/issues/detail?id=96354 .

A possible fix is to call the script lazily on the first run of the 'set()' method of a typed array.
Comment 1 Ulan Degenbaev 2011-09-16 03:55:01 PDT
Created attachment 107631 [details]
Call the binding script lazily
Comment 2 Kenneth Russell 2011-09-16 11:01:26 PDT
Comment on attachment 107631 [details]
Call the binding script lazily

View in context: https://bugs.webkit.org/attachment.cgi?id=107631&action=review

This looks good overall, thanks. I have one comment about the robustness of the code, but because this is such a high priority issue in Chromium I'm going to mark this r+ / cq+ and we can deal with the robustness issue later.

> Source/WebCore/bindings/v8/custom/V8ArrayBufferViewCustom.cpp:42
> +    v8::Handle<v8::Object> arrayBufferView = prototype->GetPrototype().As<v8::Object>();

Is there a more robust way to either find the ArrayBufferView prototype or check that we've found it with this walk? In a future version of the typed array spec a subtype of Uint8Array may be added (see http://www.khronos.org/registry/typedarray/specs/latest/#7.1 ) and this code would break if so.
Comment 3 WebKit Review Bot 2011-09-16 19:30:05 PDT
Comment on attachment 107631 [details]
Call the binding script lazily

Clearing flags on attachment: 107631

Committed r95354: <http://trac.webkit.org/changeset/95354>
Comment 4 WebKit Review Bot 2011-09-16 19:30:10 PDT
All reviewed patches have been landed.  Closing bug.