Skip to content

Feature/remove compiler workarounds#93

Merged
wdeconinck merged 2 commits into
developfrom
feature/remove_compiler_workarounds
Jun 8, 2026
Merged

Feature/remove compiler workarounds#93
wdeconinck merged 2 commits into
developfrom
feature/remove_compiler_workarounds

Conversation

@wdeconinck

Copy link
Copy Markdown
Member

This pull request removes workarounds for old compiler bugs (specifically for PGI/NVHPC and XL Fortran), and simplifies the code by eliminating related macros and conditional logic. All code now consistently uses the standard c_ptr() method and direct Fortran allocation syntax for character variables, improving maintainability and clarity.

The most important changes are:

Removal of compiler bug workarounds:

  • Removed all logic and macros related to the PGIBUG_ATLAS_197 workaround for PGI/NVHPC compilers, including conditional use of CPTR_PGIBUG_A/B and related preprocessor logic in both the CMake configuration and Fortran header/template files.
  • Removed the workaround macro FCKIT_ALLOCATE_CHARACTER and the associated XL Fortran bug logic, replacing all usages with direct Fortran allocation using character(len=...,kind=c_char).

Code simplification and modernization:

  • Updated all Fortran code to use the standard c_ptr() member function directly instead of the workaround macros, ensuring consistent pointer handling throughout the codebase.
  • Replaced all usages of the removed macros with direct allocation syntax for character variables, improving code clarity and reducing reliance on preprocessor directives.

These changes collectively modernize the codebase by removing legacy support for obsolete compiler bugs and making the code simpler and easier to maintain.

@wdeconinck wdeconinck force-pushed the feature/remove_compiler_workarounds branch from 2aae5cb to d28f00e Compare June 5, 2026 19:05
@codecov-commenter

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 33.33333% with 42 lines in your changes missing coverage. Please review.
✅ Project coverage is 51.07%. Comparing base (d2a0ac1) to head (d28f00e).

Files with missing lines Patch % Lines
src/fckit/module/fckit_mpi.fypp 0.00% 21 Missing ⚠️
src/fckit/module/fckit_configuration.F90 51.85% 13 Missing ⚠️
src/fckit/module/fckit_exception.F90 0.00% 4 Missing ⚠️
src/fckit/module/fckit_buffer.F90 0.00% 2 Missing ⚠️
src/fckit/module/fckit_C_interop.F90 50.00% 1 Missing ⚠️
src/fckit/module/fckit_refcount.F90 0.00% 1 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff            @@
##           develop      #93   +/-   ##
========================================
  Coverage    51.07%   51.07%           
========================================
  Files           58       58           
  Lines         4854     4854           
  Branches       453      453           
========================================
  Hits          2479     2479           
  Misses        2375     2375           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@wdeconinck wdeconinck merged commit 76a37e5 into develop Jun 8, 2026
377 of 378 checks passed
@wdeconinck wdeconinck deleted the feature/remove_compiler_workarounds branch June 8, 2026 11:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants