-
Notifications
You must be signed in to change notification settings - Fork 3
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
Psyclone 3 support #388
base: main
Are you sure you want to change the base?
Psyclone 3 support #388
Conversation
3 better compiler support
… only one artefact set is involved when running PSyclone.
…les to the default build artefact collections.
…eady in the output directory.
…ot replacing artefact).
…n in build (not source).
…ive compiler names are longer (crayftn-cray, craycc-cray).
… to avoid confusion with Craycc.
… new stle arguments and vice versa.
…ms with compiler wrapper which do not support this).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think there may be a better way of handling the change of behaviour between versions.
# The behaviour of PSyclone changes from 2.5.0 to the next | ||
# release. But since head-of-trunk still reports 2.5.0, we | ||
# need to run additional tests to see if we have the official | ||
# 2.5.0 release, or current trunk (which already has the new | ||
# command line options). PSyclone needs an existing file | ||
# in order to work, so use __file__ to present this file. | ||
# PSyclone will obviously abort since this is not a Fortran | ||
# file, but we only need to check the error message to | ||
# see if the domain name is incorrect (--> current trunk) | ||
# or not (2.5.0 release) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not only has PSyclone 2.5.0 been released but so has 3.0.0. So any special cases can be removed and this section can be streamlined.
self._api = api | ||
self._version = None | ||
|
||
def check_available(self) -> bool: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can this whole complication, or a good section of it, be replaced by making use of shutil.which(...)
?
if api and api.lower() == "nemo": | ||
api = "" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Rather than trying to make on class support quite different versions of the tool would it make sense to have an old PSyclone and a new PSyclone class with some sort of factory process to choose between them?
Supports the new 3.0 release, but also older PSyclone versions.