Skip to content

SCC26 Practice Problem Prep - #1731

Open
wilfonba wants to merge 3 commits into
MFlowCode:masterfrom
wilfonba:SCC26
Open

SCC26 Practice Problem Prep#1731
wilfonba wants to merge 3 commits into
MFlowCode:masterfrom
wilfonba:SCC26

Conversation

@wilfonba

Copy link
Copy Markdown
Contributor

This PR makes 2 changes in preparation for the SCC26 practice problems:

  1. It adds one line to s_convert_conservative_to_primitive to circumvent a performance regression with AMDFlang
  2. It enhances the examples/2D_shockdroplet/case.py file

Copilot AI lite review requested due to automatic review settings August 17, 2026 19:45
@wilfonba
wilfonba requested a review from sbryngelson as a code owner August 17, 2026 19:45
@wilfonba wilfonba changed the title update shockdroplet case and add AMDFlang workaround SCC26 Practice Problem Prep Aug 17, 2026
@github-actions

Copy link
Copy Markdown

Claude Code Review

Head SHA: f97535b

Files changed:

  • 2
  • examples/2D_shockdroplet/case.py
  • src/common/m_variables_conversion.fpp

Findings:

  • src/common/m_variables_conversion.fpp:427 — The new local use m_global_parameters_common, only: shear_indices ("Performance fix with AMDFlang") is added only to s_convert_conservative_to_primitive_variables, but that subroutine's GPU_PARALLEL_LOOP (line 461) calls s_compute_pressure (line 622), which is itself a GPU_ROUTINE (line 73) and independently references shear_indices via host association through m_global_parameters (line 112) — untouched by this fix. If host-associated access to shear_indices inside device code is the actual AMD flang problem, the same issue still occurs one call frame down, inside the very GPU kernel this change targets, since s_compute_pressure's own use statements are unaffected by the caller's local import.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Prepares the MFC codebase for SCC26 practice problems by addressing a compiler-related performance regression in the conservative→primitive conversion path and improving the configurability of the 2D_shockdroplet example case (plus a regenerated test artifact).

Changes:

  • Add a local import of shear_indices in s_convert_conservative_to_primitive_variables (intended AMDFlang performance workaround).
  • Enhance examples/2D_shockdroplet/case.py with CLI arguments and derived shock/post-shock/time-stepping parameters.
  • Regenerate tests/82152069/golden-metadata.txt metadata.

Reviewed changes

Copilot reviewed 3 out of 4 changed files in this pull request and generated 3 comments.

File Description
src/common/m_variables_conversion.fpp Adds a local use ... only: shear_indices within the conservative→primitive conversion routine.
examples/2D_shockdroplet/case.py Adds argparse-driven configuration and derives post-shock state/time-stepping values programmatically.
tests/82152069/golden-metadata.txt Updates generated golden metadata (invocation + environment details).

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread examples/2D_shockdroplet/case.py
Comment thread examples/2D_shockdroplet/case.py
Comment thread tests/82152069/golden-metadata.txt
@codecov

codecov Bot commented Aug 17, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 61.60%. Comparing base (ca26c4c) to head (f97535b).

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #1731   +/-   ##
=======================================
  Coverage   61.60%   61.60%           
=======================================
  Files          84       84           
  Lines       21522    21522           
  Branches     3179     3179           
=======================================
  Hits        13258    13258           
  Misses       6085     6085           
  Partials     2179     2179           

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants