On 18 Apr., 17:34, Matthias Ernst <[email protected]> wrote:
> A Persistent handle to the JS instance + MakeWeak let you register a
> callback that gets invoked by V8 when that instance was determined to be
> only weakly reachable. AdjustAmountOfExternalAllocatedMemory let's you put
> "pressure" on the V8 GC - otherwise it might not run because it doesn't know
> that there's external heap behind the small wrapper.

Well, yes.. I'm completly new to v8 and try to realize that. Are there
any documentations about what "Weak" exactly means?
Seconly, what do you meah with "pressure"? The C++ instance should be
instantiated when "new MyClass" is called. Why do the GC needs to know
that there are other heap allocations?



> Pre-create the instance when you set up the FunctionTemplate for "MyTest".
> Register the instance as "data" in FunctionTemplate::New .

Thanks, this is fairly easy.

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

Reply via email to