IntAllocator
Description
Allocator backing the integer’s storage.
Parameters
| Name | Direction | Description |
|---|---|---|
value |
in | Integer to query. |
Usage example (Cross-references)
Usage examples (Cross-references)
- In
Io.c:3244:
}
Str temp = StrInitFromCstr(start, StrIterIndex(&si) - StrIterIndex(&saved), IntAllocator(value));
Int parsed = IntInit(IntAllocator(value));
bool ok = IntTryFromStrRadix(&parsed, StrBegin(&temp), radix);- In
Io.c:3245:
Str temp = StrInitFromCstr(start, StrIterIndex(&si) - StrIterIndex(&saved), IntAllocator(value));
Int parsed = IntInit(IntAllocator(value));
bool ok = IntTryFromStrRadix(&parsed, StrBegin(&temp), radix);- In
Float.c:353:
ValidateInt(value);
*out = FloatInit(IntAllocator(value));
if (!IntTryClone(&out->significand, value)) {
FloatDeinit(out);- In
Float.c:356:
if (!IntTryClone(&out->significand, value)) {
FloatDeinit(out);
*out = FloatInit(IntAllocator(value));
return false;
}- In
Float.c:385:
ValidateInt(value);
(void)alloc;
result = FloatInit(IntAllocator(value));
(void)float_try_from_int_value(&result, value);
float_normalize(&result);- In
Float.c:409:
ValidateFloat(value);
Int temp = IntInit(IntAllocator(result));
if (FloatIsNegative(value)) {- In
Int.c:156:
static bool sint_add(SignedInt *result, SignedInt *a, SignedInt *b) {
SignedInt temp = sint_init(IntAllocator(&result->magnitude));
if (a->negative == b->negative) {- In
Int.c:205:
static bool sint_mul_unsigned(SignedInt *result, SignedInt *a, Int *b) {
SignedInt temp = sint_init(IntAllocator(&result->magnitude));
if (!int_mul(&temp.magnitude, &a->magnitude, b)) {- In
Int.c:235:
Int lhs;
Int rhs;
Int result = IntInit(IntAllocator(value));
if (!int_try_clone_value(&lhs, value)) {- In
Int.c:240:
return false;
}
if (!int_try_from_u64(&rhs, factor, IntAllocator(value))) {
IntDeinit(&lhs);
return false;- In
Int.c:260:
Int lhs;
Int rhs;
Int result = IntInit(IntAllocator(value));
if (!int_try_clone_value(&lhs, value)) {- In
Int.c:265:
return false;
}
if (!int_try_from_u64(&rhs, addend, IntAllocator(value))) {
IntDeinit(&lhs);
return false;- In
Int.c:326:
ValidateInt(out);
result = IntInit(IntAllocator(out));
if (!int_validate_radix(radix)) {- In
Int.c:447:
ValidateInt(value);
*out = IntInit(IntAllocator(value));
if (!BitVecTryClone(INT_BITS(out), INT_BITS(value))) {
return false;- In
Int.c:464:
ValidateInt(value);
clone = IntInit(IntAllocator(value));
(void)int_try_clone_value(&clone, value);
return clone;- In
Int.c:1066:
bool carry = false;
if (!int_try_init_with_capacity(&temp, max_bits + 1, IntAllocator(result))) {
return false;
}- In
Int.c:1148:
bool borrow = false;
if (!int_try_init_with_capacity(&temp, a_bits, IntAllocator(result))) {
return false;
}- In
Int.c:1183:
bool ok = false;
if (!int_try_from_u64(&rhs, subtrahend, IntAllocator(value))) {
return false;
}- In
Int.c:1210:
u64 b_bits = IntBitLength(b);
Int acc = IntInit(IntAllocator(result));
if (IntIsZero(a) || IntIsZero(b)) {- In
Int.c:1224:
Int partial;
Int next = IntInit(IntAllocator(result));
if (!int_try_clone_value(&partial, a)) {- In
Int.c:1299:
Int current;
if (!int_try_from_u64(&acc, 1, IntAllocator(result))) {
return false;
}- In
Int.c:1309:
while (exponent > 0) {
if (exponent & 1u) {
Int next = IntInit(IntAllocator(result));
if (!int_mul(&next, &acc, ¤t)) {- In
Int.c:1323:
exponent >>= 1u;
if (exponent > 0) {
Int next = IntInit(IntAllocator(result));
if (!IntSquare(&next, ¤t)) {- In
Int.c:1363:
}
Int normalized_dividend = IntInit(IntAllocator(quotient));
Int normalized_divisor = IntInit(IntAllocator(quotient));
Int q = IntInit(IntAllocator(quotient));- In
Int.c:1364:
Int normalized_dividend = IntInit(IntAllocator(quotient));
Int normalized_divisor = IntInit(IntAllocator(quotient));
Int q = IntInit(IntAllocator(quotient));
Int r = IntInit(IntAllocator(remainder));- In
Int.c:1365:
Int normalized_dividend = IntInit(IntAllocator(quotient));
Int normalized_divisor = IntInit(IntAllocator(quotient));
Int q = IntInit(IntAllocator(quotient));
Int r = IntInit(IntAllocator(remainder));
bool ok = false;- In
Int.c:1366:
Int normalized_divisor = IntInit(IntAllocator(quotient));
Int q = IntInit(IntAllocator(quotient));
Int r = IntInit(IntAllocator(remainder));
bool ok = false;- In
Int.c:1379:
IntDeinit(&q);
if (!int_try_init_with_capacity(&q, dividend_bits - divisor_bits + 1, IntAllocator(quotient))) {
goto cleanup;
}- In
Int.c:1385:
for (u64 shift = dividend_bits - divisor_bits + 1; shift > 0; shift--) {
u64 bit = shift - 1;
Int shifted = IntInit(IntAllocator(quotient));
if (!int_try_clone_value(&shifted, &normalized_divisor) || !IntShiftLeft(&shifted, bit)) {- In
Int.c:1393:
if (IntGE(&r, &shifted)) {
Int next = IntInit(IntAllocator(quotient));
if (!int_sub(&next, &r, &shifted)) {- In
Int.c:1414:
} else {
IntDeinit(&q);
q = IntInit(IntAllocator(quotient));
}- In
Int.c:1436:
bool int_div(Int *result, const Int *dividend, const Int *divisor) {
Int quotient = IntInit(IntAllocator(result));
Int remainder = IntInit(IntAllocator(result));- In
Int.c:1437:
bool int_div(Int *result, const Int *dividend, const Int *divisor) {
Int quotient = IntInit(IntAllocator(result));
Int remainder = IntInit(IntAllocator(result));
if (!int_div_mod("ient, &remainder, dividend, divisor)) {- In
Int.c:1460:
}
Int quotient = IntInit(IntAllocator(result));
Int remainder = IntInit(IntAllocator(result));- In
Int.c:1461:
Int quotient = IntInit(IntAllocator(result));
Int remainder = IntInit(IntAllocator(result));
if (!int_div_mod("ient, &remainder, dividend, divisor)) {- In
Int.c:1480:
bool int_div_u64(Int *result, const Int *dividend, u64 divisor) {
Int divisor_value = IntInit(IntAllocator(dividend));
if (!int_try_from_u64(&divisor_value, divisor, IntAllocator(dividend))) {- In
Int.c:1482:
Int divisor_value = IntInit(IntAllocator(dividend));
if (!int_try_from_u64(&divisor_value, divisor, IntAllocator(dividend))) {
IntDeinit(&divisor_value);
return false;- In
Int.c:1493:
bool int_div_i64(Int *result, const Int *dividend, i64 divisor) {
Int divisor_value = IntInit(IntAllocator(dividend));
if (!int_try_from_i64_with_allocator(&divisor_value, divisor, IntAllocator(dividend))) {- In
Int.c:1495:
Int divisor_value = IntInit(IntAllocator(dividend));
if (!int_try_from_i64_with_allocator(&divisor_value, divisor, IntAllocator(dividend))) {
IntDeinit(&divisor_value);
return false;- In
Int.c:1506:
bool int_div_exact_u64(Int *result, const Int *dividend, u64 divisor) {
Int divisor_value = IntInit(IntAllocator(dividend));
if (!int_try_from_u64(&divisor_value, divisor, IntAllocator(dividend))) {- In
Int.c:1508:
Int divisor_value = IntInit(IntAllocator(dividend));
if (!int_try_from_u64(&divisor_value, divisor, IntAllocator(dividend))) {
IntDeinit(&divisor_value);
return false;- In
Int.c:1519:
bool int_div_exact_i64(Int *result, const Int *dividend, i64 divisor) {
Int divisor_value = IntInit(IntAllocator(dividend));
if (!int_try_from_i64_with_allocator(&divisor_value, divisor, IntAllocator(dividend))) {- In
Int.c:1521:
Int divisor_value = IntInit(IntAllocator(dividend));
if (!int_try_from_i64_with_allocator(&divisor_value, divisor, IntAllocator(dividend))) {
IntDeinit(&divisor_value);
return false;- In
Int.c:1532:
bool int_div_mod_u64(Int *quotient, Int *remainder, const Int *dividend, u64 divisor) {
Int divisor_value = IntInit(IntAllocator(dividend));
if (!int_try_from_u64(&divisor_value, divisor, IntAllocator(dividend))) {- In
Int.c:1534:
Int divisor_value = IntInit(IntAllocator(dividend));
if (!int_try_from_u64(&divisor_value, divisor, IntAllocator(dividend))) {
IntDeinit(&divisor_value);
return false;- In
Int.c:1545:
bool int_div_mod_i64(Int *quotient, Int *remainder, const Int *dividend, i64 divisor) {
Int divisor_value = IntInit(IntAllocator(dividend));
if (!int_try_from_i64_with_allocator(&divisor_value, divisor, IntAllocator(dividend))) {- In
Int.c:1547:
Int divisor_value = IntInit(IntAllocator(dividend));
if (!int_try_from_i64_with_allocator(&divisor_value, divisor, IntAllocator(dividend))) {
IntDeinit(&divisor_value);
return false;- In
Int.c:1566:
}
Int divisor_value = IntInit(IntAllocator(dividend));
Int remainder = IntInit(IntAllocator(quotient));
u64 rem = 0;- In
Int.c:1567:
Int divisor_value = IntInit(IntAllocator(dividend));
Int remainder = IntInit(IntAllocator(quotient));
u64 rem = 0;- In
Int.c:1570:
u64 rem = 0;
if (!int_try_from_u64(&divisor_value, divisor, IntAllocator(dividend))) {
IntDeinit(&divisor_value);
IntDeinit(&remainder);- In
Int.c:1589:
bool int_mod(Int *result, const Int *dividend, const Int *divisor) {
Int quotient = IntInit(IntAllocator(result));
Int remainder = IntInit(IntAllocator(result));- In
Int.c:1590:
bool int_mod(Int *result, const Int *dividend, const Int *divisor) {
Int quotient = IntInit(IntAllocator(result));
Int remainder = IntInit(IntAllocator(result));
if (!int_div_mod("ient, &remainder, dividend, divisor)) {- In
Int.c:1604:
bool int_mod_u64_into(Int *result, const Int *dividend, u64 divisor) {
Int quotient = IntInit(IntAllocator(result));
bool ok = int_div_mod_u64("ient, result, dividend, divisor);- In
Int.c:1612:
bool int_mod_i64_into(Int *result, const Int *dividend, i64 divisor) {
Int quotient = IntInit(IntAllocator(result));
bool ok = int_div_mod_i64("ient, result, dividend, divisor);- In
Int.c:1627:
}
Int quotient = IntInit(IntAllocator(value));
u64 rem = int_div_u64_rem("ient, value, modulus);- In
Int.c:1639:
ValidateInt(b);
Int x = IntInit(IntAllocator(a));
Int y = IntInit(IntAllocator(b));- In
Int.c:1640:
Int x = IntInit(IntAllocator(a));
Int y = IntInit(IntAllocator(b));
if (!int_try_clone_value(&x, a) || !int_try_clone_value(&y, b)) {- In
Int.c:1649:
while (!IntIsZero(&y)) {
Int r = IntInit(IntAllocator(result));
if (!int_mod(&r, &x, &y)) {- In
Int.c:1673:
if (IntIsZero(a) || IntIsZero(b)) {
Int zero = IntInit(IntAllocator(result));
int_replace(result, &zero);
return true;- In
Int.c:1678:
}
Int gcd = IntInit(IntAllocator(result));
Int quotient = IntInit(IntAllocator(result));
Int lcm = IntInit(IntAllocator(result));- In
Int.c:1679:
Int gcd = IntInit(IntAllocator(result));
Int quotient = IntInit(IntAllocator(result));
Int lcm = IntInit(IntAllocator(result));- In
Int.c:1680:
Int gcd = IntInit(IntAllocator(result));
Int quotient = IntInit(IntAllocator(result));
Int lcm = IntInit(IntAllocator(result));
if (!IntGCD(&gcd, a, b) || !int_div("ient, a, &gcd) || !int_mul(&lcm, "ient, b)) {- In
Int.c:1709:
if (IntIsZero(value)) {
Int zero_root = IntInit(IntAllocator(root));
Int zero_rem = IntInit(IntAllocator(remainder));- In
Int.c:1710:
if (IntIsZero(value)) {
Int zero_root = IntInit(IntAllocator(root));
Int zero_rem = IntInit(IntAllocator(remainder));
int_replace(root, &zero_root);- In
Int.c:1717:
}
if (degree == 1) {
Int exact_root = IntInit(IntAllocator(root));
Int zero_rem = IntInit(IntAllocator(remainder));- In
Int.c:1718:
if (degree == 1) {
Int exact_root = IntInit(IntAllocator(root));
Int zero_rem = IntInit(IntAllocator(remainder));
if (!IntTryClone(&exact_root, value)) {- In
Int.c:1732:
u64 bits = IntBitLength(value);
u64 high_shift = bits / degree;
Int low = IntInit(IntAllocator(root));
Int high = IntInit(IntAllocator(root));
Int best = IntInit(IntAllocator(root));- In
Int.c:1733:
u64 high_shift = bits / degree;
Int low = IntInit(IntAllocator(root));
Int high = IntInit(IntAllocator(root));
Int best = IntInit(IntAllocator(root));
Int one = IntInit(IntAllocator(root));- In
Int.c:1734:
Int low = IntInit(IntAllocator(root));
Int high = IntInit(IntAllocator(root));
Int best = IntInit(IntAllocator(root));
Int one = IntInit(IntAllocator(root));- In
Int.c:1735:
Int high = IntInit(IntAllocator(root));
Int best = IntInit(IntAllocator(root));
Int one = IntInit(IntAllocator(root));
if ((bits % degree) != 0) {- In
Int.c:1744:
}
if (!int_try_from_u64(&high, 1, IntAllocator(root)) || !int_try_from_u64(&one, 1, IntAllocator(root))) {
IntDeinit(&low);
IntDeinit(&high);- In
Int.c:1761:
while (IntLE(&low, &high)) {
Int sum = IntInit(IntAllocator(root));
Int mid = IntInit(IntAllocator(root));
Int mid_pow = IntInit(IntAllocator(root));- In
Int.c:1762:
while (IntLE(&low, &high)) {
Int sum = IntInit(IntAllocator(root));
Int mid = IntInit(IntAllocator(root));
Int mid_pow = IntInit(IntAllocator(root));
int cmp = 0;- In
Int.c:1763:
Int sum = IntInit(IntAllocator(root));
Int mid = IntInit(IntAllocator(root));
Int mid_pow = IntInit(IntAllocator(root));
int cmp = 0;- In
Int.c:1790:
if (cmp <= 0) {
Int next = IntInit(IntAllocator(root));
IntDeinit(&best);- In
Int.c:1816:
low = next;
} else {
Int next = IntInit(IntAllocator(root));
if (IntEQ(&mid, &one) || IntIsZero(&mid)) {- In
Int.c:1820:
if (IntEQ(&mid, &one) || IntIsZero(&mid)) {
IntDeinit(&high);
high = IntInit(IntAllocator(root));
} else {
if (!int_sub(&next, &mid, &one)) {- In
Int.c:1842:
{
Int power = IntInit(IntAllocator(root));
Int rem = IntInit(IntAllocator(remainder));- In
Int.c:1843:
{
Int power = IntInit(IntAllocator(root));
Int rem = IntInit(IntAllocator(remainder));
if (!int_pow_u64(&power, &best, degree) || !int_sub(&rem, value, &power)) {- In
Int.c:1868:
bool IntRoot(Int *result, const Int *value, u64 degree) {
Int root = IntInit(IntAllocator(result));
Int remainder = IntInit(IntAllocator(result));- In
Int.c:1869:
bool IntRoot(Int *result, const Int *value, u64 degree) {
Int root = IntInit(IntAllocator(result));
Int remainder = IntInit(IntAllocator(result));
if (!IntRootRem(&root, &remainder, value, degree)) {- In
Int.c:1893:
ValidateInt(value);
Int root = IntInit(IntAllocator(value));
Int remainder = IntInit(IntAllocator(value));
bool result = false;- In
Int.c:1894:
Int root = IntInit(IntAllocator(value));
Int remainder = IntInit(IntAllocator(value));
bool result = false;- In
Int.c:1923:
for (u64 degree = 2; degree <= max_degree; degree++) {
Int root = IntInit(IntAllocator(value));
Int remainder = IntInit(IntAllocator(value));
bool exact = false;- In
Int.c:1924:
for (u64 degree = 2; degree <= max_degree; degree++) {
Int root = IntInit(IntAllocator(value));
Int remainder = IntInit(IntAllocator(value));
bool exact = false;- In
Int.c:1958:
}
Int aa = IntInit(IntAllocator(a));
Int nn = IntInit(IntAllocator(n));
int result = 1;- In
Int.c:1959:
Int aa = IntInit(IntAllocator(a));
Int nn = IntInit(IntAllocator(n));
int result = 1;- In
Int.c:2030:
}
Int ar = IntInit(IntAllocator(result));
Int br = IntInit(IntAllocator(result));
Int sum = IntInit(IntAllocator(result));- In
Int.c:2031:
Int ar = IntInit(IntAllocator(result));
Int br = IntInit(IntAllocator(result));
Int sum = IntInit(IntAllocator(result));- In
Int.c:2032:
Int ar = IntInit(IntAllocator(result));
Int br = IntInit(IntAllocator(result));
Int sum = IntInit(IntAllocator(result));
if (!int_mod(&ar, a, modulus) || !int_mod(&br, b, modulus) || !int_add(&sum, &ar, &br) ||- In
Int.c:2059:
}
Int ar = IntInit(IntAllocator(result));
Int br = IntInit(IntAllocator(result));- In
Int.c:2060:
Int ar = IntInit(IntAllocator(result));
Int br = IntInit(IntAllocator(result));
if (!int_mod(&ar, a, modulus) || !int_mod(&br, b, modulus)) {- In
Int.c:2075:
}
} else {
Int diff = IntInit(IntAllocator(result));
if (!int_sub(&diff, &br, &ar)) {- In
Int.c:2084:
}
if (IntIsZero(&diff)) {
Int zero = IntInit(IntAllocator(result));
int_replace(result, &zero);
} else {- In
Int.c:2114:
}
Int ar = IntInit(IntAllocator(result));
Int br = IntInit(IntAllocator(result));
Int prod = IntInit(IntAllocator(result));- In
Int.c:2115:
Int ar = IntInit(IntAllocator(result));
Int br = IntInit(IntAllocator(result));
Int prod = IntInit(IntAllocator(result));- In
Int.c:2116:
Int ar = IntInit(IntAllocator(result));
Int br = IntInit(IntAllocator(result));
Int prod = IntInit(IntAllocator(result));
if (!int_mod(&ar, a, modulus) || !int_mod(&br, b, modulus) || !int_mul(&prod, &ar, &br) ||- In
Int.c:2143:
}
Int inverse = IntInit(IntAllocator(result));
Int value = IntInit(IntAllocator(result));
bool ok = false;- In
Int.c:2144:
Int inverse = IntInit(IntAllocator(result));
Int value = IntInit(IntAllocator(result));
bool ok = false;- In
Int.c:2178:
}
Int acc = IntInit(IntAllocator(result));
Int base_mod = IntInit(IntAllocator(result));- In
Int.c:2179:
Int acc = IntInit(IntAllocator(result));
Int base_mod = IntInit(IntAllocator(result));
if (!int_try_from_u64(&acc, 1, IntAllocator(result))) {- In
Int.c:2181:
Int base_mod = IntInit(IntAllocator(result));
if (!int_try_from_u64(&acc, 1, IntAllocator(result))) {
IntDeinit(&base_mod);
return false;- In
Int.c:2193:
while (exponent > 0) {
if (exponent & 1u) {
Int next = IntInit(IntAllocator(result));
if (!IntModMul(&next, &acc, &base_mod, modulus)) {- In
Int.c:2207:
exponent >>= 1u;
if (exponent > 0) {
Int next = IntInit(IntAllocator(result));
if (!IntModMul(&next, &base_mod, &base_mod, modulus)) {- In
Int.c:2236:
}
Int acc = IntInit(IntAllocator(result));
Int base_mod = IntInit(IntAllocator(result));
Int exp = IntInit(IntAllocator(exponent));- In
Int.c:2237:
Int acc = IntInit(IntAllocator(result));
Int base_mod = IntInit(IntAllocator(result));
Int exp = IntInit(IntAllocator(exponent));- In
Int.c:2238:
Int acc = IntInit(IntAllocator(result));
Int base_mod = IntInit(IntAllocator(result));
Int exp = IntInit(IntAllocator(exponent));
if (!int_try_from_u64(&acc, 1, IntAllocator(result)) || !IntTryClone(&exp, exponent) ||- In
Int.c:2240:
Int exp = IntInit(IntAllocator(exponent));
if (!int_try_from_u64(&acc, 1, IntAllocator(result)) || !IntTryClone(&exp, exponent) ||
!int_mod(&acc, &acc, modulus) || !int_mod(&base_mod, base, modulus)) {
IntDeinit(&acc);- In
Int.c:2250:
while (!IntIsZero(&exp)) {
if (int_is_odd(&exp)) {
Int next = IntInit(IntAllocator(result));
if (!IntModMul(&next, &acc, &base_mod, modulus)) {- In
Int.c:2270:
}
if (!IntIsZero(&exp)) {
Int next = IntInit(IntAllocator(result));
if (!IntModMul(&next, &base_mod, &base_mod, modulus)) {- In
Int.c:2308:
}
Int reduced = IntInit(IntAllocator(result));
SignedInt t = sint_init(IntAllocator(result));
SignedInt new_t = sint_from_u64(1, IntAllocator(result));- In
Int.c:2309:
Int reduced = IntInit(IntAllocator(result));
SignedInt t = sint_init(IntAllocator(result));
SignedInt new_t = sint_from_u64(1, IntAllocator(result));
Int r = IntInit(IntAllocator(modulus));- In
Int.c:2310:
Int reduced = IntInit(IntAllocator(result));
SignedInt t = sint_init(IntAllocator(result));
SignedInt new_t = sint_from_u64(1, IntAllocator(result));
Int r = IntInit(IntAllocator(modulus));
Int new_r = IntInit(IntAllocator(result));- In
Int.c:2311:
SignedInt t = sint_init(IntAllocator(result));
SignedInt new_t = sint_from_u64(1, IntAllocator(result));
Int r = IntInit(IntAllocator(modulus));
Int new_r = IntInit(IntAllocator(result));
Int one = int_from_u64(1, IntAllocator(result));- In
Int.c:2312:
SignedInt new_t = sint_from_u64(1, IntAllocator(result));
Int r = IntInit(IntAllocator(modulus));
Int new_r = IntInit(IntAllocator(result));
Int one = int_from_u64(1, IntAllocator(result));
bool ok = false;- In
Int.c:2313:
Int r = IntInit(IntAllocator(modulus));
Int new_r = IntInit(IntAllocator(result));
Int one = int_from_u64(1, IntAllocator(result));
bool ok = false;- In
Int.c:2336:
while (!IntIsZero(&new_r)) {
Int q = IntInit(IntAllocator(result));
Int rem = IntInit(IntAllocator(result));
SignedInt q_new_t = sint_init(IntAllocator(result));- In
Int.c:2337:
while (!IntIsZero(&new_r)) {
Int q = IntInit(IntAllocator(result));
Int rem = IntInit(IntAllocator(result));
SignedInt q_new_t = sint_init(IntAllocator(result));
SignedInt next_t = sint_init(IntAllocator(result));- In
Int.c:2338:
Int q = IntInit(IntAllocator(result));
Int rem = IntInit(IntAllocator(result));
SignedInt q_new_t = sint_init(IntAllocator(result));
SignedInt next_t = sint_init(IntAllocator(result));
Int next_r = IntInit(IntAllocator(result));- In
Int.c:2339:
Int rem = IntInit(IntAllocator(result));
SignedInt q_new_t = sint_init(IntAllocator(result));
SignedInt next_t = sint_init(IntAllocator(result));
Int next_r = IntInit(IntAllocator(result));- In
Int.c:2340:
SignedInt q_new_t = sint_init(IntAllocator(result));
SignedInt next_t = sint_init(IntAllocator(result));
Int next_r = IntInit(IntAllocator(result));
if (!int_div_mod(&q, &rem, &r, &new_r) || !sint_mul_unsigned(&q_new_t, &new_t, &q) ||- In
Int.c:2374:
if (IntEQ(&r, &one)) {
Int positive = IntInit(IntAllocator(result));
Int mag_mod = IntInit(IntAllocator(result));- In
Int.c:2375:
if (IntEQ(&r, &one)) {
Int positive = IntInit(IntAllocator(result));
Int mag_mod = IntInit(IntAllocator(result));
if (!int_mod(&mag_mod, &t.magnitude, modulus)) {- In
Int.c:2438:
}
Int a = IntInit(IntAllocator(result));
bool ok = false;- In
Int.c:2447:
if (IntIsZero(&a)) {
Int zero = IntInit(IntAllocator(result));
int_replace(result, &zero);
IntDeinit(&a);- In
Int.c:2477:
}
if (int_mod_u64(modulus, 4) == 3) {
Int exponent = IntInit(IntAllocator(modulus));
Int root = IntInit(IntAllocator(result));- In
Int.c:2478:
if (int_mod_u64(modulus, 4) == 3) {
Int exponent = IntInit(IntAllocator(modulus));
Int root = IntInit(IntAllocator(result));
if (!IntTryClone(&exponent, modulus) || !int_add_u64(&exponent, &exponent, 1) || !IntShiftRight(&exponent, 2) ||- In
Int.c:2495:
{
Int q = IntInit(IntAllocator(modulus));
Int z = IntInit(IntAllocator(modulus));
Int c = IntInit(IntAllocator(result));- In
Int.c:2496:
{
Int q = IntInit(IntAllocator(modulus));
Int z = IntInit(IntAllocator(modulus));
Int c = IntInit(IntAllocator(result));
Int t = IntInit(IntAllocator(result));- In
Int.c:2497:
Int q = IntInit(IntAllocator(modulus));
Int z = IntInit(IntAllocator(modulus));
Int c = IntInit(IntAllocator(result));
Int t = IntInit(IntAllocator(result));
Int r = IntInit(IntAllocator(result));- In
Int.c:2498:
Int z = IntInit(IntAllocator(modulus));
Int c = IntInit(IntAllocator(result));
Int t = IntInit(IntAllocator(result));
Int r = IntInit(IntAllocator(result));
Int exponent = IntInit(IntAllocator(result));- In
Int.c:2499:
Int c = IntInit(IntAllocator(result));
Int t = IntInit(IntAllocator(result));
Int r = IntInit(IntAllocator(result));
Int exponent = IntInit(IntAllocator(result));
u64 m = 0;- In
Int.c:2500:
Int t = IntInit(IntAllocator(result));
Int r = IntInit(IntAllocator(result));
Int exponent = IntInit(IntAllocator(result));
u64 m = 0;- In
Int.c:2503:
u64 m = 0;
if (!IntTryClone(&q, modulus) || !int_try_from_u64(&z, 2, IntAllocator(modulus)) || !int_sub_u64(&q, &q, 1)) {
IntDeinit(&q);
IntDeinit(&z);- In
Int.c:2581:
while (int_compare_u64(&t, 1) != 0) {
Int t_power = IntInit(IntAllocator(&t));
u64 i = 0;- In
Int.c:2597:
for (i = 1; i < m; i++) {
Int next = IntInit(IntAllocator(result));
if (!IntSquareMod(&next, &t_power, modulus)) {- In
Int.c:2625:
{
Int b = IntInit(IntAllocator(&c));
Int b_sq = IntInit(IntAllocator(result));
Int next = IntInit(IntAllocator(result));- In
Int.c:2626:
{
Int b = IntInit(IntAllocator(&c));
Int b_sq = IntInit(IntAllocator(result));
Int next = IntInit(IntAllocator(result));- In
Int.c:2627:
Int b = IntInit(IntAllocator(&c));
Int b_sq = IntInit(IntAllocator(result));
Int next = IntInit(IntAllocator(result));
if (!IntTryClone(&b, &c)) {- In
Int.c:2645:
for (u64 j = 0; j + i + 1 < m; j++) {
Int square = IntInit(IntAllocator(result));
if (!IntSquareMod(&square, &b, modulus)) {- In
Int.c:2696:
return false;
}
next = IntInit(IntAllocator(result));
if (!IntModMul(&next, &t, &b_sq, modulus)) {
IntDeinit(&b);- In
Int.c:2769:
{
Int d = IntInit(IntAllocator(value));
Int n_minus_one = IntInit(IntAllocator(value));
u64 s = 0;- In
Int.c:2770:
{
Int d = IntInit(IntAllocator(value));
Int n_minus_one = IntInit(IntAllocator(value));
u64 s = 0;
bool probable = true;- In
Int.c:2795:
for (u64 i = 0; i < (u64)(sizeof(bases) / sizeof(bases[0])); i++) {
Int base = IntInit(IntAllocator(value));
Int x = IntInit(IntAllocator(value));- In
Int.c:2796:
for (u64 i = 0; i < (u64)(sizeof(bases) / sizeof(bases[0])); i++) {
Int base = IntInit(IntAllocator(value));
Int x = IntInit(IntAllocator(value));
if (!int_try_from_u64(&base, bases[i], IntAllocator(value))) {- In
Int.c:2798:
Int x = IntInit(IntAllocator(value));
if (!int_try_from_u64(&base, bases[i], IntAllocator(value))) {
IntDeinit(&base);
IntDeinit(&x);- In
Int.c:2829:
for (u64 r = 1; r < s; r++) {
Int next = IntInit(IntAllocator(value));
if (!IntSquareMod(&next, &x, value)) {- In
Int.c:2873:
if (int_compare_u64(value, 1) <= 0) {
Int two = IntInit(IntAllocator(result));
if (!int_try_from_u64(&two, 2, IntAllocator(result))) {- In
Int.c:2875:
Int two = IntInit(IntAllocator(result));
if (!int_try_from_u64(&two, 2, IntAllocator(result))) {
IntDeinit(&two);
return false;- In
Int.c:2883:
}
Int candidate = IntInit(IntAllocator(result));
if (!IntTryClone(&candidate, value)) {- In
Int.c:2895:
}
if (int_compare_u64(&candidate, 2) <= 0) {
Int two = IntInit(IntAllocator(result));
if (!int_try_from_u64(&two, 2, IntAllocator(result))) {- In
Int.c:2897:
Int two = IntInit(IntAllocator(result));
if (!int_try_from_u64(&two, 2, IntAllocator(result))) {
IntDeinit(&two);
IntDeinit(&candidate);- In
Int.Type.c:88:
bool result =
BitVecLen(&clone.bits) == BitVecLen(&original.bits) && IntAllocator(&clone) == IntAllocator(&original) &&
IntAllocator(&clone)->allocate == IntAllocator(&original)->allocate &&
IntAllocator(&clone)->remap == IntAllocator(&original)->remap &&- In
Int.Type.c:89:
bool result =
BitVecLen(&clone.bits) == BitVecLen(&original.bits) && IntAllocator(&clone) == IntAllocator(&original) &&
IntAllocator(&clone)->allocate == IntAllocator(&original)->allocate &&
IntAllocator(&clone)->remap == IntAllocator(&original)->remap &&
IntAllocator(&clone)->deallocate == IntAllocator(&original)->deallocate &&- In
Int.Type.c:90:
BitVecLen(&clone.bits) == BitVecLen(&original.bits) && IntAllocator(&clone) == IntAllocator(&original) &&
IntAllocator(&clone)->allocate == IntAllocator(&original)->allocate &&
IntAllocator(&clone)->remap == IntAllocator(&original)->remap &&
IntAllocator(&clone)->deallocate == IntAllocator(&original)->deallocate &&
IntAllocator(&clone)->effort == IntAllocator(&original)->effort &&- In
Int.Type.c:91:
IntAllocator(&clone)->allocate == IntAllocator(&original)->allocate &&
IntAllocator(&clone)->remap == IntAllocator(&original)->remap &&
IntAllocator(&clone)->deallocate == IntAllocator(&original)->deallocate &&
IntAllocator(&clone)->effort == IntAllocator(&original)->effort &&
IntAllocator(&clone)->retry_limit == IntAllocator(&original)->retry_limit &&- In
Int.Type.c:92:
IntAllocator(&clone)->remap == IntAllocator(&original)->remap &&
IntAllocator(&clone)->deallocate == IntAllocator(&original)->deallocate &&
IntAllocator(&clone)->effort == IntAllocator(&original)->effort &&
IntAllocator(&clone)->retry_limit == IntAllocator(&original)->retry_limit &&
BitVecGet(&clone.bits, 0) == true && BitVecGet(&clone.bits, 1) == false && BitVecGet(&clone.bits, 2) == true;- In
Int.Type.c:93:
IntAllocator(&clone)->deallocate == IntAllocator(&original)->deallocate &&
IntAllocator(&clone)->effort == IntAllocator(&original)->effort &&
IntAllocator(&clone)->retry_limit == IntAllocator(&original)->retry_limit &&
BitVecGet(&clone.bits, 0) == true && BitVecGet(&clone.bits, 1) == false && BitVecGet(&clone.bits, 2) == true;- In
Access.h:21:
/// TAGS: Float, Access, Allocator
///
#define FloatAllocator(value) IntAllocator(&(value)->significand)
#ifdef __cplusplus- In
Convert.h:574:
///
#define IntTryToStr(...) OVERLOAD(IntTryToStr, __VA_ARGS__)
#define IntTryToStr_2(out, value) int_try_to_str((out), (value), IntAllocator((value)))
#define IntTryToStr_3(out, value, alloc) int_try_to_str((out), (value), (alloc))- In
Convert.h:594:
///
#define IntToStr(...) OVERLOAD(IntToStr, __VA_ARGS__)
#define IntToStr_1(value) int_to_str((value), IntAllocator((value)))
#define IntToStr_2(value, alloc) int_to_str((value), (alloc))- In
Convert.h:617:
#define IntTryToStrRadix(...) OVERLOAD(IntTryToStrRadix, __VA_ARGS__)
#define IntTryToStrRadix_4(out, value, radix, uppercase) \
int_try_to_str_radix((out), (value), (radix), (uppercase), IntAllocator((value)))
#define IntTryToStrRadix_5(out, value, radix, uppercase, alloc) \
int_try_to_str_radix((out), (value), (radix), (uppercase), (alloc))- In
Convert.h:641:
#define IntToStrRadix(...) OVERLOAD(IntToStrRadix, __VA_ARGS__)
#define IntToStrRadix_3(value, radix, uppercase) \
int_to_str_radix((value), (radix), (uppercase), IntAllocator((value)))
#define IntToStrRadix_4(value, radix, uppercase, alloc) int_to_str_radix((value), (radix), (uppercase), (alloc))
Last updated on