Issue metadata
Sign in to add a comment
|
WebGL memory leak upon refresh
Reported by
danielgj...@gmail.com,
Feb 12 2018
|
||||||||||||||||||||||||
Issue descriptionUserAgent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.140 Safari/537.36 Steps to reproduce the problem: 1. Launch a page that has WebGL content (for instance this link to a game made with WebGL as rendering context: https://ext-qa-gameservice.thunderkick.com/gamelauncher/desktopLauncher/external-lobby?gameId=tk-s1-g15&container=container 2. Open a diagnostic tool (chrome dev tools or windows task manager will work). Note the memory usage. 3. Refresh a few times (5-10 should be enough to see the pattern). What is the expected behavior? The browser should free all or most of the memory used by the tab upon refreshing the page. What went wrong? The memory usage rises for each refresh until it reaches critical system levels upon which the tab (and any other tab open as well) will crash. Crashed report ID: No How much crashed? Whole browser Is it a problem with a plugin? No Did this work before? Yes Chrome 62 Chrome version: 64.0.3282.140 Channel: stable OS Version: 10.0 Flash Version: At least we didn't note any major memory leak in the previous versions of Chrome. It is possible it was there even back then but it for sure has gotten much worse as of late.
,
Feb 12 2018
,
Feb 12 2018
,
Feb 12 2018
,
Feb 13 2018
Tested this issue on Debian Rodete with chrome Stable #64.0.3282.140 & Beta #65.0.3325.51 and observed 2 different behaviors. Observations: 1. For Stable M64, observed that browser memory usage is rising for each refresh. 3. For Beta M65, observed browser is freeing some memory and after few seconds memory usage is rising again for each refresh. Attaching the screen-cast for reference. danielgjorwell@ Could you confirm the behavior shown in M65 is the correct behavior of this issue? Thank You...
,
Feb 13 2018
I don't have M65 but I can confirm that in Chrome Canary v66 the memory is released after about 5-10 seconds. It still grows but only by about 5% per refresh (95% of memory recovered over time). Browser build discrepancy: It is very interesting that 10 refreshes in Chrome v64 grows the memory usage from 400 to 800mb (recovering to 740 after 10 seconds). Chrome Canary v66 increases memory usage from 270Mb to 400Mb but recovered to 280Mb after 10 seconds. If Chrome of later version will work as the Canary build, then I don't think we have an issue anymore. Provided it works the same for mobile devices of course.
,
Feb 13 2018
Thank you for providing more feedback. Adding requester "kkaluri@chromium.org" to the cc list and removing "Needs-Feedback" label. For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
,
Feb 13 2018
I have the same experience with OSX. When profiling the memory heap in devtools after a couple of tab-"refresh" everything from earlier "refreshes" is still in memory, all js-objects and even the document DOM tree. A refresh should release all those, as it do in Canary. Are we bound to wait for M66 for the fix, or could this be fixed with a patch? This issue becomes problematic with large projects and auto-reload-tools like BrowserSync.
,
Feb 13 2018
GPU resources owned by WebGL contexts are eagerly released when navigating away from a web page or reloading it. This report seems to be about the renderer-side CPU memory consumption and not specifically about WebGL. I reloaded the given URL many times in Chrome 66.0.3346.0 (Official Build) canary (64-bit) on macOS and seem to see a slow growth in the memory usage of the tab's renderer process, but not the GPU or browser processes. Would need a bisect and confirmation of existence of a memory leak in earlier builds of Chromium to make progress.
,
Feb 14 2018
I'm working on Google Interland project and each page-refresh raises the memory footprint twice as much. Chrome 66 is fine for me too, problems occurred with M64. Seems more like a v8/context/cache problem. Maybe the webgl context is just a coinsident, since memory leaks is more likely detected when lots of data like ArrayBuffers. In the screenshot attached I have refreshed the page 3 times. Each time a new instance of every class is created and a new DOM tree. What's interesting is that when I inspect those objects, I see a lot of "bound_this in native_bind()". On some object it the only reference in the tree. So it's maybe those bind()-calls that prevent the page from being freed from the "shared" v8 instance. I have to note that I don't have a clue on how these things work under the hood though. Since it's working good (my problem at least) in Canary, is it only to wait until that is turned into stable? Or is this thread actually helpful finding problems in the current Chrome version? In the meantime, is it possible to force a new v8-context without leaving the domain on a page refresh? At least when developing.
,
Feb 14 2018
CC'ing possible dev's form the issue 810701 @yukishiino: Can you please confirm is this issue is as same as issue 810701 ? Thanks!!
,
Feb 14 2018
The url to interland if you want to test reloading that one is: https://beinternetawesome.withgoogle.com/interland/kind-kingdom. But I think the problem occur on any site. google.com for example (see screenshot)
,
Feb 14 2018
I think that this issue is a dup of Issue 810701 . re #c12: google.com is currently showing a series of special doodles that use webaudio. Other sites that don't use webaudio look to me having no problem. |
|||||||||||||||||||||||||
►
Sign in to add a comment |
|||||||||||||||||||||||||
Comment 1 by danielgj...@gmail.com
, Feb 12 2018