aboutsummaryrefslogtreecommitdiffhomepage
path: root/Eigen/src/Core/arch/Default/GenericPacketMathFunctions.h
diff options
context:
space:
mode:
authorGravatar Rasmus Munk Larsen <rmlarsen@google.com>2020-09-28 22:30:36 +0000
committerGravatar Rasmus Munk Larsen <rmlarsen@google.com>2020-09-28 22:30:36 +0000
commit3a0b23e473ff27db9fa708b85f3fcf9938986cfa (patch)
tree33dcadcd9ac518af23d54ff9bfdb5d4eddd3e204 /Eigen/src/Core/arch/Default/GenericPacketMathFunctions.h
parent6b0c0b587ed8aaae72ef6a383617789d27cd1708 (diff)
Fix compilation of pset1frombits calls on iOS.
Diffstat (limited to 'Eigen/src/Core/arch/Default/GenericPacketMathFunctions.h')
-rw-r--r--Eigen/src/Core/arch/Default/GenericPacketMathFunctions.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/Eigen/src/Core/arch/Default/GenericPacketMathFunctions.h b/Eigen/src/Core/arch/Default/GenericPacketMathFunctions.h
index a0bfada93..dcb21a543 100644
--- a/Eigen/src/Core/arch/Default/GenericPacketMathFunctions.h
+++ b/Eigen/src/Core/arch/Default/GenericPacketMathFunctions.h
@@ -34,7 +34,7 @@ pfrexp_double(const Packet& a, Packet& exponent) {
typedef typename unpacket_traits<Packet>::integer_packet PacketI;
const Packet cst_1022d = pset1<Packet>(1022.0);
const Packet cst_half = pset1<Packet>(0.5);
- const Packet cst_inv_mant_mask = pset1frombits<Packet>(~0x7ff0000000000000u);
+ const Packet cst_inv_mant_mask = pset1frombits<Packet>(static_cast<uint64_t>(~0x7ff0000000000000ull));
exponent = psub(pcast<PacketI,Packet>(plogical_shift_right<52>(preinterpret<PacketI>(a))), cst_1022d);
return por(pand(a, cst_inv_mant_mask), cst_half);
}
@@ -172,9 +172,9 @@ Packet plog_double(const Packet _x)
const Packet cst_1 = pset1<Packet>(1.0);
const Packet cst_half = pset1<Packet>(0.5);
// The smallest non denormalized float number.
- const Packet cst_min_norm_pos = pset1frombits<Packet>( 0x0010000000000000u);
- const Packet cst_minus_inf = pset1frombits<Packet>( 0xfff0000000000000u);
- const Packet cst_pos_inf = pset1frombits<Packet>( 0x7ff0000000000000u);
+ const Packet cst_min_norm_pos = pset1frombits<Packet>( static_cast<uint64_t>(0x0010000000000000ull));
+ const Packet cst_minus_inf = pset1frombits<Packet>( static_cast<uint64_t>(0xfff0000000000000ull));
+ const Packet cst_pos_inf = pset1frombits<Packet>( static_cast<uint64_t>(0x7ff0000000000000ull));
// Polynomial Coefficients for log(1+x) = x - x**2/2 + x**3 P(x)/Q(x)
// 1/sqrt(2) <= x < sqrt(2)