FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

compiler: Minor tweaks to enable integrated NCU-based profiling by FabioLuporini · Pull Request #2937 · devitocodes/devito · GitHub

compiler: Minor tweaks to enable integrated NCU-based profiling - #2937

Merged
FabioLuporini merged 2 commits into
mainfrom
ncu-py
May 27, 2026
Merged

compiler: Minor tweaks to enable integrated NCU-based profiling#2937
FabioLuporini merged 2 commits into
mainfrom
ncu-py

Conversation

Copy link
Copy Markdown
Contributor

Bulk of the code is in PRO

codecov Bot commented May 26, 2026
edited
Loading

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 40.00000% with 21 lines in your changes missing coverage. Please review.
✅ Project coverage is 83.36%. Comparing base (c71560b) to head (afa9cd0).

Files with missing lines Patch % Lines
devito/arch/archinfo.py 30.00% 7 Missing ⚠️
devito/parameters.py 0.00% 7 Missing ⚠️
devito/operator/profiling.py 37.50% 5 Missing ⚠️
devito/__init__.py 66.66% 1 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2937      +/-   ##
==========================================
- Coverage   83.37%   83.36%   -0.02%     
==========================================
  Files         248      248              
  Lines       51881    51905      +24     
  Branches     4479     4479              
==========================================
+ Hits        43257    43271      +14     
- Misses       7867     7879      +12     
+ Partials      757      755       -2     
Flag Coverage Δ
pytest-gpu-aomp-amdgpuX 68.67% <40.00%> (-0.02%) ⬇️
pytest-gpu-gcc- 78.06% <40.00%> (-0.03%) ⬇️
pytest-gpu-icx- 78.02% <40.00%> (+0.02%) ⬆️
pytest-gpu-nvc-nvidiaX 69.21% <40.00%> (-0.03%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 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.

Comment thread devito/__init__.py
configuration.add('profiling', 'basic', list(profiler_registry), impacts_jit=False)
def profiling_preprocessor(i):
if isinstance(i, dict):
return NcuProfiling(i['ncu'])

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.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

This could use a try/key error for safety

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

not necessary, if you're here inside profiling_preprocessor the presence of ncu (or any other legal value in profiler_registry) has already been ensured

DEVITO_PROFILING=XXX:ForwardFletcherTTI  python devitopro/recipes/recipes/run.py <...>

gives

Traceback (most recent call last):
 ........
  File "/venv/lib/python3.10/site-packages/devito/parameters.py", line 51, in wrapper
    raise ValueError(f"Illegal configuration parameter ({key}, {value}). "
ValueError: Illegal configuration parameter (profiling, {'XXX': 'ForwardFletcherTTI'}). Accepted: ['basic', 'basic1', 'basic2', 'advanced', 'advanced1', 'advanced2', 'ncu', 'advisor']

Comment thread devito/parameters.py
# Allow unquoted strings as `k:v` values.
processed.append(i)
values = processed
except AttributeError:

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.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Not sure why you need processed and values if you just do values = processed

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

there is an eval above. This is essentially to avoid the user having to supply quotes in the env var , that is, instead of doing DEVITO_PROFILING="ncu:'ForwardFletcherTTI'" they can just do DEVITO_PROFILING="ncu:ForwardFletcherTTI"

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.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Not sure how it answer my comment. All i'm saying is that you do

processed = []
for ...:
   processed.extend(...)
  
values = processed

while you can just fill

values = []
for ...:
   values.extend(...)
  

and be done

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

no, values contains... values, already

FabioLuporini merged commit dc3fa07 into main May 27, 2026
42 checks passed
FabioLuporini deleted the ncu-py branch May 27, 2026 23:38
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
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants


Back | FazBrowse Home | New Git URL