-
Notifications
You must be signed in to change notification settings - Fork 407
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
Replace PGI by NVHPC in CMake setup #4196
Conversation
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 want a test written for the volatile operators of half. @e10harvey Note that the volatile operators where this PR changes to auto& didn't actually update val I believe.
core/src/Cuda/Kokkos_Cuda_Half.hpp
Outdated
auto val_ref = const_cast<impl_type&>(val); | ||
val_ref = __float2half(__half2float(const_cast<impl_type&>(val)) + | ||
auto& val_ref = const_cast<impl_type&>(val); | ||
val_ref = __float2half(__half2float(const_cast<impl_type&>(val)) + | ||
__half2float(rhs.val)); |
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.
omg this operator was simply wrong before. val_ref was a value type wasn't it? Not a reference type? Can we get a test for 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.
Does not belong to this PR IMO
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.
Moved to #4198 and asked @e10harvey for a test.
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.
These tests are part of #4101 which is ready for another round of reviews. See https://github.com/kokkos/kokkos/pull/4101/files#diff-6980b46765a569d9ae64dffdbe6a0db53b9ed49c8b9157236055a90add5b47afR277-R352.
core/src/Cuda/Kokkos_Cuda_Half.hpp
Outdated
auto val_ref = const_cast<impl_type&>(val); | ||
val_ref = __float2half(__half2float(const_cast<impl_type&>(val)) + | ||
auto& val_ref = const_cast<impl_type&>(val); | ||
val_ref = __float2half(__half2float(const_cast<impl_type&>(val)) + | ||
__half2float(rhs.val)); |
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.
Does not belong to this PR IMO
666eb81
to
809e1dd
Compare
Retest this please. |
|
CMake
identifiesnvc++
asNVHPC
forCMake
>=3.20 and as PGI before that. Since nvc++ is supposed to be backward-compatible with pgc++ just settingNVHPC
as internal compiler identification forPGI
should be fine and avoids distinguishing between the two.