Hi Team,

We are trying to embed v8 within c++ application. Through the application, 
v8 context is loaded for every new javascript. And, context is destroyed , 
on the javascript exit by the user. In this way new context is created and 
destroyed for every javascript usage. In this way, it looks heap memory 
created by a context is getting retained and not garbage collected, even 
after the context is destroyed. Please find the below code, to get clear 
idea, on what is observed.

//code executed during javascript start
Local<Context>  localContext = node::makeContext(isolate, sandbox);
persistentContext.Reset(isolate, localContext);
printf("Size of newly created context is [%ld] 
\n",persistentContext.EstimatedSize());
fflush(stdout);

//code executed during javascript exit
persistentContext.Reset();

Here, EstimatedSize() is increasing 1.5 MB for every context creation (i.e 
estimated size coming for second context created is 1.5 MB more than the 
value came for first context). Please clarify the way to debug the case. 
How EstimatedSize() increased value can be identified?. Please provide 
suggestion.

Thanks.

Regards,
Madan 

-- 
-- 
v8-users mailing list
[email protected]
http://groups.google.com/group/v8-users
--- 
You received this message because you are subscribed to the Google Groups 
"v8-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to