-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Test for memory leaks as part of code review #327
Comments
The dev version that I'll use for memory leak testing is https://phet-dev.colorado.edu/html/greenhouse-effect/1.2.0-dev.1/phet/greenhouse-effect_all_phet.html. |
The memory leak test looks good, see the screenshot below. I followed the standard procedure, so snapshot 1 is after loading the sim normally (no fuzz, no interaction). Snapshot 2 was taken after 1 minute of fuzz testing, snapshot 3 after 2 minutes, and so forth through snapshot 11. Snapshot 12 was taken 10 minutes after snapshot 11, and 13 was 10 minutes after that. The memory usage appears to stabilize at a value around 83MB, which is reasonable. I think we're good here. Closing. |
Reopening. I was just going through the code review checklist and realized this test needs to be done in Studio as well to verify that the sim isn't leaking phet-io objects. |
Phet-io memory testing using colorized data stream. This test was a bit problematic because the developer tools kept closing by themselves every 4 minutes or so, probably because they were getting overwhelmed by the amount of data being output to the console. The heap snapshot history was lost each time this happened. So, I ran the test and wrote down the memory numbers, and put it in the table below. It looks like there is no leak, and the memory usage tops out at 120 MB, which is definitely higher than the non-phet-io case, but still, I believe, acceptable.
|
Phet-io memory test in studio, local link = http://localhost:8080/studio/?sim=greenhouse-effect&locales=*&keyboardLocaleSwitcher&phetioWrapperDebug=true&phetioElementsDisplay=all&fuzz No leak detected, memory usage stabilizes around 146 MB.
|
No leaks detected, closing. |
The code is being reviewed for this sim prior to releasing the phet-io version. This issue is where the results of the memory leak testing for both the phet and phet-io brands will be recorded.
The text was updated successfully, but these errors were encountered: