Skip to content

(closes #3475) Make OMPParallelLoopTrans respect the force_private kwarg#3476

Merged
LonelyCat124 merged 2 commits into
masterfrom
fix_omp_parallel_with_force_private
Jul 1, 2026
Merged

(closes #3475) Make OMPParallelLoopTrans respect the force_private kwarg#3476
LonelyCat124 merged 2 commits into
masterfrom
fix_omp_parallel_with_force_private

Conversation

@sergisiso

Copy link
Copy Markdown
Collaborator

This fixes one of the issues that LFRic_apps is having to adopt psyclone 3.3.

@LonelyCat124 I got a bit nervous about modifying the existing 'enable_reductions' option because it does a local options.copy() that I don't understand. So for the time being I left it as an option. I propose we unify this after the release.

@sergisiso sergisiso self-assigned this Jul 1, 2026
@codecov

codecov Bot commented Jul 1, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 100.00%. Comparing base (4216b9a) to head (bbafe92).

Additional details and impacted files
@@            Coverage Diff            @@
##            master     #3476   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files          395       395           
  Lines        55199     55215   +16     
=========================================
+ Hits         55199     55215   +16     

☔ 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.

@LonelyCat124 LonelyCat124 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah I think this is why this escaped my updates before. This transformation just force overrides specified options even if they've been provided. I think we can make this nicer later - essentially now that we have inherit=False working, we can avoid exposing the reduction_ops kwarg in the docstring, or directly on the function. This means we can always just ignore it (perhaps with a warning if reduction_ops is in **kwargs)

The options.copy() is just because the transformation can modify the dictionary and this needs to be modified, but as you say we don't need to fix this now.

I'll build the docs and check those quick, but otherwise this is ready to merge.

The only other thing is that this transformation currently won't match rules w.r.t options vs kwargs, but again not essential right now but we should fix as soon as possible after.

@sergisiso I assume this one needs merging now before the release?

@LonelyCat124

Copy link
Copy Markdown
Collaborator

All is ready to be merged if the CI passes.

@LonelyCat124 LonelyCat124 merged commit 39eb4ff into master Jul 1, 2026
16 checks passed
@LonelyCat124 LonelyCat124 deleted the fix_omp_parallel_with_force_private branch July 1, 2026 21:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants