uint128 85 src/dps8/dps8.h # define construct_128(h, l) ((uint128) { (h), (l) }) uint128 9300 src/dps8/dps8_eis.c uint128 extBits = lshift_128 (construct_128 (MASK64, MASK64), (uint) bits); uint128 9301 src/dps8/dps8_eis.c uint128 or = or_128 (n128, extBits); uint128 9304 src/dps8/dps8_eis.c uint128 extBits = ((uint128)-1 << bits); uint128 9309 src/dps8/dps8_eis.c uint128 zeroBits = complement_128 (lshift_128 (construct_128 (MASK64, MASK64), (uint) bits)); uint128 9310 src/dps8/dps8_eis.c uint128 and = and_128 (n128, zeroBits); uint128 9313 src/dps8/dps8_eis.c uint128 zeroBits = ~((uint128)-1 << bits); uint128 325 src/dps8/dps8_hw_consts.h uint128 v = or_128 (w, construct_128 (0xFFFFFFFFFFFFFF80, 0)); uint128 328 src/dps8/dps8_hw_consts.h uint128 v = and_128 (w, MASK72); uint128 339 src/dps8/dps8_hw_consts.h return ((int128) w) | (int128) (((uint128) -1ll) << 72); uint128 7125 src/dps8/dps8_ins.c uint128 bigsecs = divide_128_32 (big, 1000000u, & remainder); uint128 1181 src/dps8/dps8_math.c uint128 ut = rshift_128 (cast_128 (t), 44); uint128 2388 src/dps8/dps8_math.c int128 m1l = m1 & (((uint128)1<<64)-1); uint128 2397 src/dps8/dps8_math.c m3h = (int128) (((uint128) m3h) << 1); // m3h is hi by 64, align it for addition. The result is 135 bits so this cannot overflow. uint128 2652 src/dps8/dps8_math.c word72 m3 = ((uint128)m1 << (63-8)) / ((uint128)m2 >> 8); uint128 2805 src/dps8/dps8_math.c uint128 zFrac = (((uint128) (cpu.rA & MASK35)) << 35) | ((cpu.rQ >> 1) & MASK35); uint128 2822 src/dps8/dps8_math.c uint128 2827 src/dps8/dps8_math.c uint128 2830 src/dps8/dps8_math.c uint128 dFrac = cpu.CY & MASK35; uint128 2859 src/dps8/dps8_math.c uint128 sn = zFrac; uint128 2863 src/dps8/dps8_math.c uint128 s2n = sn << 1; uint128 2889 src/dps8/dps8_math.c if (quot & ~((uint128) MASK35)) { uint128 2939 src/dps8/dps8_math.c uint128 zFrac = lshift_128 (construct_128 (0, cpu.rA & MASK35), 35); uint128 2943 src/dps8/dps8_math.c uint128 zFrac = ((uint128) (cpu . rA & MASK35) << 35) | ((cpu . rQ >> 1) & MASK35); uint128 2955 src/dps8/dps8_math.c zFrac = (uint128) (((int128) (~zFrac)) + 1); uint128 2980 src/dps8/dps8_math.c uint128 dFrac = convert_to_word72 (0, cpu.CY & MASK35); uint128 2993 src/dps8/dps8_math.c dFrac = (uint128) (((int128) (~dFrac)) + 1); uint128 3039 src/dps8/dps8_math.c uint128 remainder; uint128 3040 src/dps8/dps8_math.c uint128 quot = divide_128 (zFrac, dFrac, & remainder); uint128 3044 src/dps8/dps8_math.c uint128 quot = zFrac / dFrac; uint128 3045 src/dps8/dps8_math.c uint128 remainder = zFrac % dFrac; uint128 35 src/dps8/dps8_math128.c bool iszero_128 (uint128 w) uint128 42 src/dps8/dps8_math128.c bool isnonzero_128 (uint128 w) uint128 49 src/dps8/dps8_math128.c bool iseq_128 (uint128 a, uint128 b) uint128 54 src/dps8/dps8_math128.c bool isgt_128 (uint128 a, uint128 b) uint128 62 src/dps8/dps8_math128.c bool islt_128 (uint128 a, uint128 b) uint128 70 src/dps8/dps8_math128.c bool isge_128 (uint128 a, uint128 b) uint128 94 src/dps8/dps8_math128.c uint128 and_128 (uint128 a, uint128 b) uint128 96 src/dps8/dps8_math128.c return (uint128) {a.h & b.h, a.l & b.l}; uint128 99 src/dps8/dps8_math128.c int128 and_s128 (int128 a, uint128 b) uint128 104 src/dps8/dps8_math128.c uint128 or_128 (uint128 a, uint128 b) uint128 106 src/dps8/dps8_math128.c return (uint128) {a.h | b.h, a.l | b.l}; uint128 109 src/dps8/dps8_math128.c uint128 xor_128 (uint128 a, uint128 b) uint128 111 src/dps8/dps8_math128.c return (uint128) {a.h ^ b.h, a.l ^ b.l}; uint128 114 src/dps8/dps8_math128.c uint128 complement_128 (uint128 a) uint128 116 src/dps8/dps8_math128.c return (uint128) {~ a.h, ~ a.l}; uint128 119 src/dps8/dps8_math128.c uint128 add_128 (uint128 a, uint128 b) uint128 142 src/dps8/dps8_math128.c uint128 subtract_128 (uint128 a, uint128 b) uint128 147 src/dps8/dps8_math128.c uint128 res = construct_128 (a.h - b.h, a.l - b.l); uint128 154 src/dps8/dps8_math128.c uint128 negate_128 (uint128 a) uint128 161 src/dps8/dps8_math128.c uint128 t = add_128 (complement_128 (cast_128 (a)), construct_128 (0, 1)); uint128 165 src/dps8/dps8_math128.c uint128 lshift_128 (uint128 a, unsigned int n) uint128 196 src/dps8/dps8_math128.c uint128 t = lshift_128 (cast_128 (a), n); uint128 200 src/dps8/dps8_math128.c uint128 rshift_128 (uint128 a, unsigned int n) uint128 268 src/dps8/dps8_math128.c uint128 t = rshift_128 (cast_128 (a), n); uint128 473 src/dps8/dps8_math128.c uint128 multiply_128 (uint128 a, uint128 b) uint128 514 src/dps8/dps8_math128.c uint128 divide_128 (uint128 a, uint128 b, uint128 * remp) uint128 569 src/dps8/dps8_math128.c uint128 divide_128_16 (uint128 a, uint16_t b, uint16_t * remp) uint128 605 src/dps8/dps8_math128.c uint128 divide_128_32 (uint128 a, uint32_t b, uint32_t * remp) uint128 656 src/dps8/dps8_math128.c uint128 a = construct_128 (ah, al); uint128 657 src/dps8/dps8_math128.c uint128 b = construct_128 (bh, bl); uint128 658 src/dps8/dps8_math128.c uint128 r = and_128 (a, b); uint128 672 src/dps8/dps8_math128.c uint128 a = construct_128 (ah, al); uint128 673 src/dps8/dps8_math128.c uint128 b = construct_128 (bh, bl); uint128 674 src/dps8/dps8_math128.c uint128 r = or_128 (a, b); uint128 688 src/dps8/dps8_math128.c uint128 a = construct_128 (ah, al); uint128 689 src/dps8/dps8_math128.c uint128 r = complement_128 (a); uint128 703 src/dps8/dps8_math128.c uint128 a = construct_128 (ah, al); uint128 704 src/dps8/dps8_math128.c uint128 b = construct_128 (bh, bl); uint128 705 src/dps8/dps8_math128.c uint128 r = add_128 (a, b); uint128 719 src/dps8/dps8_math128.c uint128 a = construct_128 (ah, al); uint128 720 src/dps8/dps8_math128.c uint128 b = construct_128 (bh, bl); uint128 721 src/dps8/dps8_math128.c uint128 r = subtract_128 (a, b); uint128 735 src/dps8/dps8_math128.c uint128 a = construct_128 (ah, al); uint128 736 src/dps8/dps8_math128.c uint128 r = negate_128 (a); uint128 750 src/dps8/dps8_math128.c uint128 a = construct_128 (ah, al); uint128 751 src/dps8/dps8_math128.c uint128 b = construct_128 (bh, bl); uint128 766 src/dps8/dps8_math128.c uint128 a = construct_128 (ah, al); uint128 767 src/dps8/dps8_math128.c uint128 r = lshift_128 (a, n); uint128 781 src/dps8/dps8_math128.c uint128 a = construct_128 (ah, al); uint128 782 src/dps8/dps8_math128.c uint128 r = rshift_128 (a, n); uint128 796 src/dps8/dps8_math128.c uint128 a = construct_128 (ah, al); uint128 797 src/dps8/dps8_math128.c uint128 b = construct_128 (bh, bl); uint128 798 src/dps8/dps8_math128.c uint128 r = multiply_128 (a, b); uint128 829 src/dps8/dps8_math128.c uint128 a = construct_128 (ah, al); uint128 831 src/dps8/dps8_math128.c uint128 res = divide_128_16 (a, b, & rem); uint128 846 src/dps8/dps8_math128.c uint128 a = construct_128 (ah, al); uint128 848 src/dps8/dps8_math128.c uint128 res = divide_128_32 (a, b, & rem); uint128 27 src/dps8/dps8_math128.h bool iszero_128 (uint128 w); uint128 28 src/dps8/dps8_math128.h bool isnonzero_128 (uint128 w); uint128 29 src/dps8/dps8_math128.h bool iseq_128 (uint128 a, uint128 b); uint128 30 src/dps8/dps8_math128.h bool isgt_128 (uint128 a, uint128 b); uint128 31 src/dps8/dps8_math128.h bool islt_128 (uint128 a, uint128 b); uint128 32 src/dps8/dps8_math128.h bool isge_128 (uint128 a, uint128 b); uint128 35 src/dps8/dps8_math128.h uint128 and_128 (uint128 a, uint128 b); uint128 36 src/dps8/dps8_math128.h int128 and_s128 (int128 a, uint128 b); uint128 37 src/dps8/dps8_math128.h uint128 or_128 (uint128 a, uint128 b); uint128 38 src/dps8/dps8_math128.h uint128 xor_128 (uint128 a, uint128 b); uint128 39 src/dps8/dps8_math128.h uint128 add_128 (uint128 a, uint128 b); uint128 40 src/dps8/dps8_math128.h uint128 subtract_128 (uint128 a, uint128 b); uint128 41 src/dps8/dps8_math128.h uint128 multiply_128 (uint128 a, uint128 b); uint128 43 src/dps8/dps8_math128.h uint128 divide_128_16 (uint128 a, uint16_t b, uint16_t * rem); uint128 44 src/dps8/dps8_math128.h uint128 divide_128_32 (uint128 a, uint32_t b, uint32_t * rem); uint128 45 src/dps8/dps8_math128.h uint128 divide_128 (uint128 a, uint128 b, uint128 * rem); uint128 46 src/dps8/dps8_math128.h uint128 complement_128 (uint128 a); uint128 47 src/dps8/dps8_math128.h uint128 negate_128 (uint128 a); uint128 49 src/dps8/dps8_math128.h uint128 lshift_128 (uint128 a, unsigned int n); uint128 51 src/dps8/dps8_math128.h uint128 rshift_128 (uint128 a, unsigned int n); uint128 1191 src/dps8/dps8_scu.c uint128 big = construct_128 (0, cpu.instrCnt); uint128 1199 src/dps8/dps8_scu.c uint128 days = construct_128 (0, scu[0].elapsed_days); uint128 1936 src/dps8/dps8_utils.c static void print_uint128o_r (uint128 n, char * p) uint128 1963 src/dps8/dps8_utils.c print_uint128o_r ((uint128) n, p); uint128 1967 src/dps8/dps8_utils.c static void print_uint128_r (uint128 n, char * p) uint128 2002 src/dps8/dps8_utils.c print_uint128_r ((uint128) n, p);