mirror of
https://gitlab.com/libeigen/eigen.git
synced 2025-04-23 10:09:36 +08:00
workaround ICC aggressive optimization
This commit is contained in:
parent
fb1a29fed5
commit
8bee573a78
@ -29,9 +29,12 @@ template<typename T> bool isNotNaN(const T& x)
|
|||||||
return x==x;
|
return x==x;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// workaround aggressive optimization in ICC
|
||||||
|
template<typename T> EIGEN_DONT_INLINE T sub(T a, T b) { return a - b; }
|
||||||
|
|
||||||
template<typename T> bool isFinite(const T& x)
|
template<typename T> bool isFinite(const T& x)
|
||||||
{
|
{
|
||||||
return isNotNaN(x-x);
|
return isNotNaN(sub(x,x));
|
||||||
}
|
}
|
||||||
|
|
||||||
template<typename T> EIGEN_DONT_INLINE T copy(const T& x)
|
template<typename T> EIGEN_DONT_INLINE T copy(const T& x)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user