-
Notifications
You must be signed in to change notification settings - Fork 64
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
ccpp_prebuild.py: speed up recompiling unchanged code (again) #357
ccpp_prebuild.py: speed up recompiling unchanged code (again) #357
Conversation
…ists where needed to avoid differences in the auto-generated code when recompiling the same code
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure why the output should have changed if the symbol names did not (I thought they came out in dictionary sort order) but I don't see anything wrong with these changes.
Thanks for the quick review. Yes, at this point I don't want to spend too much time investigating a spurious problem that I can fix by simply replacing all |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
approved
This PR fixes an issue that has come up just recently due to unrelated build changes in the UFS. When recompiling the same, unchanged code, the auto-generated caps as well as the cmake include files can change and trigger a full recompile. While it is beyond my understanding why this didn't happen before, the solution is to make the framework more robust against such external changes:
Replace regular Python dictionaries with ordered dictionaries, sort lists where needed to avoid differences in the auto-generated code when recompiling the same code. Also: sanitize formatting in a few places. No code/answer changes.
Associated PRs:
#357
NCAR/ccpp-physics#600
NOAA-EMC/fv3atm#267
ufs-community/ufs-weather-model#498
For regression testing, see ufs-community/ufs-weather-model#498