-
Notifications
You must be signed in to change notification settings - Fork 104
linear_model app with UM_PHYSICS compiler flag set to true #502
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
Merged
James Bruten (james-bruten-mo)
merged 20 commits into
MetOffice:main
from
cjohnson-pi:ifdefphys
Jun 19, 2026
Merged
Changes from all commits
Commits
Show all changes
20 commits
Select commit
Hold shift + click to select a range
42c51b7
Add ifdef UM_PHYS, linear_model example runs
cjohnson-pi 3f79afc
retry copying optimisation from lfric_atm]
cjohnson-pi f6f1a06
linear_model and lfric_atm run
cjohnson-pi 0f9e2be
clearwhitespace
cjohnson-pi 9bf79cb
removing PHYSICS_ROOT change
cjohnson-pi 5f68c17
increase build wallclock
cjohnson-pi 70c1ce1
Merge remote-tracking branch 'upstream/stable' into ifdefphys
cjohnson-pi 0efabc0
use_physics false
cjohnson-pi 23a5abb
correct for validate_rose-meta. Test suite completes.
cjohnson-pi eaaba2a
use lfric_atm optimisation options
cjohnson-pi 3d3e72e
tidy
cjohnson-pi bcad2f5
revert jedi changes
cjohnson-pi db5d9a2
whitespace
cjohnson-pi 339b0b0
update build
cjohnson-pi b9da623
Make switch less strict, for jedi tests
cjohnson-pi fc48bb0
Merge branch 'main' into ifdefphys
james-bruten-mo 58011c4
Fix indentation for extracting external metadata message
james-bruten-mo 1c0df0e
Copy build options from lfric_atm
cjohnson-pi 1c551e7
Updates since merge from main
cjohnson-pi 7d4cfe5
Merge remote-tracking branch 'origin/main' into ifdefphys
james-bruten-mo File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,45 @@ | ||
| ############################################################################## | ||
| # (c) Crown copyright 2017-2026 Met Office. All rights reserved. | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. If its a new file - should it just be 2026?
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Not sure. It was copied from lfric_atm, which started with 2017. Happy to be advised by code reviewer. |
||
| # The file LICENCE, distributed with this code, contains details of the terms | ||
| # under which the code may be used. | ||
| ############################################################################## | ||
|
|
||
| # NOTE: Import of compile options from LFRic infrastructure is temporarily | ||
| # suspended here as a workaround for #2340 in which application of the | ||
| # -qoverride-limits option was preventing compilation of a UKCA module. | ||
| # include $(LFRIC_BUILD)/compile_options.mk | ||
|
|
||
| $(info UM physics specific compile options) | ||
|
|
||
| include $(PROJECT_DIR)/build/fortran/$(FORTRAN_COMPILER).mk | ||
|
|
||
| casim/%.o: private FFLAGS_EXTRA = $(FFLAGS_UM_PHYSICS) | ||
| ukca/%.o: private FFLAGS_EXTRA = $(FFLAGS_UM_PHYSICS) | ||
| jules/%.o: private FFLAGS_EXTRA = $(FFLAGS_UM_PHYSICS) | ||
| socrates/%.o: private FFLAGS_EXTRA = $(FFLAGS_UM_PHYSICS) | ||
| legacy/%.o: private FFLAGS_EXTRA = $(FFLAGS_UM_PHYSICS) | ||
| AC_assimilation/%.o: private FFLAGS_EXTRA = $(FFLAGS_UM_PHYSICS) | ||
| aerosols/%.o: private FFLAGS_EXTRA = $(FFLAGS_UM_PHYSICS) | ||
| atmosphere_service/%.o: private FFLAGS_EXTRA = $(FFLAGS_UM_PHYSICS) | ||
| boundary_layer/%.o: private FFLAGS_EXTRA = $(FFLAGS_UM_PHYSICS) | ||
| carbon/%.o: private FFLAGS_EXTRA = $(FFLAGS_UM_PHYSICS) | ||
| convection/%.o: private FFLAGS_EXTRA = $(FFLAGS_UM_PHYSICS) | ||
| diffusion_and_filtering/%.o: private FFLAGS_EXTRA = $(FFLAGS_UM_PHYSICS) | ||
| dynamics/%.o: private FFLAGS_EXTRA = $(FFLAGS_UM_PHYSICS) | ||
| dynamics_advection/%.o: private FFLAGS_EXTRA = $(FFLAGS_UM_PHYSICS) | ||
| electric/%.o: private FFLAGS_EXTRA = $(FFLAGS_UM_PHYSICS) | ||
| free_tracers/%.o: private FFLAGS_EXTRA = $(FFLAGS_UM_PHYSICS) | ||
| gravity_wave_drag/%.o: private FFLAGS_EXTRA = $(FFLAGS_UM_PHYSICS) | ||
| idealised/%.o: private FFLAGS_EXTRA = $(FFLAGS_UM_PHYSICS) | ||
| large_scale_cloud/%.o: private FFLAGS_EXTRA = $(FFLAGS_UM_PHYSICS) | ||
| large_scale_precipitation/%.o: private FFLAGS_EXTRA = $(FFLAGS_UM_PHYSICS) | ||
| PWS_diagnostics/%.o: private FFLAGS_EXTRA = $(FFLAGS_UM_PHYSICS) | ||
| radiation_control/%.o: private FFLAGS_EXTRA = $(FFLAGS_UM_PHYSICS) | ||
| stochastic_physics/%.o: private FFLAGS_EXTRA = $(FFLAGS_UM_PHYSICS) | ||
| tracer_advection/%.o: private FFLAGS_EXTRA = $(FFLAGS_UM_PHYSICS) | ||
| %/limited_area_constants_mod.o: private FFLAGS_EXTRA = $(FFLAGS_INTEL_FIX_ARG) | ||
|
|
||
| $(info Disable warnings-turned-error caused by undeclared external functions - see ifort.mk) | ||
| %mpi_mod.o: private FFLAGS_EXTRA = $(FFLAGS_INTEL_EXTERNALS) | ||
| socrates/src/radiance_core/%.o: private FFLAGS_EXTRA = $(FFLAGS_INTEL_EXTERNALS) | ||
| socrates/src/interface_core/%.o: private FFLAGS_EXTRA = $(FFLAGS_INTEL_EXTERNALS) | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,13 @@ | ||
| ############################################################################## | ||
| # (c) Crown copyright 2017 Met Office. All rights reserved. | ||
| # The file LICENCE, distributed with this code, contains details of the terms | ||
| # under which the code may be used. | ||
| ############################################################################## | ||
| # Various things specific to the Cray Fortran compiler. | ||
| ############################################################################## | ||
|
|
||
| $(info Project specials for Cray compiler) | ||
|
|
||
| export FFLAGS_UM_PHYSICS = -s real64 | ||
|
|
||
| include $(PROJECT_DIR)/build/fortran/crayftn/$(PROFILE).mk |
55 changes: 55 additions & 0 deletions
55
applications/linear_model/build/fortran/crayftn/fast-debug.mk
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,55 @@ | ||
| ############################################################################## | ||
| # (c) Crown copyright 2025 Met Office. All rights reserved. | ||
| # The file LICENCE, distributed with this code, contains details of the terms | ||
| # under which the code may be used. | ||
| ############################################################################## | ||
| ############################################################################## | ||
| # Various things specific to fast-debug lfric_atm when using the | ||
| # Cray Fortran compiler. | ||
| # To override flags specified in LFRic Core, use | ||
| # FFLAGS_SAFE_OPTIMISATION, to add an additional flag to what is specified | ||
| # in Core, use FFLAGS_EXTRA. If you need to add debugging flags to a module, | ||
| # modify FFLAGS_DEBUG for the target module. | ||
| # All flag modification should be `private` so they are not inherited by | ||
| # submodules. | ||
| ############################################################################## | ||
|
|
||
| # ========================================================================== | ||
| # NON-DEBUG FLAGS | ||
| # ========================================================================== | ||
| # UKCA | ||
| %ukca_emiss_mode_mod.o: private FFLAGS_SAFE_OPTIMISATION = -O0 | ||
| %ukca_step_control_mod.o: private FFLAGS_SAFE_OPTIMISATION = -O0 | ||
|
|
||
| # UM | ||
| %parcel_ascent_5a.o: private FFLAGS_EXTRA = $(FFLAGS_UM_PHYSICS) -hvector0 | ||
|
|
||
| # LFRic Apps | ||
| %aerosol_ukca_alg_mod_psy.o: private FFLAGS_SAFE_OPTIMISATION = -O0 | ||
| %bl_exp_alg_mod_psy.o: private FFLAGS_SAFE_OPTIMISATION = -O0 | ||
| %bl_imp_alg_mod_psy.o: private FFLAGS_SAFE_OPTIMISATION = -O0 | ||
| %conv_comorph_alg_mod_psy.o: private FFLAGS_SAFE_OPTIMISATION = -O0 | ||
| %conv_comorph_kernel_mod.o: private FFLAGS_SAFE_OPTIMISATION = -O0 | ||
| %conv_gr_alg_mod_psy.o: private FFLAGS_SAFE_OPTIMISATION = -O0 | ||
| %gungho_model_mod.o: private FFLAGS_SAFE_OPTIMISATION = -O0 | ||
| %init_aerosol_fields_alg_mod_psy.o: private FFLAGS_SAFE_OPTIMISATION = -O0 | ||
| %jules_extra_kernel_mod.o: private FFLAGS_SAFE_OPTIMISATION = -O0 | ||
| large_scale_precipitation/%.o: private FFLAGS_SAFE_OPTIMISATION = -O2 -hfp0 -hflex_mp=strict | ||
|
|
||
| # ========================================================================== | ||
| # DEBUG FLAGS | ||
| # ========================================================================== | ||
| # UKCA | ||
| %ukca_emiss_mode_mod.o: private FFLAGS_DEBUG = -G0 | ||
| %ukca_step_control_mod.o: private FFLAGS_DEBUG = -G0 | ||
|
|
||
| # LFRic Apps | ||
| %aerosol_ukca_alg_mod_psy.o: private FFLAGS_DEBUG = -G0 | ||
| %bl_exp_alg_mod_psy.o: private FFLAGS_DEBUG = -G0 | ||
| %bl_imp_alg_mod_psy.o: private FFLAGS_DEBUG = -G0 | ||
| %conv_comorph_alg_mod_psy.o: private FFLAGS_DEBUG = -G0 | ||
| %conv_comorph_kernel_mod.o: private FFLAGS_DEBUG = -G0 | ||
| %conv_gr_alg_mod_psy.o: private FFLAGS_DEBUG = -G0 | ||
| %gungho_model_mod.o: private FFLAGS_DEBUG = -G0 | ||
| %init_aerosol_fields_alg_mod_psy.o: private FFLAGS_DEBUG = -G0 | ||
| %jules_extra_kernel_mod.o: private FFLAGS_DEBUG = -G0 |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
Im not sure what the policy is but I think the start date here should not change.
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.
The makefile was copied from lfric_atm which has a start date of 2017. Happy to be advised by the code reviewer.