Skip to content

compiler: Introduce operator lookup hook#2954

Open
EdCaunt wants to merge 3 commits into
mainfrom
operator-lookup-hook
Open

compiler: Introduce operator lookup hook#2954
EdCaunt wants to merge 3 commits into
mainfrom
operator-lookup-hook

Conversation

@EdCaunt

@EdCaunt EdCaunt commented Jun 23, 2026

Copy link
Copy Markdown
Contributor

No description provided.

@mloubout mloubout added the API api (symbolics, types, ...) label Jun 23, 2026
@codecov

codecov Bot commented Jun 23, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 42.85714% with 12 lines in your changes missing coverage. Please review.
✅ Project coverage is 83.60%. Comparing base (c01281c) to head (6bdc180).

Files with missing lines Patch % Lines
devito/arch/archinfo.py 38.46% 8 Missing ⚠️
devito/operator/operator.py 66.66% 1 Missing and 1 partial ⚠️
devito/types/equation.py 0.00% 1 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2954      +/-   ##
==========================================
- Coverage   83.60%   83.60%   -0.01%     
==========================================
  Files         250      250              
  Lines       52908    52928      +20     
  Branches     4564     4566       +2     
==========================================
+ Hits        44235    44249      +14     
- Misses       7895     7901       +6     
  Partials      778      778              
Flag Coverage Δ
pytest-gpu-aomp-amdgpuX 68.86% <42.85%> (-0.02%) ⬇️
pytest-gpu-gcc- 78.38% <42.85%> (-0.02%) ⬇️
pytest-gpu-icx- 78.31% <42.85%> (-0.02%) ⬇️
pytest-gpu-nvc-nvidiaX 69.38% <42.85%> (-0.02%) ⬇️

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

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

Comment thread devito/types/equation.py

def __str__(self):
if self._subdomain is not None:
return (f"{self.__class__.__name__}({self.lhs}, {self.rhs},"

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.

nitpicking, this part of the fstring is identical to the one you return if no subdomain is present...

expressions = cls._sanitize_exprs(expressions, **kwargs)

# Hook for retrieval of preexisting operators
# TODO: should this emit timing info if an operator is retrieved

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.

only in the hook, I'd say? so I guess you can drop this TODO comment...

@EdCaunt EdCaunt force-pushed the operator-lookup-hook branch from afa93a8 to 86d0d36 Compare June 29, 2026 14:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

API api (symbolics, types, ...)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants