Generalise hoist_arguments_to_temporaries in NEMO utils to all arguments with array operations #3429
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #3429 +/- ##
=======================================
Coverage 99.96% 99.96%
=======================================
Files 391 391
Lines 54683 54689 +6
=======================================
+ Hits 54664 54670 +6
Misses 19 19 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
Some failures after this change can be resolved with a change to reference2arrayrange_trans: instead of |
|
I'm trying building today and it just seems to work, I will test full integration and see if any others fail. |
|
From discussion with sergi the previous direction has potential to produce incorrect code. Instead we should change operation order:
|
We don't have metatransformation support yet for this, but I'll make an issue for this as well. |
…ay reduction base trans. Testing NYI
|
@sergisiso I think this is ready for a first look now. |
sergisiso
left a comment
There was a problem hiding this comment.
Thanks @LonelyCat124, its good to see it has passed all integration tests without making it exclusive for iom_put. Just some extra clarifications and testing needed.
| if (isinstance(dtype.elemental_type, ScalarType) | ||
| and dtype.elemental_type.intrinsic == | ||
| ScalarType.Intrinsic.CHARACTER): | ||
| continue |
There was a problem hiding this comment.
Is this an issue with the transformation? I am wondering if it should be inside the validation instead?
There was a problem hiding this comment.
I'm not sure - the transformation does it successfully but there was some error, I don't remember whether compiler or elsewhere in PSyclone. I can have a further look if you want, I just decided to skip it here for strings (not sure if there would be some other valid use case?)
There was a problem hiding this comment.
I found out in #3343 that node.datatype of a array_reference with a character string is special because those are not array with shapes but ScalarType with length. And therefore its datatype result is wrong. Could this be the same problem?
(If this PR is ready before #3443 I can explore it, e.g. remove the condition, there)
|
@sergisiso I think this is ready for review again? I'm not sure why i didn't mark it as so last week so if I've missed something let me know. |
sergisiso
left a comment
There was a problem hiding this comment.
@LonelyCat124 This is approved for merging, we still don't know what's the issue with characters and why we don't see the expected speedup, but it is a big step to generalise the functionality and it passes all tests
|
@LonelyCat124 The linkspector action is failing, but I will proceed for now and monitor if it gets fixed eventually. |
No description provided.