From 033b2fbc0ad3b0928c72ef8dbd2e8a81bbc421b7 Mon Sep 17 00:00:00 2001 From: Minsuk Ji <57227195+MinsukJi-NOAA@users.noreply.github.com> Date: Fri, 15 Apr 2022 14:56:11 -0400 Subject: [PATCH] Bring EMC fms_mixedmode up to date with GFDL main (689579e) (#16) * get_unit warning now only prints on root_pe (#872) Co-authored-by: Eric Stofferahn * Update changelog, version numbers and build info (#873) Co-authored-by: rem1776 * chore: Change version number to next development version (#874) * CI: Update build action for yaml parser (#871) Update build actions Change images to organization's repo and fix mixed mode parser test failure * test(parser): Change real comparison value to double (#886) Co-authored-by: rem1776 * Make 'unsupported kind' error messages more descriptive. Change author of constants4.F90 * Add doxygen comment to valid_types in sat_vapor_pres/sat_vapor_pres_k.F90 * Modify codes for r8-r4 conversion to remove compiler warnings * Remove OVERLOAD_R8 directives regarding send_data_*d_r8 subroutines * Add Doxygen comments to constants4.F90 * Updates AM4 regression test suite to run intel 21 only on PW (#893) * feat: emc changes for mixedmode (#857) (#898) * Change send_data interface and any necessary routines for mixed real precision support * Adds an r4 size constants file BREAKING CHANGE: changes some argument types in diag_manager, tracer_manager, sat_vapor_pres, and time_manager from real to class(*) Co-authored-by: Minsuk Ji <57227195+MinsukJi-NOAA@users.noreply.github.com> * feat: adds option to override (ignore) checksum test when reading restarts (#889) * update to fms2_io to allow reads to ignore embedded checksums on a fileobj basis * added fms2_io test cases for the ignore_checksum option to restart reads tests the domain, domain_wrap, and bc restart options * docs: add CI information file (#899) * test: Adds check_nml_error after reading a namelist, so it could crash only as expected (#904) * Revert "feat: emc changes for mixedmode (#857) (#898)" (#914) This reverts commit 516a5efa681e5ae954c11c0c90677b4444e28ec4. * fix: clean up unused/uninitialized variables and other warnings (#859) Remove unused variables throughout and changes/removals for other warnings such as uninitialized values and implicit casts * docs: update function style and branch names * Changes master to main in CONTRIBUTING.md * Claifies function return documentation in CODE_STYLE.md * feat: adds support for logical variables in the yaml parser (#907) * Adds support for logical variables in the yaml parser * correctly determines if a string is true or false * fix: add check for affinity to self-initialize and update test program (#917) * fix: adds casts to class(*) calls to match doubles in C routines (#920) Co-authored-by: rem1776 * build: add intel code coverage build option to autotools (#895) * refactor: change to inclusive variable names (#926) * feat: Allow maximum number of restart variables to be set at build time (#909) * fix: Fixes for linter action and code style (#869) * test: Test script updates and input tests (#800) Rewrites test script to use added testing shell functions Adds previously skipped or removed unit tests and support for testing with input files Co-authored-by: Seth Underwood Co-authored-by: Uriel Ramirez * chore: 2022.01 release changes (#941) * chore: change version number to next development version (#945) * Add option for position independent code (#930) * fix: document and change parameter names for grid versions (#918) * fix: Moving empty and non-existent data table handling inside data_override (#933) Enables the processing of an empty or non-existent data_table or data_table.yaml from within data_override, so that any routine can call data_override_init without worry * fix: Removal of internal FMS use of fms_io and mpp_io (#928) * fix: mpp changes to solve compile issues with serial builds (#949) * feat: adds build option for compiling with different sets of constants (#929) * feat: add and aggregate mpp_chksum unit tests (#946) * feat: add module for string utility routines (#911) Adds module and accompanying test for common string operations * revert: reinstated the mpp_io routines and put them at the end for future elimination. (#952) * fix: add back in small_fac parameter to constants .h files (#954) * fix: root pe bug with fms2_io::flush_file (#958) * fix: clean up string routines for fms_string_utils_mod (#953) * chore: update libFMS module with new routines (#912) * fix: removes fms_c.c and fms_c.h (#961) * Make changes to lines with more than 120 columns Co-authored-by: Ryan Mulhall <35538242+rem1776@users.noreply.github.com> Co-authored-by: Eric Stofferahn Co-authored-by: rem1776 Co-authored-by: Tom Robinson <33458882+thomas-robinson@users.noreply.github.com> Co-authored-by: Rusty Benson <6594772+bensonr@users.noreply.github.com> Co-authored-by: uramirez8707 <49168881+uramirez8707@users.noreply.github.com> Co-authored-by: Raffaele Montuoro Co-authored-by: Seth Underwood Co-authored-by: Uriel Ramirez Co-authored-by: Matthew Thompson Co-authored-by: Eric <7784797+GFDL-Eric@users.noreply.github.com> --- fms/fms_c.c | 8 -------- fms/fms_c.h | 4 ---- libFMS.F90 | 11 ++++++++++- 3 files changed, 10 insertions(+), 13 deletions(-) delete mode 100644 fms/fms_c.c delete mode 100644 fms/fms_c.h diff --git a/fms/fms_c.c b/fms/fms_c.c deleted file mode 100644 index c14f448237..0000000000 --- a/fms/fms_c.c +++ /dev/null @@ -1,8 +0,0 @@ -#include -#include -#include - -char * cstring2cpointer (char * cs) -{ - return cs; -} diff --git a/fms/fms_c.h b/fms/fms_c.h deleted file mode 100644 index b9636e0fa4..0000000000 --- a/fms/fms_c.h +++ /dev/null @@ -1,4 +0,0 @@ -#include -#include -#include -char * cstring2cpointer (char * cs); diff --git a/libFMS.F90 b/libFMS.F90 index fec4e6c57b..5fa1195d79 100644 --- a/libFMS.F90 +++ b/libFMS.F90 @@ -361,7 +361,12 @@ module fms mpp_get_nest_fine_pelist, mpp_get_nest_fine_npes, & mpp_domain_UG_is_tile_root_pe, mpp_deallocate_domainUG, & mpp_get_io_domain_UG_layout, NULL_DOMAIN1D, NULL_DOMAIN2D, & - mpp_create_super_grid_domain + mpp_create_super_grid_domain, mpp_shift_nest_domains + !> parser +#ifdef use_yaml + use yaml_parser_mod, only: open_and_parse_file, get_num_blocks, get_block_ids, get_value_from_key, & + get_nkeys, get_key_ids, get_key_name, get_key_value +#endif !> platform use platform_mod, only: r8_kind, r4_kind, i8_kind, i4_kind, c8_kind, c4_kind, & @@ -377,6 +382,10 @@ module fms lookup_es3, lookup_des3, lookup_es3_des3, & lookup_es_des, compute_qs, compute_mrs, & escomp, descomp + !> string_utils + use fms_string_utils_mod, only: string, fms_array_to_pointer, fms_pointer_to_array, fms_sort_this, & + fms_find_my_string, fms_find_unique, fms_c2f_string, fms_cstring2cpointer, & + string_copy !> time_interp use time_interp_mod, only: time_interp_init, time_interp, fraction_of_year, &