Conversation
`classify_arguments` uses the function type so it can't do that determination on it's own.
|
Also sret as an attribute is not always set even if Julia makes an sret. E.g. the code snippet in EnzymeAD/Enzyme.jl#154 will result in the first arg as sret, but without the attribute. |
|
Codecov Report
@@ Coverage Diff @@
## master #272 +/- ##
=======================================
Coverage 87.12% 87.12%
=======================================
Files 22 22
Lines 2112 2112
=======================================
Hits 1840 1840
Misses 272 272
Continue to review full report at Codecov.
|
|
We could pass it the function instead, but I guess that first need a fix in Julia to set the |
|
Only relevant for code calling the function in this PR, I remember @vtjnash said there was a compile-time performance reason why sret wasn't set and it didn't matter for correctness so I'm not sure there will be a proper Julia fix so much as a "derive it in the same way". |
|
Can we easily derive it? Otherwise that'd be a great thing for |
|
There are also sometimes 2 sret arguments. In codegen we call |
1d233d7 to
e18b7c2
Compare
classify_argumentsuses the function type so it can't do thatdetermination on it's own.
cc: @wsmoses