Lines Matching refs:SP64

40 typedef ScaledPair<uint64_t> SP64;
49 EXPECT_EQ(getRounded64(0, 0, false), SP64(0, 0));
50 EXPECT_EQ(getRounded64(0, 0, true), SP64(1, 0));
51 EXPECT_EQ(getRounded64(20, 21, true), SP64(21, 21));
52 EXPECT_EQ(getRounded64(UINT32_MAX, 0, false), SP64(UINT32_MAX, 0));
53 EXPECT_EQ(getRounded64(UINT32_MAX, 0, true), SP64(UINT64_C(1) << 32, 0));
54 EXPECT_EQ(getRounded64(UINT64_MAX, 0, false), SP64(UINT64_MAX, 0));
55 EXPECT_EQ(getRounded64(UINT64_MAX, 0, true), SP64(UINT64_C(1) << 63, 1));
70 EXPECT_EQ(getAdjusted64(0), SP64(0, 0));
71 EXPECT_EQ(getAdjusted64(0, 5), SP64(0, 5));
72 EXPECT_EQ(getAdjusted64(UINT32_MAX), SP64(UINT32_MAX, 0));
73 EXPECT_EQ(getAdjusted64(Max32In64 << 1), SP64(Max32In64 << 1, 0));
74 EXPECT_EQ(getAdjusted64(Max32In64 << 1, 1), SP64(Max32In64 << 1, 1));
75 EXPECT_EQ(getAdjusted64(Max32In64 << 31), SP64(Max32In64 << 31, 0));
76 EXPECT_EQ(getAdjusted64(Max32In64 << 32), SP64(Max32In64 << 32, 0));
77 EXPECT_EQ(getAdjusted64(Max32In64 + 1), SP64(Max32In64 + 1, 0));
78 EXPECT_EQ(getAdjusted64(UINT64_MAX), SP64(UINT64_MAX, 0));
124 EXPECT_EQ(SP64(UINT64_C(1) << 63, 64),
129 EXPECT_EQ(SP64(UINT64_C(9223372036854775810), 64),
170 EXPECT_EQ(SP64(0, 0), getQuotient64(0, 0));
171 EXPECT_EQ(SP64(0, 0), getQuotient64(0, 1));
172 EXPECT_EQ(SP64(0, 0), getQuotient64(0, 73));
173 EXPECT_EQ(SP64(UINT64_MAX, MaxScale), getQuotient64(1, 0));
174 EXPECT_EQ(SP64(UINT64_MAX, MaxScale), getQuotient64(6, 0));
177 EXPECT_EQ(SP64(1, 0), getQuotient64(1, 1));
178 EXPECT_EQ(SP64(2, 0), getQuotient64(2, 1));
179 EXPECT_EQ(SP64(4, -4), getQuotient64(4, 16));
180 EXPECT_EQ(SP64(7, 0), getQuotient64(7, 1));
181 EXPECT_EQ(SP64(7, -1), getQuotient64(7, 2));
182 EXPECT_EQ(SP64(7, -4), getQuotient64(7, 16));
185 EXPECT_EQ(SP64(UINT64_C(3) << 60, -60), getQuotient64(9, 3));
186 EXPECT_EQ(SP64(UINT64_C(9) << 58, -58), getQuotient64(63, 7));
189 EXPECT_EQ(SP64(0xaaaaaaaaaaaaaaab, -65), getQuotient64(1, 3));
190 EXPECT_EQ(SP64(0xd555555555555555, -63), getQuotient64(5, 3));
426 EXPECT_EQ(SP64(1, 0), getSum64(0, 0, 1, 0));
427 EXPECT_EQ(SP64(8, -3), getSum64(0, 0, 8, -3));
428 EXPECT_EQ(SP64(UINT64_MAX, 0), getSum64(0, 0, UINT64_MAX, 0));
431 EXPECT_EQ(SP64(2, 0), getSum64(1, 0, 1, 0));
432 EXPECT_EQ(SP64(3, 0), getSum64(1, 0, 2, 0));
433 EXPECT_EQ(SP64(67, 0), getSum64(7, 0, 60, 0));
436 EXPECT_EQ(SP64(3, 0), getSum64(1, 0, 1, 1));
437 EXPECT_EQ(SP64(4, 0), getSum64(2, 0, 1, 1));
440 EXPECT_EQ(SP64(UINT64_C(1) << 63, 1), getSum64(1, 64, 1, 0));
441 EXPECT_EQ(SP64(UINT64_C(1) << 63, -63), getSum64(1, -64, 1, 0));
444 EXPECT_EQ(SP64((UINT64_C(1) << 63) + 1, 1), getSum64(1, 64, 1, 1));
445 EXPECT_EQ(SP64((UINT64_C(1) << 63) + 1, -64), getSum64(1, -64, 1, -1));
448 EXPECT_EQ(SP64(UINT64_C(1) << 63, 1), getSum64(1, 0, UINT64_MAX, 0));
451 EXPECT_EQ(SP64(1, 0), getSum64(1, 0, 0, 0));
452 EXPECT_EQ(SP64(8, -3), getSum64(8, -3, 0, 0));
453 EXPECT_EQ(SP64(UINT64_MAX, 0), getSum64(UINT64_MAX, 0, 0, 0));
454 EXPECT_EQ(SP64(3, 0), getSum64(2, 0, 1, 0));
455 EXPECT_EQ(SP64(67, 0), getSum64(60, 0, 7, 0));
456 EXPECT_EQ(SP64(3, 0), getSum64(1, 1, 1, 0));
457 EXPECT_EQ(SP64(4, 0), getSum64(1, 1, 2, 0));
458 EXPECT_EQ(SP64(UINT64_C(1) << 63, 1), getSum64(1, 0, 1, 64));
459 EXPECT_EQ(SP64(UINT64_C(1) << 63, -63), getSum64(1, 0, 1, -64));
460 EXPECT_EQ(SP64((UINT64_C(1) << 63) + 1, 1), getSum64(1, 1, 1, 64));
461 EXPECT_EQ(SP64((UINT64_C(1) << 63) + 1, -64), getSum64(1, -1, 1, -64));
462 EXPECT_EQ(SP64(UINT64_C(1) << 63, 1), getSum64(UINT64_MAX, 0, 1, 0));
503 EXPECT_EQ(SP64(0, 0), getDifference64(1, 0, 1, 0));
504 EXPECT_EQ(SP64(1, 0), getDifference64(2, 0, 1, 0));
505 EXPECT_EQ(SP64(53, 0), getDifference64(60, 0, 7, 0));
508 EXPECT_EQ(SP64(0, 0), getDifference64(2, 0, 1, 1));
511 EXPECT_EQ(SP64(1, 0), getDifference64(1, 0, 0, 0));
512 EXPECT_EQ(SP64(8, -3), getDifference64(8, -3, 0, 0));
513 EXPECT_EQ(SP64(UINT64_MAX, 0), getDifference64(UINT64_MAX, 0, 0, 0));
516 EXPECT_EQ(SP64((UINT64_C(1) << 63) + 1, 1),
518 EXPECT_EQ(SP64((UINT64_C(1) << 63) + 1, -63),
522 EXPECT_EQ(SP64(UINT64_MAX, 0), getDifference64(1, 64, 1, 0));
523 EXPECT_EQ(SP64(UINT64_MAX, -64), getDifference64(1, 0, 1, -64));
526 EXPECT_EQ(SP64(0, 0), getDifference64(0, 0, 1, 0));
527 EXPECT_EQ(SP64(0, 0), getDifference64(0, 0, 8, -3));
528 EXPECT_EQ(SP64(0, 0), getDifference64(0, 0, UINT64_MAX, 0));
529 EXPECT_EQ(SP64(0, 0), getDifference64(7, 0, 60, 0));
530 EXPECT_EQ(SP64(0, 0), getDifference64(1, 0, 1, 1));
531 EXPECT_EQ(SP64(0, 0), getDifference64(1, -64, 1, 0));
532 EXPECT_EQ(SP64(0, 0), getDifference64(1, -64, 1, -1));