xxfxxf / chromiumembedded

Automatically exported from code.google.com/p/chromiumembedded
0 stars 0 forks source link

Good way to handle hanging JavaScript #372

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
It's possible that a JavaScript application may hang in CEF which could 
negatively affect application performance. Explore techniques for allowing the 
host application to stop/limit JavaScript execution to avoid hangs.

Original issue reported on code.google.com by magreenb...@gmail.com on 10 Oct 2011 at 3:35

GoogleCodeExporter commented 9 years ago
It seems that there's no great solution to this problem. One possibility is to 
preemption as described here:
http://groups.google.com/group/v8-users/browse_thread/thread/e285de1dad7fde98

Chrome handles this problem by killing the renderer process when it becomes 
unresponsive.

Original comment by magreenb...@gmail.com on 19 Oct 2011 at 5:42

GoogleCodeExporter commented 9 years ago
I started a thread about this on the chromium-dev mailing list:
http://groups.google.com/a/chromium.org/group/chromium-dev/browse_thread/thread/
bea5ac71c069d69

Original comment by magreenb...@gmail.com on 24 Oct 2011 at 3:50

GoogleCodeExporter commented 9 years ago
It seems that due to the V8 integration design as discussed in comment #2 it is 
not possible to restart JavaScript after terminating execution. This would 
consequently leave the browser in a broken state. As a result it will not be 
possible to support JavaScript termination in the single-process architecture. 
In the multi-process architecture we can use Chrome's approach of killing the 
renderer process if it hangs.

Original comment by magreenb...@gmail.com on 25 Oct 2011 at 5:07