On 2012/10/09 06:30:47, Sven Panne wrote:
I took a look into the WebKit issue, and I think that your problems are
related
to the currently broken External class: Although it is declared as a subclass
of
Value (i.e. promises to return a JavaScript object), Wrap/New can currently return an internal object (a Foreign), which in turn causes the assertion you
mention in the isssue to be triggered.

Yes, that's what causes the ASSERT.

I think the current CL is probably not needed when we agree on the proposal I
suggested last week: Add an API for accessing aligned pointers, making
External
a real Value, and deprecating the old unaligned pointer API plus Wrap/Unwrap.

That's certainly possible.

What's going on here is that we have a class (V8PerContextData) that holds a
bunch of WebKit data associated with a v8::Context. We need to be able to get
to that object quickly from a handle to a v8::Context.  I don't particularly
care what mechanism we use---just as long as it is fast.  :)

I ran into trouble with v8::Context::SetData because of the External/Foreign
issue.  I also had trouble removing all of the WebKit-side code that's using
SetData because there's a bunch of code that integrates with the V8 debugger
that reads the data from JavaScript (rather than from C++). Even if we solve the External/Foreign issue, I'm not sure if I actually use SetData because of
that issue.

https://codereview.chromium.org/11087020/

--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev

Reply via email to