-
Notifications
You must be signed in to change notification settings - Fork 78
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
Fix complex to not depend on C++; reimplement functions for client tests in terms of std::complex #193
Conversation
120db3c
to
c21123e
Compare
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.
Looks good.
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.
LGTM as long as CI tests pass
53dd1ef
to
5a34120
Compare
5a34120
to
790dd6f
Compare
It passes all tests now. |
The original compilation errors after |
Something is different about the CI which needs investigating and fixing, which is causing those build failures. I can't reproduce them locally. The C++ code is fine; the errors, as with nearly all C++ template compilation errors, are misleading. It looks like the CI compiler is not picking up To reproduce the failures on my own machine, I would need the right Docker container. |
This supercedes PR# 191, which was not a full solution.
This only uses C in the
hipblas.h
header, unless__cplusplus
is defined.It re-implements the test functions in terms of
std::complex
, which has a guaranteed layout and hencereinterpret_cast<std::complex<float>&>(hipComplex)
andreinterpret_cast<std::complex<double>&>(hipDoubleComplex)
can be used to cast them intostd::complex
to use the functions in there (to avoid dependence onrocblas-complex-functions.h
).