Lines Matching refs:ldexp
113 {float(ldexp(1.0f, -126)), "0x1p-126"},
114 {float(ldexp(-1.0f, -126)), "-0x1p-126"},
117 {float(ldexp(1.0f, -127)), "0x1p-127"},
118 {float(ldexp(1.0f, -127) / 2.0f), "0x1p-128"},
119 {float(ldexp(1.0f, -127) / 4.0f), "0x1p-129"},
120 {float(ldexp(1.0f, -127) / 8.0f), "0x1p-130"},
121 {float(ldexp(-1.0f, -127)), "-0x1p-127"},
122 {float(ldexp(-1.0f, -127) / 2.0f), "-0x1p-128"},
123 {float(ldexp(-1.0f, -127) / 4.0f), "-0x1p-129"},
124 {float(ldexp(-1.0f, -127) / 8.0f), "-0x1p-130"},
126 {float(ldexp(1.0, -127) + (ldexp(1.0, -127) / 2.0f)), "0x1.8p-127"},
127 {float(ldexp(1.0, -127) / 2.0 + (ldexp(1.0, -127) / 4.0f)),
176 {ldexp(1.0, 128), "0x1p+128"},
177 {ldexp(1.0, 129), "0x1p+129"},
178 {ldexp(-1.0, 128), "-0x1p+128"},
179 {ldexp(-1.0, 129), "-0x1p+129"},
180 {ldexp(1.0, 128) + ldexp(1.0, 90), "0x1.0000000004p+128"},
181 {ldexp(1.0, 129) + ldexp(1.0, 120), "0x1.008p+129"},
182 {ldexp(-1.0, 128) + ldexp(1.0, 90), "-0x1.fffffffff8p+127"},
183 {ldexp(-1.0, 129) + ldexp(1.0, 120), "-0x1.ffp+128"},
194 {ldexp(1.0, -128), "0x1p-128"},
195 {ldexp(1.0, -129), "0x1p-129"},
196 {ldexp(-1.0, -128), "-0x1p-128"},
197 {ldexp(-1.0, -129), "-0x1p-129"},
198 {ldexp(1.0, -128) + ldexp(1.0, -90), "0x1.0000000004p-90"},
199 {ldexp(1.0, -129) + ldexp(1.0, -120), "0x1.008p-120"},
200 {ldexp(-1.0, -128) + ldexp(1.0, -90), "0x1.fffffffff8p-91"},
201 {ldexp(-1.0, -129) + ldexp(1.0, -120), "0x1.ffp-121"},
204 {ldexp(1.0, -1022), "0x1p-1022"},
205 {ldexp(-1.0, -1022), "-0x1p-1022"},
208 {ldexp(1.0, -1023), "0x1p-1023"},
209 {ldexp(1.0, -1023) / 2.0, "0x1p-1024"},
210 {ldexp(1.0, -1023) / 4.0, "0x1p-1025"},
211 {ldexp(1.0, -1023) / 8.0, "0x1p-1026"},
212 {ldexp(-1.0, -1024), "-0x1p-1024"},
213 {ldexp(-1.0, -1024) / 2.0, "-0x1p-1025"},
214 {ldexp(-1.0, -1024) / 4.0, "-0x1p-1026"},
215 {ldexp(-1.0, -1024) / 8.0, "-0x1p-1027"},
217 {ldexp(1.0, -1023) + (ldexp(1.0, -1023) / 2.0), "0x1.8p-1023"},
218 {ldexp(1.0, -1023) / 2.0 + (ldexp(1.0, -1023) / 4.0),
479 {float(ldexp(1.f, 126)), "8.50706e+37"},
480 {float(ldexp(-1.f, -126)), "-1.17549e-38"},
483 {float(ldexp(1.0f, -127)), "0x1p-127"},
484 {float(ldexp(1.5f, -128)), "0x1.8p-128"},
485 {float(ldexp(1.25, -129)), "0x1.4p-129"},
486 {float(ldexp(1.125, -130)), "0x1.2p-130"},
487 {float(ldexp(-1.0f, -127)), "-0x1p-127"},
488 {float(ldexp(-1.0f, -128)), "-0x1p-128"},
489 {float(ldexp(-1.0f, -129)), "-0x1p-129"},
490 {float(ldexp(-1.5f, -130)), "-0x1.8p-130"},
510 {ldexp(1.0, 128), "3.40282366920938e+38"},
511 {ldexp(1.5, 129), "1.02084710076282e+39"},
512 {ldexp(-1.0, 128), "-3.40282366920938e+38"},
513 {ldexp(-1.5, 129), "-1.02084710076282e+39"},
516 {ldexp(1.5, -129), "2.20405190779179e-39"},
517 {ldexp(-1.5, -129), "-2.20405190779179e-39"},
520 {ldexp(1.0, -1022), "2.2250738585072e-308"},
521 {ldexp(-1.0, -1022), "-2.2250738585072e-308"},
524 {ldexp(1.125, -1023), "0x1.2p-1023"},
525 {ldexp(-1.375, -1024), "-0x1.6p-1024"},
551 EXPECT_EQ(0, unbiased_exponent(ldexp(1.0f, 0))); in TEST()
552 EXPECT_EQ(-32, unbiased_exponent(ldexp(1.0f, -32))); in TEST()
553 EXPECT_EQ(42, unbiased_exponent(ldexp(1.0f, 42))); in TEST()
554 EXPECT_EQ(125, unbiased_exponent(ldexp(1.0f, 125))); in TEST()
556 EXPECT_EQ(128, unbiased_exponent(ldexp(1.0f, 256))); in TEST()
558 EXPECT_EQ(-100, unbiased_exponent(ldexp(1.0f, -100))); in TEST()
559 EXPECT_EQ(-127, unbiased_exponent(ldexp(1.0f, -127))); // First denorm in TEST()
560 EXPECT_EQ(-128, unbiased_exponent(ldexp(1.0f, -128))); in TEST()
561 EXPECT_EQ(-129, unbiased_exponent(ldexp(1.0f, -129))); in TEST()
562 EXPECT_EQ(-140, unbiased_exponent(ldexp(1.0f, -140))); in TEST()
564 EXPECT_EQ(-126 - 23, unbiased_exponent(ldexp(1.0f, -126 - 23))); in TEST()
566 EXPECT_EQ(0, unbiased_exponent(ldexp(1.0f, -127 - 23))); in TEST()
586 f += std::ldexp(1.0f, -i); in float_fractions()
596 static_cast<float>(ldexp(float_fractions(fractions), exp))) in normalized_significand()
660 EXPECT_EQ(static_cast<float>(ldexp(1.f, -149)), set_from_sign(false, -149, 0, false)); in TEST()
661 EXPECT_EQ(static_cast<float>(ldexp(1.f, -149)), set_from_sign(false, -149, 0, true)); in TEST()
663 EXPECT_EQ(static_cast<float>(ldexp(1.f, -149)), set_from_sign(false, -150, 1, true)); in TEST()
665 EXPECT_EQ(ldexp(1.0f, -127), set_from_sign(false, -127, 0, false)); in TEST()
666 EXPECT_EQ(ldexp(1.0f, -128), set_from_sign(false, -128, 0, false)); in TEST()
669 EXPECT_EQ(ldexp(float_fractions({0, 1, 2, 5}), -32), in TEST()
671 EXPECT_EQ(ldexp(float_fractions({0, 1, 2, 5}), -128), in TEST()
676 EXPECT_EQ(-ldexp(1.0, -127), set_from_sign(true, -127, 0, false)); in TEST()
677 EXPECT_EQ(-ldexp(1.0, -128), set_from_sign(true, -128, 0, false)); in TEST()
680 EXPECT_EQ(-ldexp(float_fractions({0, 1, 2, 5}), -32), in TEST()
682 EXPECT_EQ(-ldexp(float_fractions({0, 1, 2, 5}), -128), in TEST()
716 HF(static_cast<float>(-ldexp(float_fractions({0, 1, 2, 5}), -128))) in TEST()
792 …{static_cast<float>(ldexp(float_fractions({0, 1, 11, 13}), -128)), std::make_pair(half_bits_set({0…
793 …{static_cast<float>(ldexp(float_fractions({0, 1, 11, 13}), -129)), std::make_pair(half_bits_set({0…
794 …{static_cast<float>(ldexp(float_fractions({0, 1, 11, 13}), -131)), std::make_pair(half_bits_set({0…
795 …{static_cast<float>(ldexp(float_fractions({0, 1, 11, 13}), -130)), std::make_pair(half_bits_set({0…
893 …{static_cast<float>(ldexp(float_fractions({0, 1, 10}), 3)), 0x4A01, {spvutils::kRoundToZero, spvut…
894 …{static_cast<float>(-ldexp(float_fractions({0, 1, 10}), 3)), 0xCA01, {spvutils::kRoundToZero, spvu…
898 …{static_cast<float>(ldexp(1.0f, -25)), 0x0, {spvutils::kRoundToZero, spvutils::kRoundToNegativeInf…
899 {static_cast<float>(ldexp(1.0f, -25)), 0x1, {spvutils::kRoundToPositiveInfinity}},
900 …{static_cast<float>(-ldexp(1.0f, -25)), 0x8000, {spvutils::kRoundToZero, spvutils::kRoundToPositiv…
901 {static_cast<float>(-ldexp(1.0f, -25)), 0x8001, {spvutils::kRoundToNegativeInfinity}},
902 …{static_cast<float>(ldexp(1.0f, -24)), 0x1, {spvutils::kRoundToZero, spvutils::kRoundToPositiveInf…
905 …{static_cast<float>(ldexp(1.0f, 16)), positive_infinity, {spvutils::kRoundToZero, spvutils::kRound…
906 …{static_cast<float>(ldexp(1.0f, 18)), positive_infinity, {spvutils::kRoundToZero, spvutils::kRound…
907 …{static_cast<float>(ldexp(1.3f, 16)), positive_infinity, {spvutils::kRoundToZero, spvutils::kRound…
908 …{static_cast<float>(-ldexp(1.0f, 16)), negative_infinity, {spvutils::kRoundToZero, spvutils::kRoun…
909 …{static_cast<float>(-ldexp(1.0f, 18)), negative_infinity, {spvutils::kRoundToZero, spvutils::kRoun…
910 …{static_cast<float>(-ldexp(1.3f, 16)), negative_infinity, {spvutils::kRoundToZero, spvutils::kRoun…
960 {0x0001, static_cast<float>(ldexp(1.0, -24))},
961 {0x0002, static_cast<float>(ldexp(1.0, -23))},
962 {0x8001, static_cast<float>(-ldexp(1.0, -24))},
963 {0x8011, static_cast<float>(-ldexp(1.0, -20) + -ldexp(1.0, -24))},