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

Continue profiling and reducing GC pressure in Terra Firma. #895

Open
bryanedds opened this issue Nov 15, 2024 · 3 comments
Open

Continue profiling and reducing GC pressure in Terra Firma. #895

bryanedds opened this issue Nov 15, 2024 · 3 comments
Labels
performance issues or potential issues relating to performance todo issue related to testing or other tertiary tasks

Comments

@bryanedds
Copy link
Owner

We've cut down GC pressure here a great deal by using the Scitech profiler like so -

image

This is an effective profiler, but it's hard to learn to use the right way.

@bryanedds bryanedds added todo issue related to testing or other tertiary tasks performance issues or potential issues relating to performance labels Nov 15, 2024
@bryanedds
Copy link
Owner Author

It might make sense to defer this until after we update to .NET 9 so some of our optimizations could become unnecessary with the new escape analysis optimizations.

@bryanedds
Copy link
Owner Author

bryanedds commented Nov 16, 2024

With .NET 9 and more optimizations, we're down to 0.5mb / frame. .NET 9 only seemed to provide a very tiny of allocation reduction.

@bryanedds
Copy link
Owner Author

bryanedds commented Nov 17, 2024

Unfortunately, the biggest optimizations resulted in regressions with undo / redo. We had revert those bits, which brings us back up to 0.8mb / frame. However, doing a more recent comparison between .NET 8 and 9 shows that we actually got a significant reduction in GC pressure (from 1.1mb to 0.8), so it looks like the object stack allocation is, in fact, doing some useful lifting.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
performance issues or potential issues relating to performance todo issue related to testing or other tertiary tasks
Projects
None yet
Development

No branches or pull requests

1 participant