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

Make KE functional #3489

Merged
merged 1 commit into from
Dec 21, 2024
Merged

Make KE functional #3489

merged 1 commit into from
Dec 21, 2024

Conversation

charleskawczynski
Copy link
Member

This PR changes kinetic_energy! to be functional.

Some advantages to this form:

  • It's easier to test (we can test it for a single point instead of a full field)
  • It's easier to fuse because the function kinetic_energy! is effectively manually inlined
  • It uses less parameter memory. This is because the broadcast expression only has one variable per used variable. For example, before we had local_geometry_halflevel that occurred in multiple places.

@charleskawczynski charleskawczynski added this pull request to the merge queue Dec 20, 2024
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to no response for status checks Dec 20, 2024
@charleskawczynski charleskawczynski merged commit 9759094 into main Dec 21, 2024
16 checks passed
@charleskawczynski charleskawczynski deleted the ck/functional1 branch December 21, 2024 00:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants