mirror of
https://github.com/amd/blis.git
synced 2026-05-04 06:21:12 +00:00
BLIS GTestSuite Updates:
- Fix in README.md. - Updating abs overload for scomplex and dcomplex to avoid overflow by using std::abs. - Updating comparators to take into account NaNs and Infs when measuring error. AMD-Internal: [CPUPL-2732] Change-Id: I8c12bacd9d63b2e914d0a79f337f7525dc16b733
This commit is contained in:
committed by
Eleni Vlachopoulou
parent
f9adfa8ee4
commit
bf3f5cafa8
@@ -60,4 +60,23 @@ bool operator== (const scomplex x, const scomplex y);
|
||||
bool operator== (const dcomplex x, const dcomplex y);
|
||||
|
||||
bool operator!= (const scomplex x, const scomplex y);
|
||||
bool operator!= (const dcomplex x, const dcomplex y);
|
||||
bool operator!= (const dcomplex x, const dcomplex y);
|
||||
|
||||
// Since we may only specialise template functions and classes
|
||||
// in the std namespace for custom types, and std::to_string is not
|
||||
// a template function, we put to_string into our namespace.
|
||||
namespace testinghelpers {
|
||||
template<typename T>
|
||||
std::string to_string(const T& x) {
|
||||
if constexpr (testinghelpers::type_info<T>::is_complex)
|
||||
{
|
||||
std::string ss = "(" + std::to_string(x.real) + ", " + std::to_string(x.imag) + ")";
|
||||
return ss;
|
||||
}
|
||||
else
|
||||
{
|
||||
return std::to_string(x);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user