Skip to content
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

Memory Leak Testing #50

Closed
Denz1994 opened this issue Jan 4, 2019 · 5 comments
Closed

Memory Leak Testing #50

Denz1994 opened this issue Jan 4, 2019 · 5 comments
Assignees

Comments

@Denz1994
Copy link
Contributor

Denz1994 commented Jan 4, 2019

Opening for #48.

Memory leak testing should be tracked and documented here. I will start a test and have the reviewer of #48 confirm memory leaks aren't present.

I expect results to be similar to phetsims/masses-and-springs#339.

@Denz1994 Denz1994 self-assigned this Jan 4, 2019
@Denz1994
Copy link
Contributor Author

Denz1994 commented Jan 8, 2019

Testing on Windows 10 Chrome ( Version 71.0.3578.98 ) Incognito mode. Snapshots were taken with 15-20 intervals.

image

@Denz1994
Copy link
Contributor Author

Denz1994 commented Jan 8, 2019

I will run another test on iOS to be thorough.

@Denz1994
Copy link
Contributor Author

Denz1994 commented Jan 8, 2019

Testing on iOS (10.13.6) Chrome (71.0.3578.98) Incognito mode with 15-20 minute intervals between snapshots.

image

@Denz1994
Copy link
Contributor Author

Denz1994 commented Jan 9, 2019

In a zoom discussion with @jonathanolson it was explained that there is a better process for memory leak testing.

Process:

  1. fuzz a built version of the sim with grunt --minify.mangle=false
  2. allow sim to run for a bit
  3. run phet.chipper.queryParameters.fuzz=false in console to pause sim
  4. on each screen press resetAllButton (or setup sim in specific reproducible state)
  5. take heap snapshot
  6. run phet.chipper.queryParameters.fuzz=true in console to unpause sim
  7. repeat steps 2-7 for desired time

This process is definitely more consistant and saves time. Previously runs would be extended due to variability in object creation at the time of the heap snapshot. Steps 3-6 ensures we are always using a specific state after the sim has been running for a while and testing against that same state.

I'll rerun the test and post results here.

@Denz1994
Copy link
Contributor Author

Denz1994 commented Jan 9, 2019

Testing on iOS (10.13.6) Chrome (71.0.3578.98) Incognito mode with 30 minute intervals between snapshots.

image

The results are similar as above. There isn't anything here that stands out as a memory leak. Closing this issue. Thanks @jonathanolson for the input.

@Denz1994 Denz1994 closed this as completed Jan 9, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant