Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

stage1: Mark partial and primal helpers as @inline #291

Merged
merged 1 commit into from
May 3, 2024

Conversation

topolarity
Copy link
Contributor

It's unclear whether this is a compiler bug upstream, but I've observed invokes like this in the wild:

%xxx = invoke DAECompiler.partial(%135::Diffractor.TangentBundle{1}, 1::Int64)::Any

which are (clearly) very poorly typed. %135 was a fully concrete type, so I'm not sure why the tangent type parameters ended up getting stripped off for the invoke.

In any case, the implementations here are so small that they are probably best just inlined anyway.

It's unclear whether this is a compiler bug upstream, but I've observed
invokes like this in the wild:
```
%xxx = invoke DAECompiler.partial(%135::Diffractor.TangentBundle{1}, 1::Int64)::Any
```

which are (clearly) very poorly typed. `%135` was a fully concrete type,
so I'm not sure why the tangent type parameters ended up getting
stripped off.

In any case, the implementations here are so small that they are
probably best just inlined anyway.
Copy link

codecov bot commented May 2, 2024

Codecov Report

Attention: Patch coverage is 75.00000% with 2 lines in your changes are missing coverage. Please review.

Project coverage is 54.12%. Comparing base (d0b3e3e) to head (b883867).

Files Patch % Lines
src/stage1/forward.jl 75.00% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #291      +/-   ##
==========================================
- Coverage   54.92%   54.12%   -0.81%     
==========================================
  Files          27       27              
  Lines        3026     2997      -29     
==========================================
- Hits         1662     1622      -40     
- Misses       1364     1375      +11     

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

Copy link
Member

@oxinabox oxinabox left a comment

Choose a reason for hiding this comment

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

I would expect these to inline without annoations.
That they don't seems bad.
But not the problem of diffractor.
Annoating them is good

@oxinabox oxinabox merged commit 9fcbd0c into JuliaDiff:main May 3, 2024
9 of 10 checks passed
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