Verifying ratpoints in Lean: a blueprint

A The correspondence with the C code

The model is checked against ratpoints v3.1.1 (commit 1a998538dfa8). The C files below are those of the library and main.c, whose parts that the command-line program does not mirror are excluded. Every line of code of them lies in exactly one recorded range: a range is either modelled by the Lean declarations named, or excluded from the model with a reason. Each recorded range is checked against the text it had when it was reviewed.

file

lines of code

modelled

excluded

not recorded

find_points.c

3244

2589

655

0

sift.c

820

660

160

0

init.c

302

238

64

0

sturm.c

215

202

13

0

rp-private.h

282

246

36

0

ratpoints.h

128

114

14

0

primes.h

11

11

0

0

gen_find_points_h.c

76

60

16

0

gen_init_sieve_h.c

26

13

13

0

main.c

779

727

52

0

total

5883

4860

1023

0

find_points.c

  • find_points.c:30-30: excluded (other): the include of the private header; the model has no headers

  • find_points.c:32-32: modelled by Ratpoints.primeTable

  • find_points.c:37-37: modelled by Ratpoints.Sieve.inversesMod, Ratpoints.Sieve.sieves0, Ratpoints.Sieve.squaresMod (deviation of Ratpoints.Sieve.inversesMod: a function of p, computed when it is called, for the row of p in the table inverses that the build generates and that find_points.c includes; the trial stops before p and gives 0 when it finds nothing, where inv_mod_p would not stop, which never happens for a prime p and a residue other than 0.) (deviation of Ratpoints.Sieve.sieves0: a function of p, computed when it is called, for the row of p in the table sieves0 that the build generates and that find_points.c includes; its first (p + chunk - 1) rbaPack words, for the row of RBA_PACK (RATPOINTS_MAX_PRIME_EVEN + RATPOINTS_CHUNK - 1) words whose other words are 0 and never read.) (deviation of Ratpoints.Sieve.squaresMod: a function of p, computed when it is called, for the row of p in the table squares that the build generates and that find_points.c includes.)

  • find_points.c:41-43: excluded (threads): the declarations of the lock of the tables of rows and of the destruction of the pool of threads; the model sieves the blocks in turn on one thread

  • find_points.c:69-118: excluded (instrumentation): RP_PHASE_TIMING and RP_PHASE_COUNTS, development instrumentation: the counters of sift.c declared extern and the timers RP_BC_TIC/TOC, RP_BP_TIC/TOC, RP_SIFT_TIC/TOC, RP_INIT_TIC/TOC and RP_SETUP_TIC/TOC, which time with rdtsc the part of the exact check that is done once per denominator, the residues of a denominator modulo the moduli of the first two stages, the whole of sift, the building of a row and the set-up of a denominator, with the arm of the production build, where they are empty

  • find_points.c:121-121: modelled by Ratpoints.maxDivisors

  • find_points.c:124-124: modelled by Ratpoints.maxArraySize

  • find_points.c:133-133: modelled by Ratpoints.Sieve.sieveInit (deviation of Ratpoints.Sieve.sieveInit: a function of p, for the entry of p in the table of the pointers to the functions that the build generates, one for each prime, and that init.c includes; the kind of the function, for the pointer to it.)

  • find_points.c:147-149: modelled by Ratpoints.ModulusCandidate (deviation of Ratpoints.ModulusCandidate: a natural number for the long modulus, a UInt64 for the unsigned long mask, an integer for the short count, the codes a list of natural numbers, for the array of RP_MAX_FACTORS shorts, and the sieve entry an option, none for the null pointer.)

  • find_points.c:153-153: modelled by Ratpoints.maxModuli

  • find_points.c:155-155: modelled by Ratpoints.Setup.DenInfo (deviation of Ratpoints.Setup.DenInfo: natural numbers for the int fields, which the primes fit, a cofactor below the square of a prime of the table among them (Ratpoints.Setup.mul_self_lt_of_mem_primeTable), and the valuations and the slopes for coefficients below 2 ^ (2 ^ 31 - 1).)

  • find_points.c:157-161: modelled by Ratpoints.Sieve.ForbiddenEntry (deviation of Ratpoints.Sieve.ForbiddenEntry: the words as an array, for the pointers start and end into the pattern sieves0 of the build or into the buffer of the arguments; a natural number for the long p and for the unsigned long reciprocal magic.)

  • find_points.c:166-166: modelled by Ratpoints.Sieve.ForbiddenVal (deviation of Ratpoints.Sieve.ForbiddenVal: a natural number for the long p, and one for the unsigned long mask, so that it holds every valuation of a denominator, also beyond the 64 bits of a word (Ratpoints.Sieve.forbiddenValuations).)

  • find_points.c:181-270: excluded (memory): pointer_align, which aligns the buffers and the survivors array; ba_buffer_need, alloc_ba_buffer and ensure_ba_buffer, which size, allocate and enlarge the buffer from which the builders take the rows of the tables; num_powers, the number of prime powers below RATPOINTS_MAX_PRIME_EVEN, which sizes the buffers of the sieve entries and of the prime powers (and gives add_moduli its bound on the prime powers it keeps, line 2351, which never binds); and hold_nothing, which clears the pointers to the buffers: the model allocates nothing itself and keeps the rows in tables of its own

  • find_points.c:272-375: excluded (interface): find_points_init, which a caller of the library calls before find_points_work: it answers a degree outside 0, ..., RATPOINTS_MAX_DEGREE with the work length -1, but find_points_work refuses such a degree itself (lines 4557-4558, which the model has), so the work length -1, refused at lines 4621-4622, matters only to a caller who changes the degree between the two calls; it allocates the scratch integers work and the buffers and arrays of the arguments, giving all of them back when one cannot be had, clears the pointer to the pool of threads, and prints messages under DEBUG; the model allocates nothing

  • find_points.c:377-416: excluded (memory): find_points_clear, which destroys the pool of threads, clears the scratch integers, frees the buffers and arrays of the arguments and clears the pointers to them, with messages under DEBUG; the model allocates nothing

  • find_points.c:422-422: modelled by Ratpoints.veryBig

  • find_points.c:424-454: modelled by Ratpoints.Setup.valuation (deviation of Ratpoints.Setup.valuation: one function for valuation on GMP integers, with its scratch integer vvv, and valuation1 on longs, which gives v alone and is the first component; natural numbers for |n|, the quotients and the remainders; the pair returned, for the remainder that valuation stores through its pointer r.)

  • find_points.c:464-471: modelled by Ratpoints.Sieve.ceilSqrt (deviation of Ratpoints.Sieve.ceilSqrt: the exact square root of the natural numbers (Nat.sqrt), for the square root in double corrected by a step either way; 1 for n = 0, where the C code divides by 0; natural numbers for the longs, so that a negative argument, whose square root in double is not a number, cannot occur.)

  • find_points.c:477-492: modelled by Ratpoints.Sieve.modLong (deviation of Ratpoints.Sieve.modLong: one definition for the two copies of the function, in find_points.c and in sift.c, which are the same but for the hooks of the counts of the reductions in sift.c (RP_MOD_TICK, RP_MOD_DIV), empty unless RP_MOD_COUNTS is set; integers for the longs, with the obligations that the values it computes stay in the range of a long stated as lemmas: for 0 ≤ b < 2 ^ 59, 16 b (Ratpoints.fitsLong_sixteen_mul), its negation (Ratpoints.fitsLong_neg), and a + 16 b for -16 b ≤ a < 0 (Ratpoints.fitsLong_add_sixteen_mul), its other values lying between -b and 16 b; Int.tmod for C’s division of longs, which truncates; the multiples 16 b, 8 b, 4 b and 2 b as products, for the shifts of b1.)

  • find_points.c:498-566: modelled by Ratpoints.Sieve.jacobi (deviation of Ratpoints.Sieve.jacobi: one function for jacobi, on the GMP integer lcf, and jacobi1, on a long, which the run calls when all coefficients are longs (use_c_long), with the steps of jacobi: jacobi1 takes the sign of lcf out as (-1 / b)^neg and its value LONG_MIN as LONG_MIN / 4, so that the negation of a negative lcf is a long (Ratpoints.fitsLong_neg_ite_div_four), reduces |lcf| modulo b only for b < 2^59, and does not reduce it after dividing b by the gcd, which changes the steps but not the symbol; the round of the algorithm and its two subtraction loops, which the C code writes out twice each, as helpers (Ratpoints.Sieve.jacobiRound, Ratpoints.Sieve.jacobiReduce, Ratpoints.Sieve.twoSign); natural numbers for the longs b, f, n and m, and integers for the long sign s and the long lcf of jacobi1; f the Euclidean lcf % b, for mpz_fdiv_r_ui with its scratch integer tmp; the tests f = 0 of the C code, at the start and after each division of b, as the condition of the outer loop; the masks of the signs by &&& on natural numbers; the symbol as an integer, for the int.)

  • find_points.c:568-641: modelled by Ratpoints.Sieve.jacobi (deviation of Ratpoints.Sieve.jacobi: one function for jacobi, on the GMP integer lcf, and jacobi1, on a long, which the run calls when all coefficients are longs (use_c_long), with the steps of jacobi: jacobi1 takes the sign of lcf out as (-1 / b)^neg and its value LONG_MIN as LONG_MIN / 4, so that the negation of a negative lcf is a long (Ratpoints.fitsLong_neg_ite_div_four), reduces |lcf| modulo b only for b < 2^59, and does not reduce it after dividing b by the gcd, which changes the steps but not the symbol; the round of the algorithm and its two subtraction loops, which the C code writes out twice each, as helpers (Ratpoints.Sieve.jacobiRound, Ratpoints.Sieve.jacobiReduce, Ratpoints.Sieve.twoSign); natural numbers for the longs b, f, n and m, and integers for the long sign s and the long lcf of jacobi1; f the Euclidean lcf % b, for mpz_fdiv_r_ui with its scratch integer tmp; the tests f = 0 of the C code, at the start and after each division of b, as the condition of the outer loop; the masks of the signs by &&& on natural numbers; the symbol as an integer, for the int.)

  • find_points.c:669-669: modelled by Ratpoints.jacobiPrimes

  • find_points.c:670-670: modelled by Ratpoints.jacobiTable

  • find_points.c:672-681: modelled by Ratpoints.Sieve.JacobiInfo (deviation of Ratpoints.Sieve.JacobiInfo: a list of pairs for the arrays q and nonsq and their count nq, and an array of its own for the array magic; the tables as arrays of their own, for the space that they take from the table jtab of the run; natural numbers for the longs q and the unsigned longs magic, and Booleans for the unsigned chars of the tables and of the signs.)

  • find_points.c:683-708: modelled by Ratpoints.Sieve.jacobiSetup (deviation of Ratpoints.Sieve.jacobiSetup: the tables as fresh arrays, for the table jtab of the run that tab and tab_len give, whose bound Ratpoints.jacobiTable on their total size is kept; the valuations by Ratpoints.Setup.valuation, for mpz_scan1 at 2 and the loop of exact divisions at the odd primes, the power then divided off at once; natural numbers for the GMP integer tmp, the longs and the unsigned longs of the reciprocals, which are ULONG_MAX / q + 1 for the odd primes q; none and the tables returned, for the return values 0 and 1 and the structure that ji points to.)

  • find_points.c:709-713: modelled by Ratpoints.Sieve.nonSquares (deviation of Ratpoints.Sieve.nonSquares: a fresh array, for the space in the table jtab of the run; Booleans for the unsigned chars, natural numbers for the longs x and s.)

  • find_points.c:714-720: modelled by Ratpoints.Sieve.jacobiSetup (deviation of Ratpoints.Sieve.jacobiSetup: the tables as fresh arrays, for the table jtab of the run that tab and tab_len give, whose bound Ratpoints.jacobiTable on their total size is kept; the valuations by Ratpoints.Setup.valuation, for mpz_scan1 at 2 and the loop of exact divisions at the odd primes, the power then divided off at once; natural numbers for the GMP integer tmp, the longs and the unsigned longs of the reciprocals, which are ULONG_MAX / q + 1 for the odd primes q; none and the tables returned, for the return values 0 and 1 and the structure that ji points to.)

  • find_points.c:721-729: modelled by Ratpoints.Sieve.jacobiSigns (deviation of Ratpoints.Sieve.jacobiSigns: Booleans for the bits.)

  • find_points.c:730-731: modelled by Ratpoints.Sieve.jacobiSetup (deviation of Ratpoints.Sieve.jacobiSetup: the tables as fresh arrays, for the table jtab of the run that tab and tab_len give, whose bound Ratpoints.jacobiTable on their total size is kept; the valuations by Ratpoints.Setup.valuation, for mpz_scan1 at 2 and the loop of exact divisions at the odd primes, the power then divided off at once; natural numbers for the GMP integer tmp, the longs and the unsigned longs of the reciprocals, which are ULONG_MAX / q + 1 for the odd primes q; none and the tables returned, for the return values 0 and 1 and the structure that ji points to.)

  • find_points.c:734-759: modelled by Ratpoints.Sieve.jacobiTest (deviation of Ratpoints.Sieve.jacobiTest: the list of the primes with their tables walked with the positions (List.zipIdx), at which the reciprocals are read, for the index i of the arrays; the odd part as the shift by the lowest set bit of the word b (Ratpoints.Sieve.ctz, the loop of RP_CTZL); b mod 8 for b & 7; natural numbers for the longs, the difference b - k q truncated at 0, which is the difference of the C code, since k q ≤ b where the multiplication gives the quotient; a Boolean for the unsigned char s, with exclusive or for ^= and negation for the test s == 0, and the test returned as a Boolean, for the int.)

  • find_points.c:766-776: modelled by Ratpoints.Setup.setupUs1 (deviation of Ratpoints.Setup.setupUs1: the leading coefficient read from the list, for the integer work[0] that the caller sets to |c_d| (lines 4911-4912); lists, for the arrays den_info and divisors of the arguments (ratpoints.h:390) with their terminating zeros; none for a factorization that is not complete or too many divisors, where setup_us1 leaves the flag RATPOINTS_USE_SQUARES1 clear, and the lists returned, where it sets the flag; no output under DEBUG.)

  • find_points.c:777-860: modelled by Ratpoints.Setup.factorLcf (deviation of Ratpoints.Setup.factorLcf: the valuations by Ratpoints.Setup.valuation, for mpz_scan1 at 2 and for the loop of divisions with remainder at the odd primes, the power then divided off at once; natural numbers for the GMP integers work[0] and work[1], the longs, and the int p with its square p * p (line 800), which is below 2 ^ 31 (Ratpoints.Setup.mul_self_lt_of_mem_primeTable); a list of pairs of natural numbers and the cofactor returned, for the int fields p and val of the entries of den_info (they hold the primes, the cofactor below p ^ 2 and, for coefficients below 2 ^ (2 ^ 31 - 1), the valuations: Ratpoints.Setup.DenInfo), for their count, the terminating zero and the integer work[0]; no output under DEBUG.)

  • find_points.c:863-863: modelled by Ratpoints.Setup.setupUs1 (deviation of Ratpoints.Setup.setupUs1: the leading coefficient read from the list, for the integer work[0] that the caller sets to |c_d| (lines 4911-4912); lists, for the arrays den_info and divisors of the arguments (ratpoints.h:390) with their terminating zeros; none for a factorization that is not complete or too many divisors, where setup_us1 leaves the flag RATPOINTS_USE_SQUARES1 clear, and the lists returned, where it sets the flag; no output under DEBUG.)

  • find_points.c:864-880: modelled by Ratpoints.Setup.squarefreeDivisors (deviation of Ratpoints.Setup.squarefreeDivisors: a list, for the array divisors and its pointers div, div0 and div1; natural numbers for the longs, the products x p being formed only for x ≤ ⌊bHigh / p⌋, so that they are at most bHigh and longs for a long bHigh (Ratpoints.Setup.fitsLong_mul_of_le_div).)

  • find_points.c:881-893: modelled by Ratpoints.Setup.setupUs1 (deviation of Ratpoints.Setup.setupUs1: the leading coefficient read from the list, for the integer work[0] that the caller sets to |c_d| (lines 4911-4912); lists, for the arrays den_info and divisors of the arguments (ratpoints.h:390) with their terminating zeros; none for a factorization that is not complete or too many divisors, where setup_us1 leaves the flag RATPOINTS_USE_SQUARES1 clear, and the lists returned, where it sets the flag; no output under DEBUG.)

  • find_points.c:894-912: modelled by Ratpoints.Setup.slope (deviation of Ratpoints.Setup.slope: integers for the ints, and the slope as a natural number; no output under DEBUG.)

  • find_points.c:914-935: modelled by Ratpoints.Setup.setupUs1 (deviation of Ratpoints.Setup.setupUs1: the leading coefficient read from the list, for the integer work[0] that the caller sets to |c_d| (lines 4911-4912); lists, for the arrays den_info and divisors of the arguments (ratpoints.h:390) with their terminating zeros; none for a factorization that is not complete or too many divisors, where setup_us1 leaves the flag RATPOINTS_USE_SQUARES1 clear, and the lists returned, where it sets the flag; no output under DEBUG.)

  • find_points.c:981-981: modelled by Ratpoints.Sieve.squares64

  • find_points.c:983-994: modelled by Ratpoints.Sieve.twoAdic (deviation of Ratpoints.Sieve.twoAdic: the words returned, for the classes cls and the word den_bits that get_2adic_info fills from them in the same function, which Ratpoints.Sieve.numClasses makes from the words; the lowest set bit by the loop of RP_CTZL (Ratpoints.Sieve.ctz); remainders for the masks by 0x3f; natural numbers for the longs k, b, t and a; no output under DEBUG.)

  • find_points.c:995-995: modelled by Ratpoints.Sieve.numClasses (deviation of Ratpoints.Sieve.numClasses: the classes and den_bits returned, for the array cls and the word den_bits that get_2adic_info fills through its pointer arguments, from the words that Ratpoints.Sieve.twoAdic returns; the packed pattern of a class with k ≥ 1 by a function of its own (Ratpoints.Sieve.packPattern); the pattern of a class as one word, for the vector RBA(packed) of line 1098; natural numbers for the longs k, a0 and a, and the remainder by 2 ^ k for the mask (1L << k) - 1; the mask of a stride read from the array of the masks with the default 0 beyond its seven entries, as the C code reads the zeros that it puts beyond them; the lowest set bit by the loop of RP_CTZL (Ratpoints.Sieve.ctz); no output under DEBUG.)

  • find_points.c:996-1000: modelled by Ratpoints.Sieve.twoAdic (deviation of Ratpoints.Sieve.twoAdic: the words returned, for the classes cls and the word den_bits that get_2adic_info fills from them in the same function, which Ratpoints.Sieve.numClasses makes from the words; the lowest set bit by the loop of RP_CTZL (Ratpoints.Sieve.ctz); remainders for the masks by 0x3f; natural numbers for the longs k, b, t and a; no output under DEBUG.)

  • find_points.c:1002-1004: modelled by Ratpoints.Sieve.coeffsMod64 (deviation of Ratpoints.Sieve.coeffsMod64: an array of D + 1 words, for the array cm on the stack; the Euclidean % of the integers, for mpz_fdiv_ui.)

  • find_points.c:1006-1014: modelled by Ratpoints.Sieve.fsq (deviation of Ratpoints.Sieve.fsq: Horner’s rule from 0, where the C code starts from cm[D], with the same value.)

  • find_points.c:1015-1021: modelled by Ratpoints.Sieve.gsq (deviation of Ratpoints.Sieve.gsq: Horner’s rule from 0, where the C code starts from cm[0], with the same value.)

  • find_points.c:1023-1050: modelled by Ratpoints.Sieve.twoAdic (deviation of Ratpoints.Sieve.twoAdic: the words returned, for the classes cls and the word den_bits that get_2adic_info fills from them in the same function, which Ratpoints.Sieve.numClasses makes from the words; the lowest set bit by the loop of RP_CTZL (Ratpoints.Sieve.ctz); remainders for the masks by 0x3f; natural numbers for the longs k, b, t and a; no output under DEBUG.)

  • find_points.c:1058-1062: modelled by Ratpoints.Sieve.classMasks (deviation of Ratpoints.Sieve.classMasks: an array of UInt64, for the array of RP_NUM_STRIDES unsigned longs, which the C code initializes with these seven words and zeros beyond them, and an array read with the default 0 beyond its seven entries.)

  • find_points.c:1064-1081: modelled by Ratpoints.Sieve.numClasses (deviation of Ratpoints.Sieve.numClasses: the classes and den_bits returned, for the array cls and the word den_bits that get_2adic_info fills through its pointer arguments, from the words that Ratpoints.Sieve.twoAdic returns; the packed pattern of a class with k ≥ 1 by a function of its own (Ratpoints.Sieve.packPattern); the pattern of a class as one word, for the vector RBA(packed) of line 1098; natural numbers for the longs k, a0 and a, and the remainder by 2 ^ k for the mask (1L << k) - 1; the mask of a stride read from the array of the masks with the default 0 beyond its seven entries, as the C code reads the zeros that it puts beyond them; the lowest set bit by the loop of RP_CTZL (Ratpoints.Sieve.ctz); no output under DEBUG.)

  • find_points.c:1082-1094: modelled by Ratpoints.Sieve.packPattern (deviation of Ratpoints.Sieve.packPattern: a function of its own for the two loops of the packed pattern, which the loop over the classes of get_2adic_info calls for k ≥ 1 (Ratpoints.Sieve.numClasses), as the loop of the binary algorithm of relprime is one (Ratpoints.Sieve.relprimeOdd); natural numbers for the longs a, a0, t and the shift a of the doubling, s here: the difference a - a₀ of natural numbers, which a ≥ a₀ makes the difference of the C code, the remainder by 64 for the mask by 0x3f, the same on a non-negative value, and the division by 2 ^ k for the shift by k; the lowest set bit by the loop of RP_CTZL (Ratpoints.Sieve.ctz).)

  • find_points.c:1095-1097: modelled by Ratpoints.Sieve.numClasses (deviation of Ratpoints.Sieve.numClasses: the classes and den_bits returned, for the array cls and the word den_bits that get_2adic_info fills through its pointer arguments, from the words that Ratpoints.Sieve.twoAdic returns; the packed pattern of a class with k ≥ 1 by a function of its own (Ratpoints.Sieve.packPattern); the pattern of a class as one word, for the vector RBA(packed) of line 1098; natural numbers for the longs k, a0 and a, and the remainder by 2 ^ k for the mask (1L << k) - 1; the mask of a stride read from the array of the masks with the default 0 beyond its seven entries, as the C code reads the zeros that it puts beyond them; the lowest set bit by the loop of RP_CTZL (Ratpoints.Sieve.ctz); no output under DEBUG.)

  • find_points.c:1098-1098: modelled by Ratpoints.Sieve.andRows, Ratpoints.Sieve.andRowsChunked (deviation of Ratpoints.Sieve.andRows: the bit arrays set to the class word by a loop that counts up, bit array n - 1 - i at the step i, for the loop that counts down from the last; the class word written into each word of a bit array, for the vector RBA(packed) that get_2adic_info makes once per class (find_points.c:1098) and _ratpoints_sift0 copies into each bit array (bits64, sift.c:519, sift.c:954); the moduli of the stage with their rows and their reciprocals as two lists, for the first sp1 sieve specs and the array magics from position 0 on; the value -w_low - offset written out in both reductions, for the long a, which stays a long where the helper mod reduces it outside small (Ratpoints.Sieve.fitsLong_neg_sub); indices for the pointers into the rows and into the survivors, and the number of whole periods and the rest computed before their loops; natural numbers and integers for the longs; a Boolean for the int small; no output under DEBUG.) (deviation of Ratpoints.Sieve.andRowsChunked: no moduli tested by the size of the local array of the sieve specs, for sp1 == 0; the bit arrays set to the class word by a loop that counts up, bit array n - 1 - i at the step i, for the loop that counts down from the last; the class word written into each word of a bit array, for the vector RBA(packed) that get_2adic_info makes once per class (find_points.c:1098) and _ratpoints_sift0 copies into each bit array (bits64, sift.c:519); the end of the whole chunks the index full, for the word number w_high_full, which is also the index of the first bit array of the tail, for the pointer surv after the chunks; natural numbers and integers for the longs.)

  • find_points.c:1099-1104: modelled by Ratpoints.Sieve.numClasses (deviation of Ratpoints.Sieve.numClasses: the classes and den_bits returned, for the array cls and the word den_bits that get_2adic_info fills through its pointer arguments, from the words that Ratpoints.Sieve.twoAdic returns; the packed pattern of a class with k ≥ 1 by a function of its own (Ratpoints.Sieve.packPattern); the pattern of a class as one word, for the vector RBA(packed) of line 1098; natural numbers for the longs k, a0 and a, and the remainder by 2 ^ k for the mask (1L << k) - 1; the mask of a stride read from the array of the masks with the default 0 beyond its seven entries, as the C code reads the zeros that it puts beyond them; the lowest set bit by the loop of RP_CTZL (Ratpoints.Sieve.ctz); no output under DEBUG.)

  • find_points.c:1106-1114: modelled by Ratpoints.Sieve.numClasses (deviation of Ratpoints.Sieve.numClasses: the classes and den_bits returned, for the array cls and the word den_bits that get_2adic_info fills through its pointer arguments, from the words that Ratpoints.Sieve.twoAdic returns; the packed pattern of a class with k ≥ 1 by a function of its own (Ratpoints.Sieve.packPattern); the pattern of a class as one word, for the vector RBA(packed) of line 1098; natural numbers for the longs k, a0 and a, and the remainder by 2 ^ k for the mask (1L << k) - 1; the mask of a stride read from the array of the masks with the default 0 beyond its seven entries, as the C code reads the zeros that it puts beyond them; the lowest set bit by the loop of RP_CTZL (Ratpoints.Sieve.ctz); no output under DEBUG.)

  • find_points.c:1115-1115: modelled by Ratpoints.Sieve.twoAdic (deviation of Ratpoints.Sieve.twoAdic: the words returned, for the classes cls and the word den_bits that get_2adic_info fills from them in the same function, which Ratpoints.Sieve.numClasses makes from the words; the lowest set bit by the loop of RP_CTZL (Ratpoints.Sieve.ctz); remainders for the masks by 0x3f; natural numbers for the longs k, b, t and a; no output under DEBUG.)

  • find_points.c:1119-1130: modelled by Ratpoints.Sieve.numPackings (deviation of Ratpoints.Sieve.numPackings: an array of two words, for the array seen of two unsigned longs; natural numbers for the longs key and n, the division by 64 and the remainder by 64 for the shift by 6 and the mask by 63 of the key; a natural number for the long result.)

  • find_points.c:1142-1158: modelled by Ratpoints.Sieve.classOffsets (deviation of Ratpoints.Sieve.classOffsets: the classes, the entries and the array of the offsets returned, for the arrays that class_offsets writes through its pointer arguments; the number np of the moduli the number of the sieve entries es, for the run all sp3_max of them (Ratpoints.sieving), with the reserve of further primes that the correction of the moduli may take into the second stage during the run (Ratpoints.Sieve.adaptPrimes); the inverses of 2 ^ k an array of kmax + 1 entries, for the array dinv of RP_NUM_STRIDES longs of the sieve entry, whose entries beyond kmax stay unset and unread; the inverses rinv an array of arrays, for the array on the stack; the loop over the classes by a function of its own (Ratpoints.Sieve.classRows); natural numbers for the longs.)

  • find_points.c:1159-1160: modelled by Ratpoints.Sieve.halve (deviation of Ratpoints.Sieve.halve: a function of its own for the expression that the C code writes out for d and for e; the remainder by 2 for the mask & 1 and the division by 2 for the shift >> 1; natural numbers for the longs.)

  • find_points.c:1161-1162: modelled by Ratpoints.Sieve.classOffsets (deviation of Ratpoints.Sieve.classOffsets: the classes, the entries and the array of the offsets returned, for the arrays that class_offsets writes through its pointer arguments; the number np of the moduli the number of the sieve entries es, for the run all sp3_max of them (Ratpoints.sieving), with the reserve of further primes that the correction of the moduli may take into the second stage during the run (Ratpoints.Sieve.adaptPrimes); the inverses of 2 ^ k an array of kmax + 1 entries, for the array dinv of RP_NUM_STRIDES longs of the sieve entry, whose entries beyond kmax stay unset and unread; the inverses rinv an array of arrays, for the array on the stack; the loop over the classes by a function of its own (Ratpoints.Sieve.classRows); natural numbers for the longs.)

  • find_points.c:1164-1182: modelled by Ratpoints.Sieve.classRows (deviation of Ratpoints.Sieve.classRows: a function of its own for the loop over the classes of class_offsets (Ratpoints.Sieve.classOffsets); the classes and the array of the offsets returned, for the array of the classes and the array of the offsets that class_offsets writes through its pointer arguments; the table of the rows by their keys an array of options of positions, for the array row_of of 2 ^ RP_NUM_STRIDES pointers into the offsets, none for NULL, and the row of a class its position in the array of the offsets, for the pointer row; the inverses rinv an array of arrays, for the array of RP_NUM_STRIDES longs for each modulus on the stack; natural numbers for the longs, the product a₀ rinv[n][k] a natural number for the long that RP_MULMOD converts to an unsigned long, below 2 ^ 63 (Ratpoints.mul_lt_two_pow_63); the reciprocal and the bias read from the sieve entry, as the C code reads them.)

  • find_points.c:1183-1183: modelled by Ratpoints.Sieve.classOffsets (deviation of Ratpoints.Sieve.classOffsets: the classes, the entries and the array of the offsets returned, for the arrays that class_offsets writes through its pointer arguments; the number np of the moduli the number of the sieve entries es, for the run all sp3_max of them (Ratpoints.sieving), with the reserve of further primes that the correction of the moduli may take into the second stage during the run (Ratpoints.Sieve.adaptPrimes); the inverses of 2 ^ k an array of kmax + 1 entries, for the array dinv of RP_NUM_STRIDES longs of the sieve entry, whose entries beyond kmax stay unset and unread; the inverses rinv an array of arrays, for the array on the stack; the loop over the classes by a function of its own (Ratpoints.Sieve.classRows); natural numbers for the longs.)

  • find_points.c:1194-1198: modelled by Ratpoints.ModulusCandidate.keyLe (deviation of Ratpoints.ModulusCandidate.keyLe: the test of the merge sort, whether the comparison is at most 0, for the comparison of the C code, which returns 1, -1 or 0.)

  • find_points.c:1202-1206: modelled by Ratpoints.ModulusCandidate.rLe (deviation of Ratpoints.ModulusCandidate.rLe: the test of the merge sort, whether the comparison is at most 0, for the comparison of the C code, which returns 1, -1 or 0.)

  • find_points.c:1220-1235: modelled by Ratpoints.primeCost

  • find_points.c:1241-1247: modelled by Ratpoints.primeKey (deviation of Ratpoints.primeKey: log the function of the C library of the platform that the Lean runtime binds (Float.log), on glibc an older symbol version of the routine that ratpoints binds, which gives the same values on every argument that occurs here, and which glibc does not round correctly and chooses by the processor, so that the value is that of the C program on the same machine.)

  • find_points.c:1256-1270: modelled by Ratpoints.phase1Key (deviation of Ratpoints.phase1Key: log the function of the C library of the platform that the Lean runtime binds (Float.log), on glibc an older symbol version of the routine that ratpoints binds, which gives the same values on every argument that occurs here, and which glibc does not round correctly and chooses by the processor, so that the value is that of the C program on the same machine; the candidate returned with its key and cost, for the fields of the record that phase_1_key sets; Ratpoints.rbaPack for RBA_PACK and 8 Ratpoints.rbaPack for the size of a bit array in bytes.)

  • find_points.c:1285-1318: modelled by Ratpoints.checkCost (deviation of Ratpoints.checkCost: the coefficients, the degree and the height bound as arguments, for the fields of the arguments that check_cost reads; log the function of the C library of the platform that the Lean runtime binds (Float.log), on glibc an older symbol version of the routine that ratpoints binds, which gives the same values on every argument that occurs here, and which glibc does not round correctly and chooses by the processor, so that the value is that of the C program on the same machine; log 2 computed at run time, where gcc folds log(2.0) into the same double; ceil the function of the C library of the platform (Float.ceil), which is exact, where gcc compiles an instruction; the bit length of |c_k| (Nat.log2 + 1) for mpz_sizeinbase(c_k, 2), which it is for c_k ≠ 0; 64 for LONG_LENGTH.)

  • find_points.c:1354-1354: modelled by Ratpoints.adaptWords

  • find_points.c:1355-1355: modelled by Ratpoints.adaptArrays

  • find_points.c:1356-1356: modelled by Ratpoints.adaptBits

  • find_points.c:1363-1367: modelled by Ratpoints.Sieve.RunCounts (deviation of Ratpoints.Sieve.RunCounts: the six counters of the sieving thread extended (Ratpoints.Sieve.Counters), for the six fields; a UInt64 for the unsigned long n_words_2 and a natural number for the long sp2.)

  • find_points.c:1379-1381: modelled by Ratpoints.adaptLag

  • find_points.c:1383-1388: modelled by Ratpoints.Sieve.adaptPrimes (deviation of Ratpoints.Sieve.adaptPrimes: the fields of the arguments that adapt_primes reads passed as the options, the result of the choice and the entries, and those that it writes, sp2, sp3 and adapt_at, returned; the doubles of the options by their bits; Floats for the doubles, in the order of the C code; integers for the longs adapt and sp3_extra and natural numbers for the others; no output under RP_PRIME_STATS.)

  • find_points.c:1389-1389: modelled by Ratpoints.Sieve.adaptRates (deviation of Ratpoints.Sieve.adaptRates: a function of its own for this part of adapt_primes, its returns the result none; Floats for the doubles, in the order of the C code, the conversions of the UInt64 counters to Float as the C code converts the unsigned longs to doubles, and the words since the restart the difference of the UInt64s, wrapping, converted, as the C code computes it; the densities read from the entries, for sieve_list[n]->r; natural numbers for the longs, so that sp1 ≤ 0 is sp1 = 0.)

  • find_points.c:1390-1398: modelled by Ratpoints.Sieve.adaptPrimes (deviation of Ratpoints.Sieve.adaptPrimes: the fields of the arguments that adapt_primes reads passed as the options, the result of the choice and the entries, and those that it writes, sp2, sp3 and adapt_at, returned; the doubles of the options by their bits; Floats for the doubles, in the order of the C code; integers for the longs adapt and sp3_extra and natural numbers for the others; no output under RP_PRIME_STATS.)

  • find_points.c:1400-1420: modelled by Ratpoints.Sieve.adaptRates (deviation of Ratpoints.Sieve.adaptRates: a function of its own for this part of adapt_primes, its returns the result none; Floats for the doubles, in the order of the C code, the conversions of the UInt64 counters to Float as the C code converts the unsigned longs to doubles, and the words since the restart the difference of the UInt64s, wrapping, converted, as the C code computes it; the densities read from the entries, for sieve_list[n]->r; natural numbers for the longs, so that sp1 ≤ 0 is sp1 = 0.)

  • find_points.c:1421-1438: modelled by Ratpoints.Sieve.adaptPrimes (deviation of Ratpoints.Sieve.adaptPrimes: the fields of the arguments that adapt_primes reads passed as the options, the result of the choice and the entries, and those that it writes, sp2, sp3 and adapt_at, returned; the doubles of the options by their bits; Floats for the doubles, in the order of the C code; integers for the longs adapt and sp3_extra and natural numbers for the others; no output under RP_PRIME_STATS.)

  • find_points.c:1439-1448: modelled by Ratpoints.Sieve.adaptSecond (deviation of Ratpoints.Sieve.adaptSecond: a function of its own for this part of adapt_primes; Floats for the doubles, in the order of the C code; natural numbers for the longs.)

  • find_points.c:1449-1457: modelled by Ratpoints.Sieve.adaptUp (deviation of Ratpoints.Sieve.adaptUp: a function of its own for this loop of adapt_primes; the entries an array, for sieve_list up to sp3_max, its size; Floats for the doubles, in the order of the C code; natural numbers for the longs.)

  • find_points.c:1458-1459: modelled by Ratpoints.Sieve.adaptSecond (deviation of Ratpoints.Sieve.adaptSecond: a function of its own for this part of adapt_primes; Floats for the doubles, in the order of the C code; natural numbers for the longs.)

  • find_points.c:1460-1472: modelled by Ratpoints.Sieve.adaptDown (deviation of Ratpoints.Sieve.adaptDown: a function of its own for this loop of adapt_primes; the entries an array, for sieve_list; Floats for the doubles, in the order of the C code; natural numbers for the longs, n stepping down from sp2 - 1 while it is above sp1.)

  • find_points.c:1473-1476: modelled by Ratpoints.Sieve.adaptSecond (deviation of Ratpoints.Sieve.adaptSecond: a function of its own for this part of adapt_primes; Floats for the doubles, in the order of the C code; natural numbers for the longs.)

  • find_points.c:1477-1486: modelled by Ratpoints.Sieve.adaptPrimes (deviation of Ratpoints.Sieve.adaptPrimes: the fields of the arguments that adapt_primes reads passed as the options, the result of the choice and the entries, and those that it writes, sp2, sp3 and adapt_at, returned; the doubles of the options by their bits; Floats for the doubles, in the order of the C code; integers for the longs adapt and sp3_extra and natural numbers for the others; no output under RP_PRIME_STATS.)

  • find_points.c:1487-1505: modelled by Ratpoints.Sieve.adaptThird (deviation of Ratpoints.Sieve.adaptThird: a function of its own for this part of adapt_primes, the fields sp3_per_denom (its double read by its bits by the caller) and check_rel of the arguments that it reads and the local variables level, chance, r2 and s of adapt_primes passed as arguments; the end of the third stage returned, for the field sp3 of the arguments that it writes; Floats for the doubles, in the order of the C code; natural numbers for the longs.)

  • find_points.c:1506-1509: modelled by Ratpoints.Sieve.adaptPrimes (deviation of Ratpoints.Sieve.adaptPrimes: the fields of the arguments that adapt_primes reads passed as the options, the result of the choice and the entries, and those that it writes, sp2, sp3 and adapt_at, returned; the doubles of the options by their bits; Floats for the doubles, in the order of the C code; integers for the longs adapt and sp3_extra and natural numbers for the others; no output under RP_PRIME_STATS.)

  • find_points.c:1510-1514: excluded (instrumentation): RP_PRIME_STATS in adapt_primes, a development probe that prints each correction of the moduli on stderr

  • find_points.c:1515-1515: modelled by Ratpoints.Sieve.adaptPrimes (deviation of Ratpoints.Sieve.adaptPrimes: the fields of the arguments that adapt_primes reads passed as the options, the result of the choice and the entries, and those that it writes, sp2, sp3 and adapt_at, returned; the doubles of the options by their bits; Floats for the doubles, in the order of the C code; integers for the longs adapt and sp3_extra and natural numbers for the others; no output under RP_PRIME_STATS.)

  • find_points.c:1539-1561: modelled by Ratpoints.downstreamFactor (deviation of Ratpoints.downstreamFactor: pow the function of the C library of the platform that the Lean runtime binds (Float.pow), on glibc an older symbol version of the routine that ratpoints binds, which gives the same values on every argument that occurs here, and which glibc does not round correctly and chooses by the processor, so that the value is that of the C program on the same machine; natural numbers for the long positions, the comparisons with the candidates left after n made on integers.)

  • find_points.c:1583-1589: modelled by Ratpoints.phase1Wants

  • find_points.c:1598-1609: modelled by Ratpoints.primesForPhase1

  • find_points.c:1619-1626: modelled by Ratpoints.phase2Offset (deviation of Ratpoints.phase2Offset: natural numbers for the longs, which are not negative here; the conversion of e + 0.5 to a long, which truncates, by Float.toUInt64, which truncates e + 0.5 < most as well.)

  • find_points.c:1639-1650: modelled by Ratpoints.Sieve.barrett (deviation of Ratpoints.Sieve.barrett: natural numbers for the unsigned longs, the product u m exact as the 128-bit product of the C code, and the difference exact, which does not wrap since the quotient times p is at most u for m ≤ (2 ^ 64 - 1) / p; the obligation that u is below 2 ^ 64, which the C type gives, a hypothesis of the lemma that the result is u % p (Ratpoints.Sieve.barrett_eq); the form with the 128-bit product, which the modelled builds compile (the compiler defines __SIZEOF_INT128__, and RP_NO_INT128 is not set), for the division u % p of the other builds, which gives the same remainder.)

  • find_points.c:1652-1655: modelled by Ratpoints.hornerSteps (deviation of Ratpoints.hornerSteps: computed from Ratpoints.maxBitsInPrime as the macro computes it from RATPOINTS_MAX_BITS_IN_PRIME, with 64 for LONG_LENGTH.)

  • find_points.c:1683-1697: modelled by Ratpoints.Sieve.examinePrime? (deviation of Ratpoints.Sieve.examinePrime?: the prime p itself, for its index pn in the table prime; the table a fresh array of p + 1 entries, for the integers that examine_prime takes from the buffer int_next and hands back through is_f_square_p, and the coefficients a fresh array returned with the entry, for the array coeffs_mod_p of its caller, which it fills; one loop over the residues, for the two loops of the two branches of the schedule of Horner’s rule, between which Ratpoints.Sieve.hornerBarrett chooses for each residue; the exit -1 as none, and the codes 0, 1 and 2 returned with the entry, the coefficients and the density, as natural numbers, the entry made and returned for the code 0 too, where examine_prime makes none, and the density 0.0 for that code, which examine_prime does not compute; the fields p, mask and nf of the record prec_entry of the ranking, which examine_prime sets with the density (lines 1782-1785), made by the caller from the table, the position of the prime and the code (Ratpoints.ModulusCandidate.ofPrime); the entry is a fresh value, for the space that examine_prime takes from the buffer of the sieve entries (se_next), and returned, where examine_prime stores it in the field ssp of prec_entry; it keeps only p, the table and the inverses (Ratpoints.Sieve.Entry), and no rows: the table of rows of the prime, with the row of 0 from the build and the others absent (lines 1820-1821, Ratpoints.Sieve.primeRows), is made in the store of the run by the loop of the tables when the prime says something (Ratpoints.examineInLoop), and for a prime that the third stage takes into the pool by the end of the choice (Ratpoints.choiceEnd, with Ratpoints.Sieve.SieveEntry.addTables); the fields init, nf and pw that examine_prime sets (lines 1800 and 1817) and its reciprocal magic (line 1808) are those of the sieve entry of the prime (Ratpoints.Sieve.SieveEntry), of which the prime is the single factor, made by the entries that the choice of the moduli makes (Ratpoints.primeEntry), which set the reciprocal there, and so are the bias bias, the inverse rbainv of Ratpoints.rbaLength, the density and the count of factors (lines 1811 and 1815-1817), which they set there with the formulas of these lines.)

  • find_points.c:1698-1701: excluded (instrumentation): the message under DEBUG at the start of examine_prime

  • find_points.c:1703-1723: modelled by Ratpoints.Sieve.examinePrime? (deviation of Ratpoints.Sieve.examinePrime?: the prime p itself, for its index pn in the table prime; the table a fresh array of p + 1 entries, for the integers that examine_prime takes from the buffer int_next and hands back through is_f_square_p, and the coefficients a fresh array returned with the entry, for the array coeffs_mod_p of its caller, which it fills; one loop over the residues, for the two loops of the two branches of the schedule of Horner’s rule, between which Ratpoints.Sieve.hornerBarrett chooses for each residue; the exit -1 as none, and the codes 0, 1 and 2 returned with the entry, the coefficients and the density, as natural numbers, the entry made and returned for the code 0 too, where examine_prime makes none, and the density 0.0 for that code, which examine_prime does not compute; the fields p, mask and nf of the record prec_entry of the ranking, which examine_prime sets with the density (lines 1782-1785), made by the caller from the table, the position of the prime and the code (Ratpoints.ModulusCandidate.ofPrime); the entry is a fresh value, for the space that examine_prime takes from the buffer of the sieve entries (se_next), and returned, where examine_prime stores it in the field ssp of prec_entry; it keeps only p, the table and the inverses (Ratpoints.Sieve.Entry), and no rows: the table of rows of the prime, with the row of 0 from the build and the others absent (lines 1820-1821, Ratpoints.Sieve.primeRows), is made in the store of the run by the loop of the tables when the prime says something (Ratpoints.examineInLoop), and for a prime that the third stage takes into the pool by the end of the choice (Ratpoints.choiceEnd, with Ratpoints.Sieve.SieveEntry.addTables); the fields init, nf and pw that examine_prime sets (lines 1800 and 1817) and its reciprocal magic (line 1808) are those of the sieve entry of the prime (Ratpoints.Sieve.SieveEntry), of which the prime is the single factor, made by the entries that the choice of the moduli makes (Ratpoints.primeEntry), which set the reciprocal there, and so are the bias bias, the inverse rbainv of Ratpoints.rbaLength, the density and the count of factors (lines 1811 and 1815-1817), which they set there with the formulas of these lines.)

  • find_points.c:1724-1724: modelled by Ratpoints.Sieve.hornerBarrett (deviation of Ratpoints.Sieve.hornerBarrett: the choice between the two branches made for each residue, where examine_prime makes it once, around its loop over the residues; natural numbers for the unsigned long accumulator, with the obligation that it stays below 2 ^ 64 stated as a lemma (Ratpoints.Sieve.HornerInvariant.lt_two_pow_64); the steps counted up from 0 to d - 1, for the index n that counts down.)

  • find_points.c:1725-1725: modelled by Ratpoints.Sieve.examinePrime? (deviation of Ratpoints.Sieve.examinePrime?: the prime p itself, for its index pn in the table prime; the table a fresh array of p + 1 entries, for the integers that examine_prime takes from the buffer int_next and hands back through is_f_square_p, and the coefficients a fresh array returned with the entry, for the array coeffs_mod_p of its caller, which it fills; one loop over the residues, for the two loops of the two branches of the schedule of Horner’s rule, between which Ratpoints.Sieve.hornerBarrett chooses for each residue; the exit -1 as none, and the codes 0, 1 and 2 returned with the entry, the coefficients and the density, as natural numbers, the entry made and returned for the code 0 too, where examine_prime makes none, and the density 0.0 for that code, which examine_prime does not compute; the fields p, mask and nf of the record prec_entry of the ranking, which examine_prime sets with the density (lines 1782-1785), made by the caller from the table, the position of the prime and the code (Ratpoints.ModulusCandidate.ofPrime); the entry is a fresh value, for the space that examine_prime takes from the buffer of the sieve entries (se_next), and returned, where examine_prime stores it in the field ssp of prec_entry; it keeps only p, the table and the inverses (Ratpoints.Sieve.Entry), and no rows: the table of rows of the prime, with the row of 0 from the build and the others absent (lines 1820-1821, Ratpoints.Sieve.primeRows), is made in the store of the run by the loop of the tables when the prime says something (Ratpoints.examineInLoop), and for a prime that the third stage takes into the pool by the end of the choice (Ratpoints.choiceEnd, with Ratpoints.Sieve.SieveEntry.addTables); the fields init, nf and pw that examine_prime sets (lines 1800 and 1817) and its reciprocal magic (line 1808) are those of the sieve entry of the prime (Ratpoints.Sieve.SieveEntry), of which the prime is the single factor, made by the entries that the choice of the moduli makes (Ratpoints.primeEntry), which set the reciprocal there, and so are the bias bias, the inverse rbainv of Ratpoints.rbaLength, the density and the count of factors (lines 1811 and 1815-1817), which they set there with the formulas of these lines.)

  • find_points.c:1726-1731: modelled by Ratpoints.Sieve.hornerBarrett (deviation of Ratpoints.Sieve.hornerBarrett: the choice between the two branches made for each residue, where examine_prime makes it once, around its loop over the residues; natural numbers for the unsigned long accumulator, with the obligation that it stays below 2 ^ 64 stated as a lemma (Ratpoints.Sieve.HornerInvariant.lt_two_pow_64); the steps counted up from 0 to d - 1, for the index n that counts down.)

  • find_points.c:1732-1734: modelled by Ratpoints.Sieve.examinePrime? (deviation of Ratpoints.Sieve.examinePrime?: the prime p itself, for its index pn in the table prime; the table a fresh array of p + 1 entries, for the integers that examine_prime takes from the buffer int_next and hands back through is_f_square_p, and the coefficients a fresh array returned with the entry, for the array coeffs_mod_p of its caller, which it fills; one loop over the residues, for the two loops of the two branches of the schedule of Horner’s rule, between which Ratpoints.Sieve.hornerBarrett chooses for each residue; the exit -1 as none, and the codes 0, 1 and 2 returned with the entry, the coefficients and the density, as natural numbers, the entry made and returned for the code 0 too, where examine_prime makes none, and the density 0.0 for that code, which examine_prime does not compute; the fields p, mask and nf of the record prec_entry of the ranking, which examine_prime sets with the density (lines 1782-1785), made by the caller from the table, the position of the prime and the code (Ratpoints.ModulusCandidate.ofPrime); the entry is a fresh value, for the space that examine_prime takes from the buffer of the sieve entries (se_next), and returned, where examine_prime stores it in the field ssp of prec_entry; it keeps only p, the table and the inverses (Ratpoints.Sieve.Entry), and no rows: the table of rows of the prime, with the row of 0 from the build and the others absent (lines 1820-1821, Ratpoints.Sieve.primeRows), is made in the store of the run by the loop of the tables when the prime says something (Ratpoints.examineInLoop), and for a prime that the third stage takes into the pool by the end of the choice (Ratpoints.choiceEnd, with Ratpoints.Sieve.SieveEntry.addTables); the fields init, nf and pw that examine_prime sets (lines 1800 and 1817) and its reciprocal magic (line 1808) are those of the sieve entry of the prime (Ratpoints.Sieve.SieveEntry), of which the prime is the single factor, made by the entries that the choice of the moduli makes (Ratpoints.primeEntry), which set the reciprocal there, and so are the bias bias, the inverse rbainv of Ratpoints.rbaLength, the density and the count of factors (lines 1811 and 1815-1817), which they set there with the formulas of these lines.)

  • find_points.c:1735-1735: modelled by Ratpoints.Sieve.hornerBarrett (deviation of Ratpoints.Sieve.hornerBarrett: the choice between the two branches made for each residue, where examine_prime makes it once, around its loop over the residues; natural numbers for the unsigned long accumulator, with the obligation that it stays below 2 ^ 64 stated as a lemma (Ratpoints.Sieve.HornerInvariant.lt_two_pow_64); the steps counted up from 0 to d - 1, for the index n that counts down.)

  • find_points.c:1736-1736: modelled by Ratpoints.Sieve.examinePrime? (deviation of Ratpoints.Sieve.examinePrime?: the prime p itself, for its index pn in the table prime; the table a fresh array of p + 1 entries, for the integers that examine_prime takes from the buffer int_next and hands back through is_f_square_p, and the coefficients a fresh array returned with the entry, for the array coeffs_mod_p of its caller, which it fills; one loop over the residues, for the two loops of the two branches of the schedule of Horner’s rule, between which Ratpoints.Sieve.hornerBarrett chooses for each residue; the exit -1 as none, and the codes 0, 1 and 2 returned with the entry, the coefficients and the density, as natural numbers, the entry made and returned for the code 0 too, where examine_prime makes none, and the density 0.0 for that code, which examine_prime does not compute; the fields p, mask and nf of the record prec_entry of the ranking, which examine_prime sets with the density (lines 1782-1785), made by the caller from the table, the position of the prime and the code (Ratpoints.ModulusCandidate.ofPrime); the entry is a fresh value, for the space that examine_prime takes from the buffer of the sieve entries (se_next), and returned, where examine_prime stores it in the field ssp of prec_entry; it keeps only p, the table and the inverses (Ratpoints.Sieve.Entry), and no rows: the table of rows of the prime, with the row of 0 from the build and the others absent (lines 1820-1821, Ratpoints.Sieve.primeRows), is made in the store of the run by the loop of the tables when the prime says something (Ratpoints.examineInLoop), and for a prime that the third stage takes into the pool by the end of the choice (Ratpoints.choiceEnd, with Ratpoints.Sieve.SieveEntry.addTables); the fields init, nf and pw that examine_prime sets (lines 1800 and 1817) and its reciprocal magic (line 1808) are those of the sieve entry of the prime (Ratpoints.Sieve.SieveEntry), of which the prime is the single factor, made by the entries that the choice of the moduli makes (Ratpoints.primeEntry), which set the reciprocal there, and so are the bias bias, the inverse rbainv of Ratpoints.rbaLength, the density and the count of factors (lines 1811 and 1815-1817), which they set there with the formulas of these lines.)

  • find_points.c:1737-1744: modelled by Ratpoints.Sieve.hornerBarrett (deviation of Ratpoints.Sieve.hornerBarrett: the choice between the two branches made for each residue, where examine_prime makes it once, around its loop over the residues; natural numbers for the unsigned long accumulator, with the obligation that it stays below 2 ^ 64 stated as a lemma (Ratpoints.Sieve.HornerInvariant.lt_two_pow_64); the steps counted up from 0 to d - 1, for the index n that counts down.)

  • find_points.c:1745-1749: modelled by Ratpoints.Sieve.examinePrime? (deviation of Ratpoints.Sieve.examinePrime?: the prime p itself, for its index pn in the table prime; the table a fresh array of p + 1 entries, for the integers that examine_prime takes from the buffer int_next and hands back through is_f_square_p, and the coefficients a fresh array returned with the entry, for the array coeffs_mod_p of its caller, which it fills; one loop over the residues, for the two loops of the two branches of the schedule of Horner’s rule, between which Ratpoints.Sieve.hornerBarrett chooses for each residue; the exit -1 as none, and the codes 0, 1 and 2 returned with the entry, the coefficients and the density, as natural numbers, the entry made and returned for the code 0 too, where examine_prime makes none, and the density 0.0 for that code, which examine_prime does not compute; the fields p, mask and nf of the record prec_entry of the ranking, which examine_prime sets with the density (lines 1782-1785), made by the caller from the table, the position of the prime and the code (Ratpoints.ModulusCandidate.ofPrime); the entry is a fresh value, for the space that examine_prime takes from the buffer of the sieve entries (se_next), and returned, where examine_prime stores it in the field ssp of prec_entry; it keeps only p, the table and the inverses (Ratpoints.Sieve.Entry), and no rows: the table of rows of the prime, with the row of 0 from the build and the others absent (lines 1820-1821, Ratpoints.Sieve.primeRows), is made in the store of the run by the loop of the tables when the prime says something (Ratpoints.examineInLoop), and for a prime that the third stage takes into the pool by the end of the choice (Ratpoints.choiceEnd, with Ratpoints.Sieve.SieveEntry.addTables); the fields init, nf and pw that examine_prime sets (lines 1800 and 1817) and its reciprocal magic (line 1808) are those of the sieve entry of the prime (Ratpoints.Sieve.SieveEntry), of which the prime is the single factor, made by the entries that the choice of the moduli makes (Ratpoints.primeEntry), which set the reciprocal there, and so are the bias bias, the inverse rbainv of Ratpoints.rbaLength, the density and the count of factors (lines 1811 and 1815-1817), which they set there with the formulas of these lines.)

  • find_points.c:1751-1759: excluded (instrumentation): the table of examine_prime with its last entry, printed under DEBUG

  • find_points.c:1761-1781: modelled by Ratpoints.Sieve.examinePrime? (deviation of Ratpoints.Sieve.examinePrime?: the prime p itself, for its index pn in the table prime; the table a fresh array of p + 1 entries, for the integers that examine_prime takes from the buffer int_next and hands back through is_f_square_p, and the coefficients a fresh array returned with the entry, for the array coeffs_mod_p of its caller, which it fills; one loop over the residues, for the two loops of the two branches of the schedule of Horner’s rule, between which Ratpoints.Sieve.hornerBarrett chooses for each residue; the exit -1 as none, and the codes 0, 1 and 2 returned with the entry, the coefficients and the density, as natural numbers, the entry made and returned for the code 0 too, where examine_prime makes none, and the density 0.0 for that code, which examine_prime does not compute; the fields p, mask and nf of the record prec_entry of the ranking, which examine_prime sets with the density (lines 1782-1785), made by the caller from the table, the position of the prime and the code (Ratpoints.ModulusCandidate.ofPrime); the entry is a fresh value, for the space that examine_prime takes from the buffer of the sieve entries (se_next), and returned, where examine_prime stores it in the field ssp of prec_entry; it keeps only p, the table and the inverses (Ratpoints.Sieve.Entry), and no rows: the table of rows of the prime, with the row of 0 from the build and the others absent (lines 1820-1821, Ratpoints.Sieve.primeRows), is made in the store of the run by the loop of the tables when the prime says something (Ratpoints.examineInLoop), and for a prime that the third stage takes into the pool by the end of the choice (Ratpoints.choiceEnd, with Ratpoints.Sieve.SieveEntry.addTables); the fields init, nf and pw that examine_prime sets (lines 1800 and 1817) and its reciprocal magic (line 1808) are those of the sieve entry of the prime (Ratpoints.Sieve.SieveEntry), of which the prime is the single factor, made by the entries that the choice of the moduli makes (Ratpoints.primeEntry), which set the reciprocal there, and so are the bias bias, the inverse rbainv of Ratpoints.rbaLength, the density and the count of factors (lines 1811 and 1815-1817), which they set there with the formulas of these lines.)

  • find_points.c:1782-1785: modelled by Ratpoints.ModulusCandidate.ofPrime (deviation of Ratpoints.ModulusCandidate.ofPrime: the record returned, for the record prec_entry that examine_prime fills, its key and cost 0.0 until the caller sets them, where the C code leaves them as they are; the count -1 read from the code, which is 2 exactly when np ≥ p.)

  • find_points.c:1795-1819: modelled by Ratpoints.Sieve.examinePrime? (deviation of Ratpoints.Sieve.examinePrime?: the prime p itself, for its index pn in the table prime; the table a fresh array of p + 1 entries, for the integers that examine_prime takes from the buffer int_next and hands back through is_f_square_p, and the coefficients a fresh array returned with the entry, for the array coeffs_mod_p of its caller, which it fills; one loop over the residues, for the two loops of the two branches of the schedule of Horner’s rule, between which Ratpoints.Sieve.hornerBarrett chooses for each residue; the exit -1 as none, and the codes 0, 1 and 2 returned with the entry, the coefficients and the density, as natural numbers, the entry made and returned for the code 0 too, where examine_prime makes none, and the density 0.0 for that code, which examine_prime does not compute; the fields p, mask and nf of the record prec_entry of the ranking, which examine_prime sets with the density (lines 1782-1785), made by the caller from the table, the position of the prime and the code (Ratpoints.ModulusCandidate.ofPrime); the entry is a fresh value, for the space that examine_prime takes from the buffer of the sieve entries (se_next), and returned, where examine_prime stores it in the field ssp of prec_entry; it keeps only p, the table and the inverses (Ratpoints.Sieve.Entry), and no rows: the table of rows of the prime, with the row of 0 from the build and the others absent (lines 1820-1821, Ratpoints.Sieve.primeRows), is made in the store of the run by the loop of the tables when the prime says something (Ratpoints.examineInLoop), and for a prime that the third stage takes into the pool by the end of the choice (Ratpoints.choiceEnd, with Ratpoints.Sieve.SieveEntry.addTables); the fields init, nf and pw that examine_prime sets (lines 1800 and 1817) and its reciprocal magic (line 1808) are those of the sieve entry of the prime (Ratpoints.Sieve.SieveEntry), of which the prime is the single factor, made by the entries that the choice of the moduli makes (Ratpoints.primeEntry), which set the reciprocal there, and so are the bias bias, the inverse rbainv of Ratpoints.rbaLength, the density and the count of factors (lines 1811 and 1815-1817), which they set there with the formulas of these lines.)

  • find_points.c:1820-1821: modelled by Ratpoints.Sieve.primeRows (deviation of Ratpoints.Sieve.primeRows: the table returned, for the array sieve of the entry, which examine_prime fills; the row of 0 the words of the pattern, for the pointer to them.)

  • find_points.c:1822-1826: modelled by Ratpoints.Sieve.examinePrime? (deviation of Ratpoints.Sieve.examinePrime?: the prime p itself, for its index pn in the table prime; the table a fresh array of p + 1 entries, for the integers that examine_prime takes from the buffer int_next and hands back through is_f_square_p, and the coefficients a fresh array returned with the entry, for the array coeffs_mod_p of its caller, which it fills; one loop over the residues, for the two loops of the two branches of the schedule of Horner’s rule, between which Ratpoints.Sieve.hornerBarrett chooses for each residue; the exit -1 as none, and the codes 0, 1 and 2 returned with the entry, the coefficients and the density, as natural numbers, the entry made and returned for the code 0 too, where examine_prime makes none, and the density 0.0 for that code, which examine_prime does not compute; the fields p, mask and nf of the record prec_entry of the ranking, which examine_prime sets with the density (lines 1782-1785), made by the caller from the table, the position of the prime and the code (Ratpoints.ModulusCandidate.ofPrime); the entry is a fresh value, for the space that examine_prime takes from the buffer of the sieve entries (se_next), and returned, where examine_prime stores it in the field ssp of prec_entry; it keeps only p, the table and the inverses (Ratpoints.Sieve.Entry), and no rows: the table of rows of the prime, with the row of 0 from the build and the others absent (lines 1820-1821, Ratpoints.Sieve.primeRows), is made in the store of the run by the loop of the tables when the prime says something (Ratpoints.examineInLoop), and for a prime that the third stage takes into the pool by the end of the choice (Ratpoints.choiceEnd, with Ratpoints.Sieve.SieveEntry.addTables); the fields init, nf and pw that examine_prime sets (lines 1800 and 1817) and its reciprocal magic (line 1808) are those of the sieve entry of the prime (Ratpoints.Sieve.SieveEntry), of which the prime is the single factor, made by the entries that the choice of the moduli makes (Ratpoints.primeEntry), which set the reciprocal there, and so are the bias bias, the inverse rbainv of Ratpoints.rbaLength, the density and the count of factors (lines 1811 and 1815-1817), which they set there with the formulas of these lines.)

  • find_points.c:1836-1854: modelled by Ratpoints.numeratorsFor (deviation of Ratpoints.numeratorsFor: the search intervals as an argument, for the fields domain and num_inter of the arguments, their ends doubles by their bits (Ratpoints.Double.toFloat); the sum and the three counts returned, the counts as doubles, as the C code hands them back through its pointers.)

  • find_points.c:1863-1876: modelled by Ratpoints.clippedPadding (deviation of Ratpoints.clippedPadding: the two sums passed and returned, for the pointers; integers for the longs, the arithmetic shifts as divisions that round down and the masks by RBA_LENGTH - 1 as Euclidean remainders.)

  • find_points.c:1917-1917: modelled by Ratpoints.runShapeSamples

  • find_points.c:1921-1922: modelled by Ratpoints.invStride (deviation of Ratpoints.invStride: an array of the seven doubles of the table, which rp_inv_stride sizes by RP_NUM_STRIDES, read by getD with 0.0, the value of the entries beyond the seven initializers when RP_NUM_STRIDES is larger; the stride of a class is at most 2 ^ 6.)

  • find_points.c:1926-1937: modelled by Ratpoints.forbiddenFraction (deviation of Ratpoints.forbiddenFraction: natural numbers for the long and the unsigned long mask; 64 for LONG_LENGTH.)

  • find_points.c:1939-1944: modelled by Ratpoints.runShape (deviation of Ratpoints.runShape: the switch checkDenom for the bit RATPOINTS_CHECK_DENOM of the flags, and the forbidden divisors as lists, for the arrays with their counts fba and fdc.)

  • find_points.c:1945-1957: modelled by Ratpoints.ShapeAcc (deviation of Ratpoints.ShapeAcc: a structure for the local variables, with their initial values.)

  • find_points.c:1959-1959: modelled by Ratpoints.runShape (deviation of Ratpoints.runShape: the switch checkDenom for the bit RATPOINTS_CHECK_DENOM of the flags, and the forbidden divisors as lists, for the arrays with their counts fba and fdc.)

  • find_points.c:1960-1962: modelled by Ratpoints.shapeSquares (deviation of Ratpoints.shapeSquares: ceil and floor the functions of the C library of the platform (Float.ceil, Float.floor), which are exact, where gcc compiles instructions.)

  • find_points.c:1964-1973: modelled by Ratpoints.sampleSteps (deviation of Ratpoints.sampleSteps: one function for the samples of the squares and of every denominator, which the C code writes out twice.)

  • find_points.c:1976-1979: modelled by Ratpoints.shapeSquares (deviation of Ratpoints.shapeSquares: ceil and floor the functions of the C library of the platform (Float.ceil, Float.floor), which are exact, where gcc compiles instructions.)

  • find_points.c:1980-1981: modelled by Ratpoints.addClass (deviation of Ratpoints.addClass: one function for the three places of the C code.)

  • find_points.c:1982-1985: modelled by Ratpoints.shapeSquares (deviation of Ratpoints.shapeSquares: ceil and floor the functions of the C library of the platform (Float.ceil, Float.floor), which are exact, where gcc compiles instructions.)

  • find_points.c:1986-1986: modelled by Ratpoints.runShape (deviation of Ratpoints.runShape: the switch checkDenom for the bit RATPOINTS_CHECK_DENOM of the flags, and the forbidden divisors as lists, for the arrays with their counts fba and fdc.)

  • find_points.c:1987-1992: modelled by Ratpoints.shapeSquares1 (deviation of Ratpoints.shapeSquares1: the divisors as a list, for the zero-terminated array args->divisors.)

  • find_points.c:1993-2009: modelled by Ratpoints.sampleDivisor (deviation of Ratpoints.sampleDivisor: ceil and floor the functions of the C library of the platform (Float.ceil, Float.floor), which are exact, where gcc compiles instructions.)

  • find_points.c:2010-2016: modelled by Ratpoints.shapeSquares1 (deviation of Ratpoints.shapeSquares1: the divisors as a list, for the zero-terminated array args->divisors.)

  • find_points.c:2017-2018: modelled by Ratpoints.addClass (deviation of Ratpoints.addClass: one function for the three places of the C code.)

  • find_points.c:2019-2023: modelled by Ratpoints.shapeSquares1 (deviation of Ratpoints.shapeSquares1: the divisors as a list, for the zero-terminated array args->divisors.)

  • find_points.c:2024-2024: modelled by Ratpoints.runShape (deviation of Ratpoints.runShape: the switch checkDenom for the bit RATPOINTS_CHECK_DENOM of the flags, and the forbidden divisors as lists, for the arrays with their counts fba and fdc.)

  • find_points.c:2025-2027: modelled by Ratpoints.shapeAll (deviation of Ratpoints.shapeAll: the set bits of the word visited by the lowest set bit (Ratpoints.Sieve.ctz), as the C code visits them with RP_CTZL.)

  • find_points.c:2028-2037: modelled by Ratpoints.sampleSteps (deviation of Ratpoints.sampleSteps: one function for the samples of the squares and of every denominator, which the C code writes out twice.)

  • find_points.c:2038-2044: modelled by Ratpoints.shapeAll (deviation of Ratpoints.shapeAll: the set bits of the word visited by the lowest set bit (Ratpoints.Sieve.ctz), as the C code visits them with RP_CTZL.)

  • find_points.c:2045-2046: modelled by Ratpoints.addClass (deviation of Ratpoints.addClass: one function for the three places of the C code.)

  • find_points.c:2047-2050: modelled by Ratpoints.shapeAll (deviation of Ratpoints.shapeAll: the set bits of the word visited by the lowest set bit (Ratpoints.Sieve.ctz), as the C code visits them with RP_CTZL.)

  • find_points.c:2051-2065: modelled by Ratpoints.keepChecked (deviation of Ratpoints.keepChecked: the forbidden divisors as lists, for the arrays of the arguments with their counts fba and fdc.)

  • find_points.c:2066-2066: modelled by Ratpoints.shapeAll (deviation of Ratpoints.shapeAll: the set bits of the word visited by the lowest set bit (Ratpoints.Sieve.ctz), as the C code visits them with RP_CTZL.)

  • find_points.c:2074-2105: modelled by Ratpoints.shapeEstimate (deviation of Ratpoints.shapeEstimate: the estimate returned as a structure, for the four pointers of run_shape; ceil the function of the C library of the platform (Float.ceil), which is exact, where gcc compiles an instruction; 64 for LONG_LENGTH.)

  • find_points.c:2106-2106: modelled by Ratpoints.runShape (deviation of Ratpoints.runShape: the switch checkDenom for the bit RATPOINTS_CHECK_DENOM of the flags, and the forbidden divisors as lists, for the arrays with their counts fba and fdc.)

  • find_points.c:2128-2132: modelled by Ratpoints.bpwAdd (deviation of Ratpoints.bpwAdd: the two sums passed and returned, for the pointers; the number of the set bits of the word a loop over its bits (Ratpoints.popcount), for gcc’s builtin __builtin_popcountl.)

  • find_points.c:2134-2142: modelled by Ratpoints.meanBitsPerWord (deviation of Ratpoints.meanBitsPerWord: the set bits of the word visited by the lowest set bit (Ratpoints.Sieve.ctz), as the C code visits them with RP_CTZL.)

  • find_points.c:2143-2151: modelled by Ratpoints.bpwSquares1

  • find_points.c:2152-2159: modelled by Ratpoints.meanBitsPerWord (deviation of Ratpoints.meanBitsPerWord: the set bits of the word visited by the lowest set bit (Ratpoints.Sieve.ctz), as the C code visits them with RP_CTZL.)

  • find_points.c:2192-2197: modelled by Ratpoints.Sieve.forbiddenValuations (deviation of Ratpoints.Sieve.forbiddenValuations: the prime p itself, for its index pn in the table prime, and the squares modulo p by Ratpoints.Sieve.squaresMod, for the row of p in the table squares of the build; an array for the pointer coeffs_mod_p; a natural number for the unsigned long mask, without the cap m < LONG_LENGTH - 1 of the loop, which never binds for a long b_high and an odd prime, the loop ending before m = 40 (Ratpoints.Sieve.lt_forty_of_pow_le), and for p ≤ 1, which the C code never examines, the loop, once entered, does not end; natural numbers for the longs.)

  • find_points.c:2198-2200: modelled by Ratpoints.Sieve.unitParts (deviation of Ratpoints.Sieve.unitParts: an array of options of pairs, for the arrays present, w and r on the stack; natural numbers for the longs.)

  • find_points.c:2201-2203: modelled by Ratpoints.Sieve.forbiddenValuations (deviation of Ratpoints.Sieve.forbiddenValuations: the prime p itself, for its index pn in the table prime, and the squares modulo p by Ratpoints.Sieve.squaresMod, for the row of p in the table squares of the build; an array for the pointer coeffs_mod_p; a natural number for the unsigned long mask, without the cap m < LONG_LENGTH - 1 of the loop, which never binds for a long b_high and an odd prime, the loop ending before m = 40 (Ratpoints.Sieve.lt_forty_of_pow_le), and for p ≤ 1, which the C code never examines, the loop, once entered, does not end; natural numbers for the longs.)

  • find_points.c:2204-2215: modelled by Ratpoints.Sieve.unitParts (deviation of Ratpoints.Sieve.unitParts: an array of options of pairs, for the arrays present, w and r on the stack; natural numbers for the longs.)

  • find_points.c:2216-2217: modelled by Ratpoints.Sieve.forbiddenValuations (deviation of Ratpoints.Sieve.forbiddenValuations: the prime p itself, for its index pn in the table prime, and the squares modulo p by Ratpoints.Sieve.squaresMod, for the row of p in the table squares of the build; an array for the pointer coeffs_mod_p; a natural number for the unsigned long mask, without the cap m < LONG_LENGTH - 1 of the loop, which never binds for a long b_high and an odd prime, the loop ending before m = 40 (Ratpoints.Sieve.lt_forty_of_pow_le), and for p ≤ 1, which the C code never examines, the loop, once entered, does not end; natural numbers for the longs.)

  • find_points.c:2218-2228: modelled by Ratpoints.Sieve.forbiddenAt (deviation of Ratpoints.Sieve.forbiddenAt: the valuations and unit parts of the coefficients as the array of options us (Ratpoints.Sieve.unitParts), for the arrays present, w and r, its size d + 1 for the bound degree of the loop, and the squares modulo p as the argument sq (Ratpoints.Sieve.squaresMod), for the row squares[pn] of the table of the build; the test returned, for the bit that the caller sets; remainders by 2 for the masks & 1; natural numbers for the longs.)

  • find_points.c:2229-2234: modelled by Ratpoints.Sieve.forbiddenValuations (deviation of Ratpoints.Sieve.forbiddenValuations: the prime p itself, for its index pn in the table prime, and the squares modulo p by Ratpoints.Sieve.squaresMod, for the row of p in the table squares of the build; an array for the pointer coeffs_mod_p; a natural number for the unsigned long mask, without the cap m < LONG_LENGTH - 1 of the loop, which never binds for a long b_high and an odd prime, the loop ending before m = 40 (Ratpoints.Sieve.lt_forty_of_pow_le), and for p ≤ 1, which the C code never examines, the loop, once entered, does not end; natural numbers for the longs.)

  • find_points.c:2241-2252: modelled by Ratpoints.Sieve.modinv (deviation of Ratpoints.Sieve.modinv: natural numbers for x, m and the remainders, which are never negative for x ≥ 0, so that the correction of a negative x % m has no counterpart; integers for the long cofactors, which stay between -m and m (Ratpoints.Sieve.ModinvInvariant.natAbs_add_mul_le); the result a natural number.)

  • find_points.c:2267-2282: modelled by Ratpoints.Sieve.examinePower (deviation of Ratpoints.Sieve.examinePower: the tables returned as a fresh value, for the entry pw of the buffer of the prime powers that examine_power fills; m as p ^ e, for the product of e factors p; the bit arrays sq, fsq and gsq fresh arrays of Ratpoints.modWords words, which the loop at line 2282 clears, for the local array that the function leaves unset and the arrays of the entry pw; natural numbers for the longs and unsigned longs, the variable t for the multiples of p, where the C code reuses x, and the steps v x + c of Horner’s rule, with v, x and c below m, staying below m ^ 2, with the obligation stated as a lemma (Ratpoints.mul_add_lt_two_pow_64_of_lt_maxPrimeEven); the code that examine_power returns read from the density by Ratpoints.Sieve.Power.useful.)

  • find_points.c:2283-2284: modelled by Ratpoints.Sieve.setSquareBits (deviation of Ratpoints.Sieve.setSquareBits: the bit array passed and returned, for the local array sq of examine_power; natural numbers for the longs, the squares x x with x < m staying below m ^ 2, with the obligation stated as a lemma (Ratpoints.mul_self_lt_two_pow_63_of_lt_maxPrimeEven).)

  • find_points.c:2285-2293: modelled by Ratpoints.Sieve.examinePower (deviation of Ratpoints.Sieve.examinePower: the tables returned as a fresh value, for the entry pw of the buffer of the prime powers that examine_power fills; m as p ^ e, for the product of e factors p; the bit arrays sq, fsq and gsq fresh arrays of Ratpoints.modWords words, which the loop at line 2282 clears, for the local array that the function leaves unset and the arrays of the entry pw; natural numbers for the longs and unsigned longs, the variable t for the multiples of p, where the C code reuses x, and the steps v x + c of Horner’s rule, with v, x and c below m, staying below m ^ 2, with the obligation stated as a lemma (Ratpoints.mul_add_lt_two_pow_64_of_lt_maxPrimeEven); the code that examine_power returns read from the density by Ratpoints.Sieve.Power.useful.)

  • find_points.c:2294-2300: modelled by Ratpoints.Sieve.setRevBits (deviation of Ratpoints.Sieve.setRevBits: the bit array passed and returned, for the array of the entry pw; the variable t for the multiples of p, where the C code reuses x; a while loop for the loop for with the step p; natural numbers for the longs and unsigned longs.)

  • find_points.c:2301-2301: modelled by Ratpoints.Sieve.examinePower (deviation of Ratpoints.Sieve.examinePower: the tables returned as a fresh value, for the entry pw of the buffer of the prime powers that examine_power fills; m as p ^ e, for the product of e factors p; the bit arrays sq, fsq and gsq fresh arrays of Ratpoints.modWords words, which the loop at line 2282 clears, for the local array that the function leaves unset and the arrays of the entry pw; natural numbers for the longs and unsigned longs, the variable t for the multiples of p, where the C code reuses x, and the steps v x + c of Horner’s rule, with v, x and c below m, staying below m ^ 2, with the obligation stated as a lemma (Ratpoints.mul_add_lt_two_pow_64_of_lt_maxPrimeEven); the code that examine_power returns read from the density by Ratpoints.Sieve.Power.useful.)

  • find_points.c:2302-2303: modelled by Ratpoints.Sieve.unitInverses (deviation of Ratpoints.Sieve.unitInverses: the inverses a fresh array, returned, for the array inv of the entry pw that examine_power fills; natural numbers for the longs and for the unsigned short inverses, which are below m, with the obligation stated as a lemma (Ratpoints.Sieve.getElem!_inv_run_examinePower_lt_two_pow_16).)

  • find_points.c:2304-2304: excluded (other): the count np of a prime power stored in its rp_power, which nothing reads

  • find_points.c:2306-2329: modelled by Ratpoints.Sieve.powerDensity (deviation of Ratpoints.Sieve.powerDensity: the density returned, for the field r of the record pw that examine_power sets; natural numbers for the longs; the residues t stepped through by a while loop.)

  • find_points.c:2330-2330: modelled by Ratpoints.Sieve.Power.useful (deviation of Ratpoints.Sieve.Power.useful: a Boolean read from the density of the record, for the code 1 or 0 that examine_power returns.)

  • find_points.c:2331-2331: modelled by Ratpoints.Sieve.examinePower (deviation of Ratpoints.Sieve.examinePower: the tables returned as a fresh value, for the entry pw of the buffer of the prime powers that examine_power fills; m as p ^ e, for the product of e factors p; the bit arrays sq, fsq and gsq fresh arrays of Ratpoints.modWords words, which the loop at line 2282 clears, for the local array that the function leaves unset and the arrays of the entry pw; natural numbers for the longs and unsigned longs, the variable t for the multiples of p, where the C code reuses x, and the steps v x + c of Horner’s rule, with v, x and c below m, staying below m ^ 2, with the obligation stated as a lemma (Ratpoints.mul_add_lt_two_pow_64_of_lt_maxPrimeEven); the code that examine_power returns read from the density by Ratpoints.Sieve.Power.useful.)

  • find_points.c:2337-2337: modelled by Ratpoints.modulusTableMax

  • find_points.c:2346-2349: modelled by Ratpoints.addModuli (deviation of Ratpoints.addModuli: the pool passed and returned, for the array prec and the count pnp, and the records of the prime powers returned, for the buffer pws of the arguments; the tables and the densities of the primes of the loop of the tables (primeSe) and whether denominators divisible by them occur (pinf) as arrays by their positions; the estimates of the run as arguments, for the fields of the arguments; a while loop over the candidates; natural numbers for the longs; no bound npw_max (num_powers, line 2351), which never binds.)

  • find_points.c:2350-2350: modelled by Ratpoints.PowerTable (deviation of Ratpoints.PowerTable: a structure for the buffer pws, the count npw of its records and the array pw_idx of indices with its markers -1 (not examined) and -2 (useless): an array of the records, and a list of the pairs examined with an option, none for -2, a pair not in the list for -1.)

  • find_points.c:2351-2351: modelled by Ratpoints.addModuli (deviation of Ratpoints.addModuli: the pool passed and returned, for the array prec and the count pnp, and the records of the prime powers returned, for the buffer pws of the arguments; the tables and the densities of the primes of the loop of the tables (primeSe) and whether denominators divisible by them occur (pinf) as arrays by their positions; the estimates of the run as arguments, for the fields of the arguments; a while loop over the candidates; natural numbers for the longs; no bound npw_max (num_powers, line 2351), which never binds.)

  • find_points.c:2352-2354: modelled by Ratpoints.PowerTable (deviation of Ratpoints.PowerTable: a structure for the buffer pws, the count npw of its records and the array pw_idx of indices with its markers -1 (not examined) and -2 (useless): an array of the records, and a list of the pairs examined with an option, none for -2, a pair not in the list for -1.)

  • find_points.c:2355-2356: modelled by Ratpoints.addModuli (deviation of Ratpoints.addModuli: the pool passed and returned, for the array prec and the count pnp, and the records of the prime powers returned, for the buffer pws of the arguments; the tables and the densities of the primes of the loop of the tables (primeSe) and whether denominators divisible by them occur (pinf) as arrays by their positions; the estimates of the run as arguments, for the fields of the arguments; a while loop over the candidates; natural numbers for the longs; no bound npw_max (num_powers, line 2351), which never binds.)

  • find_points.c:2358-2359: modelled by Ratpoints.PowerTable (deviation of Ratpoints.PowerTable: a structure for the buffer pws, the count npw of its records and the array pw_idx of indices with its markers -1 (not examined) and -2 (useless): an array of the records, and a list of the pairs examined with an option, none for -2, a pair not in the list for -1.)

  • find_points.c:2361-2361: modelled by Ratpoints.addModuli (deviation of Ratpoints.addModuli: the pool passed and returned, for the array prec and the count pnp, and the records of the prime powers returned, for the buffer pws of the arguments; the tables and the densities of the primes of the loop of the tables (primeSe) and whether denominators divisible by them occur (pinf) as arrays by their positions; the estimates of the run as arguments, for the fields of the arguments; a while loop over the candidates; natural numbers for the longs; no bound npw_max (num_powers, line 2351), which never binds.)

  • find_points.c:2362-2362: modelled by Ratpoints.FacState (deviation of Ratpoints.FacState: a structure for the local variables of the loop over the candidates.)

  • find_points.c:2363-2363: modelled by Ratpoints.offerModulus (deviation of Ratpoints.offerModulus: the candidate returned, for the record prec[pnp] that add_moduli fills, with the key and the cost 0.0, which the caller sets, and no sieve entry.)

  • find_points.c:2364-2365: modelled by Ratpoints.FacState (deviation of Ratpoints.FacState: a structure for the local variables of the loop over the candidates.)

  • find_points.c:2368-2368: modelled by Ratpoints.offerModulus (deviation of Ratpoints.offerModulus: the candidate returned, for the record prec[pnp] that add_moduli fills, with the key and the cost 0.0, which the caller sets, and no sieve entry.)

  • find_points.c:2370-2380: modelled by Ratpoints.factorCandidate (deviation of Ratpoints.factorCandidate: a while loop with the position of the prime in the state, for the loop for whose variable pn the search for the prime below p ^ 2 advances; natural numbers for the longs.)

  • find_points.c:2381-2386: modelled by Ratpoints.takeFactor (deviation of Ratpoints.takeFactor: the densities of the primes from the array primeSe of the tables and densities of the loop of the tables, for the entries prime_se and their fields r.)

  • find_points.c:2387-2394: modelled by Ratpoints.powerIndex (deviation of Ratpoints.powerIndex: the table passed and returned, for the buffer pws, the count npw and the array pw_idx of add_moduli; no test of room in the buffer (line 2390), which never fails, since add_moduli examines each prime power at most once and num_powers counts them all.)

  • find_points.c:2395-2398: modelled by Ratpoints.takeFactor (deviation of Ratpoints.takeFactor: the densities of the primes from the array primeSe of the tables and densities of the loop of the tables, for the entries prime_se and their fields r.)

  • find_points.c:2399-2399: modelled by Ratpoints.factorCandidate (deviation of Ratpoints.factorCandidate: a while loop with the position of the prime in the state, for the loop for whose variable pn the search for the prime below p ^ 2 advances; natural numbers for the longs.)

  • find_points.c:2400-2402: modelled by Ratpoints.offerModulus (deviation of Ratpoints.offerModulus: the candidate returned, for the record prec[pnp] that add_moduli fills, with the key and the cost 0.0, which the caller sets, and no sieve entry.)

  • find_points.c:2403-2403: modelled by Ratpoints.addModuli (deviation of Ratpoints.addModuli: the pool passed and returned, for the array prec and the count pnp, and the records of the prime powers returned, for the buffer pws of the arguments; the tables and the densities of the primes of the loop of the tables (primeSe) and whether denominators divisible by them occur (pinf) as arrays by their positions; the estimates of the run as arguments, for the fields of the arguments; a while loop over the candidates; natural numbers for the longs; no bound npw_max (num_powers, line 2351), which never binds.)

  • find_points.c:2404-2406: modelled by Ratpoints.offerModulus (deviation of Ratpoints.offerModulus: the candidate returned, for the record prec[pnp] that add_moduli fills, with the key and the cost 0.0, which the caller sets, and no sieve entry.)

  • find_points.c:2407-2411: modelled by Ratpoints.addModuli (deviation of Ratpoints.addModuli: the pool passed and returned, for the array prec and the count pnp, and the records of the prime powers returned, for the buffer pws of the arguments; the tables and the densities of the primes of the loop of the tables (primeSe) and whether denominators divisible by them occur (pinf) as arrays by their positions; the estimates of the run as arguments, for the fields of the arguments; a while loop over the candidates; natural numbers for the longs; no bound npw_max (num_powers, line 2351), which never binds.)

  • find_points.c:2414-2426: modelled by Ratpoints.makeModulus (deviation of Ratpoints.makeModulus: the entry returned as a fresh value, for the space that make_power and make_modulus take from the buffer of the sieve entries, and the entry of a prime power made for each modulus that needs it, where make_modulus makes it once and keeps it by its index (power_se), with the density of the first modulus that makes it, the density of the prime power in both cases; the factors as a list (Ratpoints.Sieve.Factor), the tables of a prime from the loop of the tables and the records of the prime powers, for the pointers factor to their entries; the tables of rows, which make_power (line 2427) and make_modulus (line 2471) clear, made in the store of the run after the choice (Ratpoints.Sieve.SieveEntry.addTables).)

  • find_points.c:2427-2427: modelled by Ratpoints.Sieve.SieveEntry.addTables (deviation of Ratpoints.Sieve.SieveEntry.addTables: the tables of rows made in the store of the run, by the reference to the entry (Ratpoints.Sieve.EntryRef), for the arrays sieve of the entries, after the choice for every entry, the reserve included (Ratpoints.choiceEnd), where make_power and make_modulus make them with the entry; a table of rows made only when its reference is absent, for the test of power_se (lines 2444 and 2466) by which the entry of a prime power is made once, and for the entry of a prime, which examine_prime makes once, with its table of rows, in the loop of the tables (Ratpoints.examineInLoop) or in the third stage (lines 2994-2995), where the model makes the table of a prime of the third stage after the choice, and none for a prime that the third stage examines and passes over, whose table nothing reads.)

  • find_points.c:2428-2429: modelled by Ratpoints.makeModulus (deviation of Ratpoints.makeModulus: the entry returned as a fresh value, for the space that make_power and make_modulus take from the buffer of the sieve entries, and the entry of a prime power made for each modulus that needs it, where make_modulus makes it once and keeps it by its index (power_se), with the density of the first modulus that makes it, the density of the prime power in both cases; the factors as a list (Ratpoints.Sieve.Factor), the tables of a prime from the loop of the tables and the records of the prime powers, for the pointers factor to their entries; the tables of rows, which make_power (line 2427) and make_modulus (line 2471) clear, made in the store of the run after the choice (Ratpoints.Sieve.SieveEntry.addTables).)

  • find_points.c:2434-2470: modelled by Ratpoints.makeModulus (deviation of Ratpoints.makeModulus: the entry returned as a fresh value, for the space that make_power and make_modulus take from the buffer of the sieve entries, and the entry of a prime power made for each modulus that needs it, where make_modulus makes it once and keeps it by its index (power_se), with the density of the first modulus that makes it, the density of the prime power in both cases; the factors as a list (Ratpoints.Sieve.Factor), the tables of a prime from the loop of the tables and the records of the prime powers, for the pointers factor to their entries; the tables of rows, which make_power (line 2427) and make_modulus (line 2471) clear, made in the store of the run after the choice (Ratpoints.Sieve.SieveEntry.addTables).)

  • find_points.c:2471-2471: modelled by Ratpoints.Sieve.SieveEntry.addTables (deviation of Ratpoints.Sieve.SieveEntry.addTables: the tables of rows made in the store of the run, by the reference to the entry (Ratpoints.Sieve.EntryRef), for the arrays sieve of the entries, after the choice for every entry, the reserve included (Ratpoints.choiceEnd), where make_power and make_modulus make them with the entry; a table of rows made only when its reference is absent, for the test of power_se (lines 2444 and 2466) by which the entry of a prime power is made once, and for the entry of a prime, which examine_prime makes once, with its table of rows, in the loop of the tables (Ratpoints.examineInLoop) or in the third stage (lines 2994-2995), where the model makes the table of a prime of the third stage after the choice, and none for a prime that the third stage examines and passes over, whose table nothing reads.)

  • find_points.c:2472-2475: modelled by Ratpoints.makeModulus (deviation of Ratpoints.makeModulus: the entry returned as a fresh value, for the space that make_power and make_modulus take from the buffer of the sieve entries, and the entry of a prime power made for each modulus that needs it, where make_modulus makes it once and keeps it by its index (power_se), with the density of the first modulus that makes it, the density of the prime power in both cases; the factors as a list (Ratpoints.Sieve.Factor), the tables of a prime from the loop of the tables and the records of the prime powers, for the pointers factor to their entries; the tables of rows, which make_power (line 2427) and make_modulus (line 2471) clear, made in the store of the run after the choice (Ratpoints.Sieve.SieveEntry.addTables).)

  • find_points.c:2490-2508: modelled by Ratpoints.takeEntries (deviation of Ratpoints.takeEntries: the pool, the mask and the product passed and returned, for the pointers prec, pnp, used and rate; an integer for the long want and natural numbers for the other longs; the candidate dropped by Array.eraseIdxIfInBounds, for the loop that moves the rest down.)

  • find_points.c:2509-2518: modelled by Ratpoints.dropUsed

  • find_points.c:2519-2520: modelled by Ratpoints.takeEntries (deviation of Ratpoints.takeEntries: the pool, the mask and the product passed and returned, for the pointers prec, pnp, used and rate; an integer for the long want and natural numbers for the other longs; the candidate dropped by Array.eraseIdxIfInBounds, for the loop that moves the rest down.)

  • find_points.c:2522-2532: modelled by Ratpoints.sievingInfo (deviation of Ratpoints.sievingInfo: the result as the prime that sieving_info returns when the curve has no points modulo it, the error of the result, and as a structure (Ratpoints.SievingInfo) otherwise, for the code 0 that it returns and the fields of the arguments that it sets; the arrays prime_se, power_se and pinf of the loop of the tables in its state (Ratpoints.TableLoop), the entries of the prime powers made where a modulus needs them (Ratpoints.makeModulus); no failure for lack of memory (lines 2801 and 3061), which the model cannot meet; no output under RP_PRIME_STATS or DEBUG, and the report under RATPOINTS_VERBOSE at its end (lines 3089-3095) printed by the search after it returns (Ratpoints.Report.choice).)

  • find_points.c:2533-2536: modelled by Ratpoints.Sieve.forbidden (deviation of Ratpoints.Sieve.forbidden: the position examined as an argument, for the final pn_lim of the loop of the tables; the Kronecker symbol by the table of the squares modulo p, which marks 0 as a square, for mpz_kronecker_si; the flag RATPOINTS_CHECK_DENOM not tested, since the search computes the forbidden divisors only when the flag is set, for even degree (Ratpoints.sievingInfo); lists, for the two arrays of the arguments with their terminating zeros; the words of one of the first Ratpoints.numPrimes primes an array of the first p words of the pattern sieves0, for the pointers start and end into it, and those of a prime beyond them made with its entry, for the words that sieving_info makes after this loop in the buffer forb_words, with no failure for lack of memory, where sieving_info drops those whose words it cannot store; natural numbers for the longs and the reciprocals; no output under DEBUG.)

  • find_points.c:2537-2539: modelled by Ratpoints.TableLoop (deviation of Ratpoints.TableLoop: a structure for the local variables of sieving_info that the loop changes: arrays, for prec with its count pnp, prime_se, pinf and the arrays of the forbidden divisors with their counts; the tables and the densities of the primes, for the entries prime_se; the store of the tables of rows, for the arrays sieve of the entries.)

  • find_points.c:2545-2545: modelled by Ratpoints.TableLoop (deviation of Ratpoints.TableLoop: a structure for the local variables of sieving_info that the loop changes: arrays, for prec with its count pnp, prime_se, pinf and the arrays of the forbidden divisors with their counts; the tables and the densities of the primes, for the entries prime_se; the store of the tables of rows, for the arrays sieve of the entries.)

  • find_points.c:2546-2546: modelled by Ratpoints.sievingInfo (deviation of Ratpoints.sievingInfo: the result as the prime that sieving_info returns when the curve has no points modulo it, the error of the result, and as a structure (Ratpoints.SievingInfo) otherwise, for the code 0 that it returns and the fields of the arguments that it sets; the arrays prime_se, power_se and pinf of the loop of the tables in its state (Ratpoints.TableLoop), the entries of the prime powers made where a modulus needs them (Ratpoints.makeModulus); no failure for lack of memory (lines 2801 and 3061), which the model cannot meet; no output under RP_PRIME_STATS or DEBUG, and the report under RATPOINTS_VERBOSE at its end (lines 3089-3095) printed by the search after it returns (Ratpoints.Report.choice).)

  • find_points.c:2547-2547: modelled by Ratpoints.TableLoop (deviation of Ratpoints.TableLoop: a structure for the local variables of sieving_info that the loop changes: arrays, for prec with its count pnp, prime_se, pinf and the arrays of the forbidden divisors with their counts; the tables and the densities of the primes, for the entries prime_se; the store of the tables of rows, for the arrays sieve of the entries.)

  • find_points.c:2548-2559: modelled by Ratpoints.sievingInfo (deviation of Ratpoints.sievingInfo: the result as the prime that sieving_info returns when the curve has no points modulo it, the error of the result, and as a structure (Ratpoints.SievingInfo) otherwise, for the code 0 that it returns and the fields of the arguments that it sets; the arrays prime_se, power_se and pinf of the loop of the tables in its state (Ratpoints.TableLoop), the entries of the prime powers made where a modulus needs them (Ratpoints.makeModulus); no failure for lack of memory (lines 2801 and 3061), which the model cannot meet; no output under RP_PRIME_STATS or DEBUG, and the report under RATPOINTS_VERBOSE at its end (lines 3089-3095) printed by the search after it returns (Ratpoints.Report.choice).)

  • find_points.c:2561-2562: modelled by Ratpoints.Sieve.forbidden (deviation of Ratpoints.Sieve.forbidden: the position examined as an argument, for the final pn_lim of the loop of the tables; the Kronecker symbol by the table of the squares modulo p, which marks 0 as a square, for mpz_kronecker_si; the flag RATPOINTS_CHECK_DENOM not tested, since the search computes the forbidden divisors only when the flag is set, for even degree (Ratpoints.sievingInfo); lists, for the two arrays of the arguments with their terminating zeros; the words of one of the first Ratpoints.numPrimes primes an array of the first p words of the pattern sieves0, for the pointers start and end into it, and those of a prime beyond them made with its entry, for the words that sieving_info makes after this loop in the buffer forb_words, with no failure for lack of memory, where sieving_info drops those whose words it cannot store; natural numbers for the longs and the reciprocals; no output under DEBUG.)

  • find_points.c:2566-2567: modelled by Ratpoints.TableLoop (deviation of Ratpoints.TableLoop: a structure for the local variables of sieving_info that the loop changes: arrays, for prec with its count pnp, prime_se, pinf and the arrays of the forbidden divisors with their counts; the tables and the densities of the primes, for the entries prime_se; the store of the tables of rows, for the arrays sieve of the entries.)

  • find_points.c:2569-2575: modelled by Ratpoints.SieveOptions.tuning (deviation of Ratpoints.SieveOptions.tuning: the four values as a quadruple, for the local variables of sieving_info; the doubles of the options by their bits (Ratpoints.Double.toFloat).)

  • find_points.c:2580-2581: modelled by Ratpoints.adaptStart (deviation of Ratpoints.adaptStart: a UInt64 for the unsigned long, 2 ^ 64 - 1 for ULONG_MAX.)

  • find_points.c:2587-2588: modelled by Ratpoints.checkRelOf (deviation of Ratpoints.checkRelOf: the value returned, for the field check_rel of the arguments; the double of -W by its bits.)

  • find_points.c:2595-2596: modelled by Ratpoints.sievingInfo (deviation of Ratpoints.sievingInfo: the result as the prime that sieving_info returns when the curve has no points modulo it, the error of the result, and as a structure (Ratpoints.SievingInfo) otherwise, for the code 0 that it returns and the fields of the arguments that it sets; the arrays prime_se, power_se and pinf of the loop of the tables in its state (Ratpoints.TableLoop), the entries of the prime powers made where a modulus needs them (Ratpoints.makeModulus); no failure for lack of memory (lines 2801 and 3061), which the model cannot meet; no output under RP_PRIME_STATS or DEBUG, and the report under RATPOINTS_VERBOSE at its end (lines 3089-3095) printed by the search after it returns (Ratpoints.Report.choice).)

  • find_points.c:2597-2599: modelled by Ratpoints.choiceEstimate (deviation of Ratpoints.choiceEstimate: one function for the two places of the C code, the values returned.)

  • find_points.c:2601-2605: modelled by Ratpoints.tablesLoop (deviation of Ratpoints.tablesLoop: a loop over the first Ratpoints.numPrimes positions that ends when the position reaches the number to look at, for the loop for whose bound the body raises, which never passes Ratpoints.numPrimes; no clearing of the arrays prime_se, power_se and pinf (lines 2601-2602), which the state starts empty.)

  • find_points.c:2606-2626: modelled by Ratpoints.examineInLoop (deviation of Ratpoints.examineInLoop: the exit as none, for the prime that sieving_info returns, which the loop of the tables returns (Ratpoints.tablesLoop); the store with the table of rows of the prime, for the array sieve of its entry.)

  • find_points.c:2627-2631: modelled by Ratpoints.Sieve.forbiddenOfPrime (deviation of Ratpoints.Sieve.forbiddenOfPrime: the entry returned, for the entries that the C code writes into the arrays args->forb_ba and args->forbidden and counts; the words of the prime an array of the first p words of the pattern sieves0 of the build, for the pointers start and end into it; natural numbers for the longs and the reciprocal; no output under DEBUG.)

  • find_points.c:2632-2641: modelled by Ratpoints.Sieve.allValuations (deviation of Ratpoints.Sieve.allValuations: a natural number for the unsigned long mask, without the cap m < LONG_LENGTH - 1 of the loop, which never binds for a long b_high and an odd prime, the loop ending before m = 40 (Ratpoints.Sieve.lt_forty_of_pow_le), and for p ≤ 1, which the C code never examines, the loop, once entered, does not end; natural numbers for the longs.)

  • find_points.c:2642-2676: modelled by Ratpoints.Sieve.forbiddenOfPrime (deviation of Ratpoints.Sieve.forbiddenOfPrime: the entry returned, for the entries that the C code writes into the arrays args->forb_ba and args->forbidden and counts; the words of the prime an array of the first p words of the pattern sieves0 of the build, for the pointers start and end into it; natural numbers for the longs and the reciprocal; no output under DEBUG.)

  • find_points.c:2677-2677: modelled by Ratpoints.examineInLoop (deviation of Ratpoints.examineInLoop: the exit as none, for the prime that sieving_info returns, which the loop of the tables returns (Ratpoints.tablesLoop); the store with the table of rows of the prime, for the array sieve of its entry.)

  • find_points.c:2693-2693: modelled by Ratpoints.tablesLoop (deviation of Ratpoints.tablesLoop: a loop over the first Ratpoints.numPrimes positions that ends when the position reaches the number to look at, for the loop for whose bound the body raises, which never passes Ratpoints.numPrimes; no clearing of the arrays prime_se, power_se and pinf (lines 2601-2602), which the state starts empty.)

  • find_points.c:2694-2705: modelled by Ratpoints.raiseLimit (deviation of Ratpoints.raiseLimit: the sort by qsort with compare_entries as Lean’s stable merge sort (Ratpoints.sortFrom), which gives the order of glibc’s qsort, stable when it can allocate its buffer, as always in the model, also on ties, since the keys are finite or +∞; integers for the longs that may be negative or large.)

  • find_points.c:2707-2707: modelled by Ratpoints.tablesLoop (deviation of Ratpoints.tablesLoop: a loop over the first Ratpoints.numPrimes positions that ends when the position reaches the number to look at, for the loop for whose bound the body raises, which never passes Ratpoints.numPrimes; no clearing of the arrays prime_se, power_se and pinf (lines 2601-2602), which the state starts empty.)

  • find_points.c:2709-2772: modelled by Ratpoints.Sieve.forbidden (deviation of Ratpoints.Sieve.forbidden: the position examined as an argument, for the final pn_lim of the loop of the tables; the Kronecker symbol by the table of the squares modulo p, which marks 0 as a square, for mpz_kronecker_si; the flag RATPOINTS_CHECK_DENOM not tested, since the search computes the forbidden divisors only when the flag is set, for even degree (Ratpoints.sievingInfo); lists, for the two arrays of the arguments with their terminating zeros; the words of one of the first Ratpoints.numPrimes primes an array of the first p words of the pattern sieves0, for the pointers start and end into it, and those of a prime beyond them made with its entry, for the words that sieving_info makes after this loop in the buffer forb_words, with no failure for lack of memory, where sieving_info drops those whose words it cannot store; natural numbers for the longs and the reciprocals; no output under DEBUG.)

  • find_points.c:2773-2777: modelled by Ratpoints.Sieve.forbiddenRow (deviation of Ratpoints.Sieve.forbiddenRow: one function for the two codes that make these words, the array work of the generator of find_points.h, for the primes of the table, and the words that sieving_info makes in the buffer forb_words for the forbidden divisors beyond the table (Ratpoints.Sieve.forbidden), with the positions p i for i < 64, for the positions m = 0, p, 2 p, … below 64 p there; a fresh array of p words, for the array work of RATPOINTS_MAX_PRIME words and for the space in the buffer; divisions and remainders for the shifts and masks by LONG_SHIFT and LONG_MASK.)

  • find_points.c:2778-2789: modelled by Ratpoints.Sieve.forbidden (deviation of Ratpoints.Sieve.forbidden: the position examined as an argument, for the final pn_lim of the loop of the tables; the Kronecker symbol by the table of the squares modulo p, which marks 0 as a square, for mpz_kronecker_si; the flag RATPOINTS_CHECK_DENOM not tested, since the search computes the forbidden divisors only when the flag is set, for even degree (Ratpoints.sievingInfo); lists, for the two arrays of the arguments with their terminating zeros; the words of one of the first Ratpoints.numPrimes primes an array of the first p words of the pattern sieves0, for the pointers start and end into it, and those of a prime beyond them made with its entry, for the words that sieving_info makes after this loop in the buffer forb_words, with no failure for lack of memory, where sieving_info drops those whose words it cannot store; natural numbers for the longs and the reciprocals; no output under DEBUG.)

  • find_points.c:2794-2795: modelled by Ratpoints.sievingInfo (deviation of Ratpoints.sievingInfo: the result as the prime that sieving_info returns when the curve has no points modulo it, the error of the result, and as a structure (Ratpoints.SievingInfo) otherwise, for the code 0 that it returns and the fields of the arguments that it sets; the arrays prime_se, power_se and pinf of the loop of the tables in its state (Ratpoints.TableLoop), the entries of the prime powers made where a modulus needs them (Ratpoints.makeModulus); no failure for lack of memory (lines 2801 and 3061), which the model cannot meet; no output under RP_PRIME_STATS or DEBUG, and the report under RATPOINTS_VERBOSE at its end (lines 3089-3095) printed by the search after it returns (Ratpoints.Report.choice).)

  • find_points.c:2801-2801: excluded (memory): the enlargement of ba_buffer for the primes that the loop of the tables of sieving_info looked at beyond num_primes, which fails only for lack of memory

  • find_points.c:2808-2812: modelled by Ratpoints.choiceTail (deviation of Ratpoints.choiceTail: the sort by qsort with compare_entries as Lean’s stable merge sort (Ratpoints.sortFrom), which gives the order of glibc’s qsort, stable when it can allocate its buffer, as always in the model, also on ties, since the keys are finite or +∞; the result returned as a structure (Ratpoints.SievingInfo), for the fields of the arguments that sieving_info sets.)

  • find_points.c:2813-2815: modelled by Ratpoints.choiceEstimate (deviation of Ratpoints.choiceEstimate: one function for the two places of the C code, the values returned.)

  • find_points.c:2816-2823: modelled by Ratpoints.choiceTail (deviation of Ratpoints.choiceTail: the sort by qsort with compare_entries as Lean’s stable merge sort (Ratpoints.sortFrom), which gives the order of glibc’s qsort, stable when it can allocate its buffer, as always in the model, also on ties, since the keys are finite or +∞; the result returned as a structure (Ratpoints.SievingInfo), for the fields of the arguments that sieving_info sets.)

  • find_points.c:2826-2826: modelled by Ratpoints.choiceTail (deviation of Ratpoints.choiceTail: the sort by qsort with compare_entries as Lean’s stable merge sort (Ratpoints.sortFrom), which gives the order of glibc’s qsort, stable when it can allocate its buffer, as always in the model, also on ties, since the keys are finite or +∞; the result returned as a structure (Ratpoints.SievingInfo), for the fields of the arguments that sieving_info sets.)

  • find_points.c:2843-2846: modelled by Ratpoints.firstStages (deviation of Ratpoints.firstStages: integers for the longs that may be negative.)

  • find_points.c:2853-2863: modelled by Ratpoints.rankSecond (deviation of Ratpoints.rankSecond: the sort by qsort with compare_entries as Lean’s stable merge sort (Ratpoints.sortFrom), which gives the order of glibc’s qsort, stable when it can allocate its buffer, as always in the model, also on ties, since the keys are finite or +∞.)

  • find_points.c:2864-2871: modelled by Ratpoints.firstStages (deviation of Ratpoints.firstStages: integers for the longs that may be negative.)

  • find_points.c:2879-2890: modelled by Ratpoints.dropComposites

  • find_points.c:2894-2900: modelled by Ratpoints.stageEntries (deviation of Ratpoints.stageEntries: the entries kept in the candidates, for the array sieve_list into which sieving_info puts them (line 2898), which the caller reads from the candidates.)

  • find_points.c:2922-2922: modelled by Ratpoints.ThirdState (deviation of Ratpoints.ThirdState: a structure for the local variables of the stage.)

  • find_points.c:2926-2932: modelled by Ratpoints.thirdOf (deviation of Ratpoints.thirdOf: integers for the comparison of the longs; the double of -Q by its bits.)

  • find_points.c:2933-2933: modelled by Ratpoints.ThirdState (deviation of Ratpoints.ThirdState: a structure for the local variables of the stage.)

  • find_points.c:2941-2947: modelled by Ratpoints.survivorsAtThird (deviation of Ratpoints.survivorsAtThird: 64 for LONG_LENGTH.)

  • find_points.c:2949-2950: modelled by Ratpoints.thirdStage (deviation of Ratpoints.thirdStage: a while loop over the state, the candidates swapped by Array.swapIfInBounds; the sieve entry of the prime taken kept in its candidate, for the array sieve_list (line 3014).)

  • find_points.c:2955-2961: modelled by Ratpoints.bestByR

  • find_points.c:2973-2975: modelled by Ratpoints.thirdStage (deviation of Ratpoints.thirdStage: a while loop over the state, the candidates swapped by Array.swapIfInBounds; the sieve entry of the prime taken kept in its candidate, for the array sieve_list (line 3014).)

  • find_points.c:2976-2978: modelled by Ratpoints.lookFurther

  • find_points.c:2980-2981: modelled by Ratpoints.thirdStage (deviation of Ratpoints.thirdStage: a while loop over the state, the candidates swapped by Array.swapIfInBounds; the sieve entry of the prime taken kept in its candidate, for the array sieve_list (line 3014).)

  • find_points.c:2982-2991: modelled by Ratpoints.rTyp

  • find_points.c:2992-2993: modelled by Ratpoints.thirdStage (deviation of Ratpoints.thirdStage: a while loop over the state, the candidates swapped by Array.swapIfInBounds; the sieve entry of the prime taken kept in its candidate, for the array sieve_list (line 3014).)

  • find_points.c:2994-3008: modelled by Ratpoints.lookFurther

  • find_points.c:3009-3016: modelled by Ratpoints.thirdStage (deviation of Ratpoints.thirdStage: a while loop over the state, the candidates swapped by Array.swapIfInBounds; the sieve entry of the prime taken kept in its candidate, for the array sieve_list (line 3014).)

  • find_points.c:3017-3017: modelled by Ratpoints.choiceEnd (deviation of Ratpoints.choiceEnd: the sort by qsort with compare_by_r as Lean’s stable merge sort (Ratpoints.sortFrom), from the end of the second stage on, as the C code sorts, which gives the order of glibc’s qsort, stable when it can allocate its buffer, as always in the model; the entries, the reciprocals and the store returned, for the arrays sieve_list and magics of the arguments and the arrays sieve of the entries; sp3_max the length of the list of the entries, the larger of sp3 and the size of the pool, which is never smaller; no enlargement of the buffer of the rows (lines 3042-3061), which the model does not have.)

  • find_points.c:3024-3034: modelled by Ratpoints.choiceEnd (deviation of Ratpoints.choiceEnd: the sort by qsort with compare_by_r as Lean’s stable merge sort (Ratpoints.sortFrom), from the end of the second stage on, as the C code sorts, which gives the order of glibc’s qsort, stable when it can allocate its buffer, as always in the model; the entries, the reciprocals and the store returned, for the arrays sieve_list and magics of the arguments and the arrays sieve of the entries; sp3_max the length of the list of the entries, the larger of sp3 and the size of the pool, which is never smaller; no enlargement of the buffer of the rows (lines 3042-3061), which the model does not have.)

  • find_points.c:3036-3062: excluded (memory): the enlargement of ba_buffer for the tables of every prime looked at, those that the third stage looked at among them, and of the composite moduli of the first two stages and their prime-power factors, which fails only for lack of memory

  • find_points.c:3064-3070: modelled by Ratpoints.choiceEnd (deviation of Ratpoints.choiceEnd: the sort by qsort with compare_by_r as Lean’s stable merge sort (Ratpoints.sortFrom), from the end of the second stage on, as the C code sorts, which gives the order of glibc’s qsort, stable when it can allocate its buffer, as always in the model; the entries, the reciprocals and the store returned, for the arrays sieve_list and magics of the arguments and the arrays sieve of the entries; sp3_max the length of the list of the entries, the larger of sp3 and the size of the pool, which is never smaller; no enlargement of the buffer of the rows (lines 3042-3061), which the model does not have.)

  • find_points.c:3073-3087: excluded (instrumentation): RP_PRIME_STATS, development instrumentation that prints on stderr one line per curve: the primes looked at and those that carry information, the ends of the three stages, the estimates of the run and the density of each candidate

  • find_points.c:3089-3095: modelled by Ratpoints.Report.choice (deviation of Ratpoints.Report.choice: the result of the choice as an argument, for the local pn_lim and the fields of the arguments that sieving_info prints, which the search prints after it returns, nothing being printed in between; the double bpw a value of Lean’s Float (Ratpoints.Double.ofFloat); the length of the third stage an integer, for the difference of the longs.)

  • find_points.c:3098-3100: excluded (instrumentation): the message under DEBUG at the end of sieving_info

  • find_points.c:3102-3103: modelled by Ratpoints.sievingInfo (deviation of Ratpoints.sievingInfo: the result as the prime that sieving_info returns when the curve has no points modulo it, the error of the result, and as a structure (Ratpoints.SievingInfo) otherwise, for the code 0 that it returns and the fields of the arguments that it sets; the arrays prime_se, power_se and pinf of the loop of the tables in its state (Ratpoints.TableLoop), the entries of the prime powers made where a modulus needs them (Ratpoints.makeModulus); no failure for lack of memory (lines 2801 and 3061), which the model cannot meet; no output under RP_PRIME_STATS or DEBUG, and the report under RATPOINTS_VERBOSE at its end (lines 3089-3095) printed by the search after it returns (Ratpoints.Report.choice).)

  • find_points.c:3112-3114: modelled by Ratpoints.Sieve.sift (deviation of Ratpoints.Sieve.sift: the height bound converted to Int64, which is exact for H < 2 ^ 63, and the denominator too, and the bits back to integers; the bounds of the search intervals an array, for the struct rp_intervals with its pointers bd and end, which sift reaches through the field iv of the sieving thread, which worker_init clears (line 3130) and run_block sets for each block (line 3913; here Ratpoints.Sieve.runBlock, which passes the array of the run on); one call of Ratpoints.Sieve.setRows, for the two calls with the flag shared a constant, between which the pool of threads chooses, which the model does not have; the store of the tables of rows passed and returned, for the arrays sieve of the entries of the arguments, which sift reaches through sieve_list and which keep the rows built for the rest of the run; the end sp1 of the first stage, the entries es and the reciprocals mgs of the first two stages, the entries es3 of the third stage and their reciprocals mgs3 as arguments, for the numbers sp1, sp2 and sp3 that the sieving thread keeps (worker_init), the entries sieve_list[0], …, sieve_list[sp2 - 1], the array magics of the arguments, which _ratpoints_sift0 reads, and the entries sieve_list[sp2], …, sieve_list[sp3 - 1] and the reciprocals magics[sp2], …, magics[sp3 - 1], which fill_checks reads, the cut points of the decision of the block (Ratpoints.Sieve.runBlock); the residues bp and the class cl as values, for the pointers bp_list and cls, and the array offsets of the row offsets of the run as an argument, which the C code reaches through the pointer offset of the class; the thunk of Ratpoints.Sieve.fillChecks, for the table checks of the sieving thread, which fill_checks fills, and its flag stage3_filled, which sift clears; the thunk of the products w, for the flag compute_bc, which sift sets and _ratpoints_check_point clears when it computes the products; the counters cnt passed and returned, for those of the sieving thread, the count sifts one up at the start (line 3461); the delivery r passed and returned, for the pointers info and wk->quit, which worker_init clears, and the count total that sift keeps from zero and returns; the arguments of the run passed explicitly, for the pointer args of the sieving thread (rp-private.h:574), which worker_init sets and through which sift reads them; no pool, slot and stop flag of a thread of the pool, the flag by which the pool of threads tells it to abandon its block (pool, slot, stop, rp-private.h:584, excluded with the threads); natural numbers and integers for the longs; no measurements of the phases (RP_SIFT_TIC, RP_SETUP_TIC and their TOC) and no output under DEBUG.)

  • find_points.c:3119-3121: modelled by Ratpoints.Sieve.siftPiece (deviation of Ratpoints.Sieve.siftPiece: the arm of the first stage chosen by a test on the constant Ratpoints.chunk, for the conditional compilation #if (RATPOINTS_CHUNK > 1) && (RATPOINTS_CHUNK <= 16) (sift.c:452, sift.c:575, sift.c:943), which compiles one arm only, and tail_leg with the chunked one; a fresh array of zeros for each piece, for the survivors array of the sieving thread, which every piece reuses, with one bit array more for the alignment, and whose words malloc leaves uninitialized; the piece by its first word number w0 and its number n of bit arrays, for w_low and w_high, and an index for the pointer to its last bit array; the moduli of the first two stages with their rows and offsets as the list specs and the end sp1 of the first stage, for the sieve specs sieves and the number sp1 that the sieving thread keeps, the reciprocals of their moduli as the list mgs, for the array magics of the arguments, and the thunk checks, for the table checks of the third stage and its length nchecks = sp3 - sp2; the class cl as a value, for the pointer cls; integers for the longs of the test small, which stay longs, and a Boolean for its int; the counters cnt passed and returned, for the field n_words of the sieving thread, which counts the n Ratpoints.rbaPack words of the piece (line 548), the product of UInt64s as the C code multiplies the unsigned long by RBA_PACK; the thunk w of the products of the check as an argument, where _ratpoints_check_point computes the products when the first survivor of b reaches it; the delivery r passed and returned, for the pointers info and wk->quit and the count total that _ratpoints_sift0 keeps from zero and returns, and its returns at a stop within the walk through the set bits of a word passed on by the scan (Ratpoints.Sieve.scanPiece); natural numbers and integers for the longs; no measurements of the phases (RP_TIC, RP_TOC, RP_PHASE_TIMING) and no stop after one of them (RP_STOP_AFTER).)

  • find_points.c:3122-3122: modelled by Ratpoints.Sieve.checkPoint (deviation of Ratpoints.Sieve.checkPoint: the products w as a thunk, which the sieve of one denominator makes for each denominator (Ratpoints.Sieve.sift) and which is forced when the first numerator of b reaches the check, for the array work of the sieving thread, which worker_init gives it, and its flag compute_bc, which sift sets and _ratpoints_check_point clears when it computes the products; the degree d and the flags fl as arguments, handed down from Ratpoints.Sieve.sieveRun through the components that call the check, for the degree and the bits RATPOINTS_REVERSED, RATPOINTS_NO_CHECK and RATPOINTS_NO_Y of the flags of the search, which _ratpoints_check_point reads through its worker (args->degree, args->flags); the delivery r passed and returned, for the pointers info and wk->quit and the count total that _ratpoints_check_point keeps from zero and returns, and the three branches of the map of the reversal at each call one definition (Ratpoints.Delivery.callMapped); the square root and the test of the remainder by Nat.sqrt on v, for mpz_sqrtrem; integers for the longs a and b (the negations of the map stay longs by Ratpoints.fitsLong_neg); no measurements of the time of the check and of its products (RP_CHECK, RP_BC_TIC, RP_BC_TOC under RP_PHASE_TIMING), and no output under DEBUG.)

  • find_points.c:3123-3124: modelled by Ratpoints.Sieve.sift (deviation of Ratpoints.Sieve.sift: the height bound converted to Int64, which is exact for H < 2 ^ 63, and the denominator too, and the bits back to integers; the bounds of the search intervals an array, for the struct rp_intervals with its pointers bd and end, which sift reaches through the field iv of the sieving thread, which worker_init clears (line 3130) and run_block sets for each block (line 3913; here Ratpoints.Sieve.runBlock, which passes the array of the run on); one call of Ratpoints.Sieve.setRows, for the two calls with the flag shared a constant, between which the pool of threads chooses, which the model does not have; the store of the tables of rows passed and returned, for the arrays sieve of the entries of the arguments, which sift reaches through sieve_list and which keep the rows built for the rest of the run; the end sp1 of the first stage, the entries es and the reciprocals mgs of the first two stages, the entries es3 of the third stage and their reciprocals mgs3 as arguments, for the numbers sp1, sp2 and sp3 that the sieving thread keeps (worker_init), the entries sieve_list[0], …, sieve_list[sp2 - 1], the array magics of the arguments, which _ratpoints_sift0 reads, and the entries sieve_list[sp2], …, sieve_list[sp3 - 1] and the reciprocals magics[sp2], …, magics[sp3 - 1], which fill_checks reads, the cut points of the decision of the block (Ratpoints.Sieve.runBlock); the residues bp and the class cl as values, for the pointers bp_list and cls, and the array offsets of the row offsets of the run as an argument, which the C code reaches through the pointer offset of the class; the thunk of Ratpoints.Sieve.fillChecks, for the table checks of the sieving thread, which fill_checks fills, and its flag stage3_filled, which sift clears; the thunk of the products w, for the flag compute_bc, which sift sets and _ratpoints_check_point clears when it computes the products; the counters cnt passed and returned, for those of the sieving thread, the count sifts one up at the start (line 3461); the delivery r passed and returned, for the pointers info and wk->quit, which worker_init clears, and the count total that sift keeps from zero and returns; the arguments of the run passed explicitly, for the pointer args of the sieving thread (rp-private.h:574), which worker_init sets and through which sift reads them; no pool, slot and stop flag of a thread of the pool, the flag by which the pool of threads tells it to abandon its block (pool, slot, stop, rp-private.h:584, excluded with the threads); natural numbers and integers for the longs; no measurements of the phases (RP_SIFT_TIC, RP_SETUP_TIC and their TOC) and no output under DEBUG.)

  • find_points.c:3127-3128: modelled by Ratpoints.Sieve.runBlock (deviation of Ratpoints.Sieve.runBlock: the decision’s entries and reciprocals cut as lists for each block, for the numbers sp2 and sp3 that the sieving thread keeps and through which sift and fill_bp_list read the arrays sieve_list and magics; the report returned with the delivery and the store, for the fields of the sieving thread that worker_stat copies into it after the block; the counters and the index of the decision, which worker_init clears before the run (lines 3127-3128), set only here, for each block (lines 3911 and 3914-3915), before they are read; the arguments of the run passed explicitly, for the fields of the run and of the arguments that run_block reads; the delivery r passed and returned, for the pointers info and wk->quit and the count total that run_block keeps from zero and returns; the array bp_list of sp3_max entries on the stack, of which fill_bp_list fills the first sp2, a list made by Ratpoints.Sieve.siftDen; natural numbers for the longs.)

  • find_points.c:3129-3130: modelled by Ratpoints.Sieve.sift (deviation of Ratpoints.Sieve.sift: the height bound converted to Int64, which is exact for H < 2 ^ 63, and the denominator too, and the bits back to integers; the bounds of the search intervals an array, for the struct rp_intervals with its pointers bd and end, which sift reaches through the field iv of the sieving thread, which worker_init clears (line 3130) and run_block sets for each block (line 3913; here Ratpoints.Sieve.runBlock, which passes the array of the run on); one call of Ratpoints.Sieve.setRows, for the two calls with the flag shared a constant, between which the pool of threads chooses, which the model does not have; the store of the tables of rows passed and returned, for the arrays sieve of the entries of the arguments, which sift reaches through sieve_list and which keep the rows built for the rest of the run; the end sp1 of the first stage, the entries es and the reciprocals mgs of the first two stages, the entries es3 of the third stage and their reciprocals mgs3 as arguments, for the numbers sp1, sp2 and sp3 that the sieving thread keeps (worker_init), the entries sieve_list[0], …, sieve_list[sp2 - 1], the array magics of the arguments, which _ratpoints_sift0 reads, and the entries sieve_list[sp2], …, sieve_list[sp3 - 1] and the reciprocals magics[sp2], …, magics[sp3 - 1], which fill_checks reads, the cut points of the decision of the block (Ratpoints.Sieve.runBlock); the residues bp and the class cl as values, for the pointers bp_list and cls, and the array offsets of the row offsets of the run as an argument, which the C code reaches through the pointer offset of the class; the thunk of Ratpoints.Sieve.fillChecks, for the table checks of the sieving thread, which fill_checks fills, and its flag stage3_filled, which sift clears; the thunk of the products w, for the flag compute_bc, which sift sets and _ratpoints_check_point clears when it computes the products; the counters cnt passed and returned, for those of the sieving thread, the count sifts one up at the start (line 3461); the delivery r passed and returned, for the pointers info and wk->quit, which worker_init clears, and the count total that sift keeps from zero and returns; the arguments of the run passed explicitly, for the pointer args of the sieving thread (rp-private.h:574), which worker_init sets and through which sift reads them; no pool, slot and stop flag of a thread of the pool, the flag by which the pool of threads tells it to abandon its block (pool, slot, stop, rp-private.h:584, excluded with the threads); natural numbers and integers for the longs; no measurements of the phases (RP_SIFT_TIC, RP_SETUP_TIC and their TOC) and no output under DEBUG.)

  • find_points.c:3132-3136: excluded (memory): the result of worker_init, whether the survivors array could be allocated, and worker_clear, which frees it; the model takes a fresh array for each piece and cannot fail for lack of memory

  • find_points.c:3149-3170: modelled by Ratpoints.Sieve.setRows (deviation of Ratpoints.Sieve.setRows: a list of the moduli with their rows and offsets, for the array of sieve specs ssp that set_rows fills; the empty array for the null pointer of a row not built yet; the start set to 0, where the C code leaves the field as it is until the first stage sets it; the end p also for a row not built yet, where the C code adds p to the null pointer; the row read plainly, for the acquire load that the flag shared chooses when threads share the tables of rows; the store of the tables of rows of the run as an argument, for the arrays sieve of the entries that the pointers in sieve_list reach; the array of the row offsets of the run as an argument, which the C code reaches through the pointer offset of the class, and a class without a row of offsets (none, for NULL), which the run never sifts, reads the offsets from position 0; natural numbers for the longs.)

  • find_points.c:3217-3218: modelled by Ratpoints.Sieve.ExactEnd (deviation of Ratpoints.Sieve.ExactEnd: a natural number for the int s, which is from 0 to 127, and a Boolean for the int neg.)

  • find_points.c:3219-3221: modelled by Ratpoints.Sieve.IntervalBounds (deviation of Ratpoints.Sieve.IntervalBounds: natural numbers for the int shifts lsh and ush, which are from 0 to 63, and a Boolean for the int fast.)

  • find_points.c:3231-3238: modelled by Ratpoints.Sieve.exactScale (deviation of Ratpoints.Sieve.exactScale: the 128-bit product, sum and shift on two 64-bit halves, the high half of the product by Ratpoints.Sieve.mulHi, for the unsigned __int128 of the arm that the modelled builds compile (the compiler defines __SIZEOF_INT128__, and RP_NO_INT128 is not set), which Lean core does not have; the other arm (lines 3239-3256), for a build without a 128-bit type, is excluded; the long b converted to a 64-bit word, as the C code converts it to an unsigned long.)

  • find_points.c:3239-3256: excluded (other): the arm of exact_scale for a build without a 128-bit type or with RP_NO_INT128, which puts the 128-bit product together from 32-bit halves; the modelled builds compile the arm with unsigned __int128 (Ratpoints.Sieve.exactScale)

  • find_points.c:3257-3257: modelled by Ratpoints.Sieve.exactScale (deviation of Ratpoints.Sieve.exactScale: the 128-bit product, sum and shift on two 64-bit halves, the high half of the product by Ratpoints.Sieve.mulHi, for the unsigned __int128 of the arm that the modelled builds compile (the compiler defines __SIZEOF_INT128__, and RP_NO_INT128 is not set), which Lean core does not have; the other arm (lines 3239-3256), for a build without a 128-bit type, is excluded; the long b converted to a 64-bit word, as the C code converts it to an unsigned long.)

  • find_points.c:3264-3271: modelled by Ratpoints.Sieve.exactEnd (deviation of Ratpoints.Sieve.exactEnd: the double as its bits, with fabs and the comparisons of the C language on them (Ratpoints.Double.fabs, Ratpoints.Double.lt); a Boolean for the int lower; the end returned, for the rp_end that the C code writes through its pointer.)

  • find_points.c:3272-3291: modelled by Ratpoints.Sieve.exactMantissa (deviation of Ratpoints.Sieve.exactMantissa: an integer for the int s while it is computed, and a natural number when it is returned; the lowest set bit by the loop of RP_CTZL (Ratpoints.Sieve.ctz), where gcc and clang take __builtin_ctzl; the mantissa and the exponent returned, for the fields m and s of the rp_end that the C code writes.)

  • find_points.c:3292-3299: modelled by Ratpoints.Sieve.exactEnd (deviation of Ratpoints.Sieve.exactEnd: the double as its bits, with fabs and the comparisons of the C language on them (Ratpoints.Double.fabs, Ratpoints.Double.lt); a Boolean for the int lower; the end returned, for the rp_end that the C code writes through its pointer.)

  • find_points.c:3304-3318: modelled by Ratpoints.Sieve.endForm (deviation of Ratpoints.Sieve.endForm: the form returned as an option, for the pointers M, C and sh through which the C code writes it and the int that says whether it has one; Int64 for the longs, with the division of Int64, which truncates as the C division does, on the non-negative longs LONG_MAX - c and b_high; a Boolean for the int lower; a natural number for the int sh.)

  • find_points.c:3323-3340: modelled by Ratpoints.Sieve.exactBounds (deviation of Ratpoints.Sieve.exactBounds: the search intervals and the bounds as arguments, for the fields domain, num_inter, height and b_high of the arguments, and the array of the bounds returned, for the array that run_setup allocates and exact_bounds fills through its pointer; Int64 for the longs; the conjunction of the tests, whose && makes the form of the upper end only when the lower end has one, as a bind of options, and the forms as the options that Ratpoints.Sieve.endForm returns, for the fields that end_form writes.)

  • find_points.c:3355-3370: modelled by Ratpoints.Sieve.numeratorsToBits (deviation of Ratpoints.Sieve.numeratorsToBits: Int64 for the longs, in two’s complement, the representation on which the and with the mask acts, also on a negative end, and >>> on Int64 the arithmetic shift, for the >> of a negative long, both of which the C standard leaves to the implementation (the representation before C23) and gcc defines so; the arithmetic of Int64 wrapping where that of the longs overflows, which the C standard leaves undefined: the differences of the plain form for an end within a₀ of -2 ^ 63, so beyond 2 ^ 63 - 65 in absolute value, where neither the C code nor Ratpoints.Sieve.sift takes the plain form; the stride k and the residue a₀ of the class converted to Int64; the two ends returned as a pair, for the pointers low and high through which the function reads and writes them; a Boolean for the int split, an argument: clear on the path of the forms of the ends (Ratpoints.Sieve.intervalBits), which exact_bounds gives an interval only for H ≤ 2 ^ 63 - 65, and on the path of the products in 128 bits (Ratpoints.Sieve.intervalBitsExact) set exactly for the heights above 2 ^ 63 - 65.)

  • find_points.c:3381-3406: modelled by Ratpoints.Sieve.intervalBitsExact (deviation of Ratpoints.Sieve.intervalBitsExact: the code and the bits returned as a triple, for the int and the pointers low and high through which the C code writes the bits, the bits (0, 0) with the codes 1 and 2, for which the C code writes nothing; Int64 for the longs, the unsigned long products compared with the height bound converted to a 64-bit word, as the C code compares them; no output under DEBUG.)

  • find_points.c:3410-3434: modelled by Ratpoints.Sieve.intervalBits (deviation of Ratpoints.Sieve.intervalBits: the code and the bits returned as a triple, for the int and the pointers low and high through which the C code writes the bits, the bits (0, 0) with the codes 1 and 2, for which the C code writes nothing; Int64 for the longs, and >>> on Int64 the arithmetic shift, for the >> of a negative long, which the C standard leaves to the implementation and gcc defines so; the arithmetic of Int64 wrapping where that of the longs overflows, which it does not here, by the bound of Ratpoints.Sieve.endForm on the forms of an interval taken inline and the forms of an empty one otherwise; no output under DEBUG.)

  • find_points.c:3435-3440: modelled by Ratpoints.Sieve.sift (deviation of Ratpoints.Sieve.sift: the height bound converted to Int64, which is exact for H < 2 ^ 63, and the denominator too, and the bits back to integers; the bounds of the search intervals an array, for the struct rp_intervals with its pointers bd and end, which sift reaches through the field iv of the sieving thread, which worker_init clears (line 3130) and run_block sets for each block (line 3913; here Ratpoints.Sieve.runBlock, which passes the array of the run on); one call of Ratpoints.Sieve.setRows, for the two calls with the flag shared a constant, between which the pool of threads chooses, which the model does not have; the store of the tables of rows passed and returned, for the arrays sieve of the entries of the arguments, which sift reaches through sieve_list and which keep the rows built for the rest of the run; the end sp1 of the first stage, the entries es and the reciprocals mgs of the first two stages, the entries es3 of the third stage and their reciprocals mgs3 as arguments, for the numbers sp1, sp2 and sp3 that the sieving thread keeps (worker_init), the entries sieve_list[0], …, sieve_list[sp2 - 1], the array magics of the arguments, which _ratpoints_sift0 reads, and the entries sieve_list[sp2], …, sieve_list[sp3 - 1] and the reciprocals magics[sp2], …, magics[sp3 - 1], which fill_checks reads, the cut points of the decision of the block (Ratpoints.Sieve.runBlock); the residues bp and the class cl as values, for the pointers bp_list and cls, and the array offsets of the row offsets of the run as an argument, which the C code reaches through the pointer offset of the class; the thunk of Ratpoints.Sieve.fillChecks, for the table checks of the sieving thread, which fill_checks fills, and its flag stage3_filled, which sift clears; the thunk of the products w, for the flag compute_bc, which sift sets and _ratpoints_check_point clears when it computes the products; the counters cnt passed and returned, for those of the sieving thread, the count sifts one up at the start (line 3461); the delivery r passed and returned, for the pointers info and wk->quit, which worker_init clears, and the count total that sift keeps from zero and returns; the arguments of the run passed explicitly, for the pointer args of the sieving thread (rp-private.h:574), which worker_init sets and through which sift reads them; no pool, slot and stop flag of a thread of the pool, the flag by which the pool of threads tells it to abandon its block (pool, slot, stop, rp-private.h:584, excluded with the threads); natural numbers and integers for the longs; no measurements of the phases (RP_SIFT_TIC, RP_SETUP_TIC and their TOC) and no output under DEBUG.)

  • find_points.c:3442-3488: modelled by Ratpoints.Sieve.sift (deviation of Ratpoints.Sieve.sift: the height bound converted to Int64, which is exact for H < 2 ^ 63, and the denominator too, and the bits back to integers; the bounds of the search intervals an array, for the struct rp_intervals with its pointers bd and end, which sift reaches through the field iv of the sieving thread, which worker_init clears (line 3130) and run_block sets for each block (line 3913; here Ratpoints.Sieve.runBlock, which passes the array of the run on); one call of Ratpoints.Sieve.setRows, for the two calls with the flag shared a constant, between which the pool of threads chooses, which the model does not have; the store of the tables of rows passed and returned, for the arrays sieve of the entries of the arguments, which sift reaches through sieve_list and which keep the rows built for the rest of the run; the end sp1 of the first stage, the entries es and the reciprocals mgs of the first two stages, the entries es3 of the third stage and their reciprocals mgs3 as arguments, for the numbers sp1, sp2 and sp3 that the sieving thread keeps (worker_init), the entries sieve_list[0], …, sieve_list[sp2 - 1], the array magics of the arguments, which _ratpoints_sift0 reads, and the entries sieve_list[sp2], …, sieve_list[sp3 - 1] and the reciprocals magics[sp2], …, magics[sp3 - 1], which fill_checks reads, the cut points of the decision of the block (Ratpoints.Sieve.runBlock); the residues bp and the class cl as values, for the pointers bp_list and cls, and the array offsets of the row offsets of the run as an argument, which the C code reaches through the pointer offset of the class; the thunk of Ratpoints.Sieve.fillChecks, for the table checks of the sieving thread, which fill_checks fills, and its flag stage3_filled, which sift clears; the thunk of the products w, for the flag compute_bc, which sift sets and _ratpoints_check_point clears when it computes the products; the counters cnt passed and returned, for those of the sieving thread, the count sifts one up at the start (line 3461); the delivery r passed and returned, for the pointers info and wk->quit, which worker_init clears, and the count total that sift keeps from zero and returns; the arguments of the run passed explicitly, for the pointer args of the sieving thread (rp-private.h:574), which worker_init sets and through which sift reads them; no pool, slot and stop flag of a thread of the pool, the flag by which the pool of threads tells it to abandon its block (pool, slot, stop, rp-private.h:584, excluded with the threads); natural numbers and integers for the longs; no measurements of the phases (RP_SIFT_TIC, RP_SETUP_TIC and their TOC) and no output under DEBUG.)

  • find_points.c:3490-3521: modelled by Ratpoints.Sieve.sift (deviation of Ratpoints.Sieve.sift: the height bound converted to Int64, which is exact for H < 2 ^ 63, and the denominator too, and the bits back to integers; the bounds of the search intervals an array, for the struct rp_intervals with its pointers bd and end, which sift reaches through the field iv of the sieving thread, which worker_init clears (line 3130) and run_block sets for each block (line 3913; here Ratpoints.Sieve.runBlock, which passes the array of the run on); one call of Ratpoints.Sieve.setRows, for the two calls with the flag shared a constant, between which the pool of threads chooses, which the model does not have; the store of the tables of rows passed and returned, for the arrays sieve of the entries of the arguments, which sift reaches through sieve_list and which keep the rows built for the rest of the run; the end sp1 of the first stage, the entries es and the reciprocals mgs of the first two stages, the entries es3 of the third stage and their reciprocals mgs3 as arguments, for the numbers sp1, sp2 and sp3 that the sieving thread keeps (worker_init), the entries sieve_list[0], …, sieve_list[sp2 - 1], the array magics of the arguments, which _ratpoints_sift0 reads, and the entries sieve_list[sp2], …, sieve_list[sp3 - 1] and the reciprocals magics[sp2], …, magics[sp3 - 1], which fill_checks reads, the cut points of the decision of the block (Ratpoints.Sieve.runBlock); the residues bp and the class cl as values, for the pointers bp_list and cls, and the array offsets of the row offsets of the run as an argument, which the C code reaches through the pointer offset of the class; the thunk of Ratpoints.Sieve.fillChecks, for the table checks of the sieving thread, which fill_checks fills, and its flag stage3_filled, which sift clears; the thunk of the products w, for the flag compute_bc, which sift sets and _ratpoints_check_point clears when it computes the products; the counters cnt passed and returned, for those of the sieving thread, the count sifts one up at the start (line 3461); the delivery r passed and returned, for the pointers info and wk->quit, which worker_init clears, and the count total that sift keeps from zero and returns; the arguments of the run passed explicitly, for the pointer args of the sieving thread (rp-private.h:574), which worker_init sets and through which sift reads them; no pool, slot and stop flag of a thread of the pool, the flag by which the pool of threads tells it to abandon its block (pool, slot, stop, rp-private.h:584, excluded with the threads); natural numbers and integers for the longs; no measurements of the phases (RP_SIFT_TIC, RP_SETUP_TIC and their TOC) and no output under DEBUG.)

  • find_points.c:3522-3554: modelled by Ratpoints.Sieve.buildRows (deviation of Ratpoints.Sieve.buildRows: the specs and the store of the tables of rows of the run passed and returned, for the array of the sieve specs and the arrays sieve of the entries; the empty array for the null pointer of a row not built yet; no lock of the tables (rp_tables_lock, rp_tables_unlock), and the pointer read again plainly, for the acquire load, both for the threads that share the tables of rows, which the model does not have; no measurement of the construction (RP_INIT_TIC, RP_INIT_TOC) and no output under DEBUG.)

  • find_points.c:3555-3561: modelled by Ratpoints.Sieve.sift (deviation of Ratpoints.Sieve.sift: the height bound converted to Int64, which is exact for H < 2 ^ 63, and the denominator too, and the bits back to integers; the bounds of the search intervals an array, for the struct rp_intervals with its pointers bd and end, which sift reaches through the field iv of the sieving thread, which worker_init clears (line 3130) and run_block sets for each block (line 3913; here Ratpoints.Sieve.runBlock, which passes the array of the run on); one call of Ratpoints.Sieve.setRows, for the two calls with the flag shared a constant, between which the pool of threads chooses, which the model does not have; the store of the tables of rows passed and returned, for the arrays sieve of the entries of the arguments, which sift reaches through sieve_list and which keep the rows built for the rest of the run; the end sp1 of the first stage, the entries es and the reciprocals mgs of the first two stages, the entries es3 of the third stage and their reciprocals mgs3 as arguments, for the numbers sp1, sp2 and sp3 that the sieving thread keeps (worker_init), the entries sieve_list[0], …, sieve_list[sp2 - 1], the array magics of the arguments, which _ratpoints_sift0 reads, and the entries sieve_list[sp2], …, sieve_list[sp3 - 1] and the reciprocals magics[sp2], …, magics[sp3 - 1], which fill_checks reads, the cut points of the decision of the block (Ratpoints.Sieve.runBlock); the residues bp and the class cl as values, for the pointers bp_list and cls, and the array offsets of the row offsets of the run as an argument, which the C code reaches through the pointer offset of the class; the thunk of Ratpoints.Sieve.fillChecks, for the table checks of the sieving thread, which fill_checks fills, and its flag stage3_filled, which sift clears; the thunk of the products w, for the flag compute_bc, which sift sets and _ratpoints_check_point clears when it computes the products; the counters cnt passed and returned, for those of the sieving thread, the count sifts one up at the start (line 3461); the delivery r passed and returned, for the pointers info and wk->quit, which worker_init clears, and the count total that sift keeps from zero and returns; the arguments of the run passed explicitly, for the pointer args of the sieving thread (rp-private.h:574), which worker_init sets and through which sift reads them; no pool, slot and stop flag of a thread of the pool, the flag by which the pool of threads tells it to abandon its block (pool, slot, stop, rp-private.h:584, excluded with the threads); natural numbers and integers for the longs; no measurements of the phases (RP_SIFT_TIC, RP_SETUP_TIC and their TOC) and no output under DEBUG.)

  • find_points.c:3563-3612: modelled by Ratpoints.Sieve.siftBits (deviation of Ratpoints.Sieve.siftBits: a function of its own for the bits of one interval of the numerators, the part of the loop over the intervals of sift after the set-up; the size A of the pieces as an argument, for args->array_size (line 3571), which sift reads through the pointer args of the sieving thread; natural numbers and integers for the longs, the word numbers and the masks by the division and the remainder, rounding down, by Ratpoints.rbaLength, for the shift by RBA_SHIFT and the mask by RBA_LENGTH - 1 (with Ratpoints.rbaLength = 2 ^ Ratpoints.rbaShift), which gcc makes the floor division and the Euclidean remainder on a negative long too, the first bits of the bit arrays staying longs for the bits of a height bound below 2 ^ 63 (Ratpoints.Sieve.neg_two_pow_le_rbaLength_mul_ediv, Ratpoints.Sieve.rbaLength_mul_ediv_add_one_le_two_pow); the delivery r passed and returned, for the pointers info and wk->quit and the count total that sift keeps from zero and returns, and the counters cnt passed and returned, for those of the sieving thread; no test of the flag stop of a thread of the pool after a piece (line 3610), which is null on the calling thread (line 5129, with the pool excluded with the threads), and no measurement (RP_SIFT_TOC) on the return at a stop.)

  • find_points.c:3613-3617: modelled by Ratpoints.Sieve.sift (deviation of Ratpoints.Sieve.sift: the height bound converted to Int64, which is exact for H < 2 ^ 63, and the denominator too, and the bits back to integers; the bounds of the search intervals an array, for the struct rp_intervals with its pointers bd and end, which sift reaches through the field iv of the sieving thread, which worker_init clears (line 3130) and run_block sets for each block (line 3913; here Ratpoints.Sieve.runBlock, which passes the array of the run on); one call of Ratpoints.Sieve.setRows, for the two calls with the flag shared a constant, between which the pool of threads chooses, which the model does not have; the store of the tables of rows passed and returned, for the arrays sieve of the entries of the arguments, which sift reaches through sieve_list and which keep the rows built for the rest of the run; the end sp1 of the first stage, the entries es and the reciprocals mgs of the first two stages, the entries es3 of the third stage and their reciprocals mgs3 as arguments, for the numbers sp1, sp2 and sp3 that the sieving thread keeps (worker_init), the entries sieve_list[0], …, sieve_list[sp2 - 1], the array magics of the arguments, which _ratpoints_sift0 reads, and the entries sieve_list[sp2], …, sieve_list[sp3 - 1] and the reciprocals magics[sp2], …, magics[sp3 - 1], which fill_checks reads, the cut points of the decision of the block (Ratpoints.Sieve.runBlock); the residues bp and the class cl as values, for the pointers bp_list and cls, and the array offsets of the row offsets of the run as an argument, which the C code reaches through the pointer offset of the class; the thunk of Ratpoints.Sieve.fillChecks, for the table checks of the sieving thread, which fill_checks fills, and its flag stage3_filled, which sift clears; the thunk of the products w, for the flag compute_bc, which sift sets and _ratpoints_check_point clears when it computes the products; the counters cnt passed and returned, for those of the sieving thread, the count sifts one up at the start (line 3461); the delivery r passed and returned, for the pointers info and wk->quit, which worker_init clears, and the count total that sift keeps from zero and returns; the arguments of the run passed explicitly, for the pointer args of the sieving thread (rp-private.h:574), which worker_init sets and through which sift reads them; no pool, slot and stop flag of a thread of the pool, the flag by which the pool of threads tells it to abandon its block (pool, slot, stop, rp-private.h:584, excluded with the threads); natural numbers and integers for the longs; no measurements of the phases (RP_SIFT_TIC, RP_SETUP_TIC and their TOC) and no output under DEBUG.)

  • find_points.c:3639-3679: modelled by Ratpoints.Sieve.fillBpList (deviation of Ratpoints.Sieve.fillBpList: a list, made by a map over the entries and their reciprocals (List.zipWith) in the branch that b chooses and returned, for the array bp_list that the loops over the positions 0, …, sp2 - 1 of sieve_list and magics fill through the pointer argument; the entries of the first two stages and their reciprocals as arguments, for wk->sp2 and the arrays sieve_list and magics of the arguments; natural numbers for the longs, the products natural numbers for the longs that RP_MULMOD converts to unsigned longs, at most Ratpoints.mulModLimit in the first branch (Ratpoints.mul_le_mulModLimit_of_le_div) and below 2 ^ 63 in the others (Ratpoints.mul_lt_two_pow_63); no measurement of its time (RP_BP_TIC, RP_BP_TOC).)

  • find_points.c:3725-3728: modelled by Ratpoints.Sieve.Shape (deviation of Ratpoints.Sieve.Shape: an inductive type with the data of each shape, for the constant shape and the fields of rp_run that the shapes read, with these exceptions: the forbidden divisors as lists, for forb_ba and forbidden with no count nfb, a list having its length; the tables of the Jacobi test as an option, for ji, jtab and fast_jacobi; with the words, the bit RATPOINTS_USE_JACOBI of the flags and the leading coefficient args->cof[args->degree], which run_block reads through the field args, the run taking the rest of what it reads of the arguments as its own arguments (Ratpoints.Sieve.sieveRun); no copies of use_c_long and lcf_long, which only jacobi1 reads (Ratpoints.Sieve.jacobi); the segments and the blocks (Ratpoints.Sieve.BlockPlan) and the counters and the decisions of the correction of the moduli (Ratpoints.Sieve.Correction) structures of their own; the bounds of the search intervals (the struct iv of the run, Ratpoints.Sieve.runSetup), the classes with their row offsets and den_bits passed to the run apart (Ratpoints.Sieve.sieveRun).)

  • find_points.c:3729-3731: modelled by Ratpoints.blocksWanted

  • find_points.c:3732-3734: modelled by Ratpoints.blockMin

  • find_points.c:3736-3749: modelled by Ratpoints.Sieve.Shape (deviation of Ratpoints.Sieve.Shape: an inductive type with the data of each shape, for the constant shape and the fields of rp_run that the shapes read, with these exceptions: the forbidden divisors as lists, for forb_ba and forbidden with no count nfb, a list having its length; the tables of the Jacobi test as an option, for ji, jtab and fast_jacobi; with the words, the bit RATPOINTS_USE_JACOBI of the flags and the leading coefficient args->cof[args->degree], which run_block reads through the field args, the run taking the rest of what it reads of the arguments as its own arguments (Ratpoints.Sieve.sieveRun); no copies of use_c_long and lcf_long, which only jacobi1 reads (Ratpoints.Sieve.jacobi); the segments and the blocks (Ratpoints.Sieve.BlockPlan) and the counters and the decisions of the correction of the moduli (Ratpoints.Sieve.Correction) structures of their own; the bounds of the search intervals (the struct iv of the run, Ratpoints.Sieve.runSetup), the classes with their row offsets and den_bits passed to the run apart (Ratpoints.Sieve.sieveRun).)

  • find_points.c:3750-3754: modelled by Ratpoints.Sieve.BlockPlan (deviation of Ratpoints.Sieve.BlockPlan: the segments as an array of pairs, for the pointers seg_lo and seg_hi; the first blocks with the number of the blocks at the end of the array, for seg_block and nblocks, which the C code keeps apart with the same value; no count nseg of the segments, an array having its size; natural numbers for the longs.)

  • find_points.c:3755-3762: modelled by Ratpoints.Sieve.Correction (deviation of Ratpoints.Sieve.Correction: the decisions an array of structures, for the three arrays dec_block, dec_sp2 and dec_sp3 and their count ndec; the fields sp2, sp3 and adapt_at of the arguments, which adapt_primes writes and run_fold reads, kept here, since they are read only within the run, by run_fold and adapt_primes, after which line 5163 overwrites sp2 and sp3 with the ends of the last block folded; natural numbers for the longs and a UInt64 for the unsigned long.)

  • find_points.c:3763-3763: modelled by Ratpoints.Sieve.Shape (deviation of Ratpoints.Sieve.Shape: an inductive type with the data of each shape, for the constant shape and the fields of rp_run that the shapes read, with these exceptions: the forbidden divisors as lists, for forb_ba and forbidden with no count nfb, a list having its length; the tables of the Jacobi test as an option, for ji, jtab and fast_jacobi; with the words, the bit RATPOINTS_USE_JACOBI of the flags and the leading coefficient args->cof[args->degree], which run_block reads through the field args, the run taking the rest of what it reads of the arguments as its own arguments (Ratpoints.Sieve.sieveRun); no copies of use_c_long and lcf_long, which only jacobi1 reads (Ratpoints.Sieve.jacobi); the segments and the blocks (Ratpoints.Sieve.BlockPlan) and the counters and the decisions of the correction of the moduli (Ratpoints.Sieve.Correction) structures of their own; the bounds of the search intervals (the struct iv of the run, Ratpoints.Sieve.runSetup), the classes with their row offsets and den_bits passed to the run apart (Ratpoints.Sieve.sieveRun).)

  • find_points.c:3766-3774: modelled by Ratpoints.Sieve.floorSqrt (deviation of Ratpoints.Sieve.floorSqrt: the exact square root of the natural numbers (Nat.sqrt), for the square root in double corrected by a step either way; natural numbers for the longs, so that 0 is the only case n < 1.)

  • find_points.c:3778-3806: modelled by Ratpoints.Sieve.runSetup (deviation of Ratpoints.Sieve.runSetup: the shape returned with its data, for the fields of the run that run_setup fills, and Booleans and an option for the bits RATPOINTS_USE_SQUARES, RATPOINTS_USE_SQUARES1, RATPOINTS_CHECK_DENOM and RATPOINTS_USE_JACOBI of the flags; the bounds of the search intervals returned as an array with the shape, for the struct iv of the run with its pointers bd and end; the search intervals, the height bound and the largest denominator as arguments, for the fields of the arguments that exact_bounds reads; no count nfb, a list having its length; no copies of use_c_long and lcf_long, which only jacobi1 reads (Ratpoints.Sieve.jacobi); the segments and the blocks made by Ratpoints.Sieve.Shape.blockPlan, and the counters and the decisions of the correction by Ratpoints.Sieve.Correction.start; no failure for lack of memory.)

  • find_points.c:3807-3811: excluded (memory): the arrays of the segments of the run (their bounds and first blocks) in one allocation, which fails only for lack of memory, and before it the pointers to the other two arrays that run_clear frees set to NULL

  • find_points.c:3812-3837: modelled by Ratpoints.Sieve.Shape.segments (deviation of Ratpoints.Sieve.Shape.segments: the segments as an array of pairs, for the arrays seg_lo and seg_hi of the run; quotients by 64 for the shifts by LONG_SHIFT; natural numbers for the longs, the steps of a segment counted only when lo ≤ hi, as the C code counts them; the count of the segments read from the shape, for nseg, which run_setup counts before (line 3794).)

  • find_points.c:3838-3842: modelled by Ratpoints.Sieve.blockLength (deviation of Ratpoints.Sieve.blockLength: the conditional compilation #ifdef RP_BLOCK_LEN a constant of type Option Nat (Ratpoints.blockLen), none in the default build.)

  • find_points.c:3843-3850: modelled by Ratpoints.Sieve.Shape.blockPlan (deviation of Ratpoints.Sieve.Shape.blockPlan: the blocks returned as a structure (Ratpoints.Sieve.BlockPlan), for the fields of the run that run_setup fills; natural numbers for the longs.)

  • find_points.c:3853-3856: modelled by Ratpoints.Sieve.Correction.start (deviation of Ratpoints.Sieve.Correction.start: the state returned, for the fields of the run that run_setup sets.)

  • find_points.c:3857-3860: excluded (memory): the arrays of the decisions of the correction of the moduli between the blocks in one allocation, which fails only for lack of memory

  • find_points.c:3861-3863: modelled by Ratpoints.Sieve.Correction.start (deviation of Ratpoints.Sieve.Correction.start: the state returned, for the fields of the run that run_setup sets.)

  • find_points.c:3866-3868: excluded (memory): the array of the search intervals of the run on the heap, whose allocation fails only for lack of memory

  • find_points.c:3869-3870: modelled by Ratpoints.Sieve.runSetup (deviation of Ratpoints.Sieve.runSetup: the shape returned with its data, for the fields of the run that run_setup fills, and Booleans and an option for the bits RATPOINTS_USE_SQUARES, RATPOINTS_USE_SQUARES1, RATPOINTS_CHECK_DENOM and RATPOINTS_USE_JACOBI of the flags; the bounds of the search intervals returned as an array with the shape, for the struct iv of the run with its pointers bd and end; the search intervals, the height bound and the largest denominator as arguments, for the fields of the arguments that exact_bounds reads; no count nfb, a list having its length; no copies of use_c_long and lcf_long, which only jacobi1 reads (Ratpoints.Sieve.jacobi); the segments and the blocks made by Ratpoints.Sieve.Shape.blockPlan, and the counters and the decisions of the correction by Ratpoints.Sieve.Correction.start; no failure for lack of memory.)

  • find_points.c:3871-3875: excluded (instrumentation): the report of the loop over the denominators under DEBUG at the end of run_setup: its shape, its segments and its blocks

  • find_points.c:3876-3877: modelled by Ratpoints.Sieve.runSetup (deviation of Ratpoints.Sieve.runSetup: the shape returned with its data, for the fields of the run that run_setup fills, and Booleans and an option for the bits RATPOINTS_USE_SQUARES, RATPOINTS_USE_SQUARES1, RATPOINTS_CHECK_DENOM and RATPOINTS_USE_JACOBI of the flags; the bounds of the search intervals returned as an array with the shape, for the struct iv of the run with its pointers bd and end; the search intervals, the height bound and the largest denominator as arguments, for the fields of the arguments that exact_bounds reads; no count nfb, a list having its length; no copies of use_c_long and lcf_long, which only jacobi1 reads (Ratpoints.Sieve.jacobi); the segments and the blocks made by Ratpoints.Sieve.Shape.blockPlan, and the counters and the decisions of the correction by Ratpoints.Sieve.Correction.start; no failure for lack of memory.)

  • find_points.c:3879-3883: excluded (memory): run_clear, which releases the arrays of the run

  • find_points.c:3889-3898: modelled by Ratpoints.Sieve.runBlock (deviation of Ratpoints.Sieve.runBlock: the decision’s entries and reciprocals cut as lists for each block, for the numbers sp2 and sp3 that the sieving thread keeps and through which sift and fill_bp_list read the arrays sieve_list and magics; the report returned with the delivery and the store, for the fields of the sieving thread that worker_stat copies into it after the block; the counters and the index of the decision, which worker_init clears before the run (lines 3127-3128), set only here, for each block (lines 3911 and 3914-3915), before they are read; the arguments of the run passed explicitly, for the fields of the run and of the arguments that run_block reads; the delivery r passed and returned, for the pointers info and wk->quit and the count total that run_block keeps from zero and returns; the array bp_list of sp3_max entries on the stack, of which fill_bp_list fills the first sp2, a list made by Ratpoints.Sieve.siftDen; natural numbers for the longs.)

  • find_points.c:3900-3904: modelled by Ratpoints.Sieve.BlockPlan.steps (deviation of Ratpoints.Sieve.BlockPlan.steps: the segment and the steps returned, for the locals of run_block; natural numbers for the longs, the difference hi - a truncated at 0, where the C code compares a long that is not negative for a block of the run.)

  • find_points.c:3908-3910: modelled by Ratpoints.Sieve.findDecision (deviation of Ratpoints.Sieve.findDecision: the decisions an array of structures (Ratpoints.Sieve.Decision), for the three arrays dec_block, dec_sp2 and dec_sp3 and their count ndec, which the C code reads with an acquire load, for the threads that publish their decisions (RP_ACQUIRE), here a plain read; the index returned, for the local d; natural numbers for the longs.)

  • find_points.c:3911-3911: modelled by Ratpoints.Sieve.runBlock (deviation of Ratpoints.Sieve.runBlock: the decision’s entries and reciprocals cut as lists for each block, for the numbers sp2 and sp3 that the sieving thread keeps and through which sift and fill_bp_list read the arrays sieve_list and magics; the report returned with the delivery and the store, for the fields of the sieving thread that worker_stat copies into it after the block; the counters and the index of the decision, which worker_init clears before the run (lines 3127-3128), set only here, for each block (lines 3911 and 3914-3915), before they are read; the arguments of the run passed explicitly, for the fields of the run and of the arguments that run_block reads; the delivery r passed and returned, for the pointers info and wk->quit and the count total that run_block keeps from zero and returns; the array bp_list of sp3_max entries on the stack, of which fill_bp_list fills the first sp2, a list made by Ratpoints.Sieve.siftDen; natural numbers for the longs.)

  • find_points.c:3912-3912: modelled by Ratpoints.Sieve.findDecision (deviation of Ratpoints.Sieve.findDecision: the decisions an array of structures (Ratpoints.Sieve.Decision), for the three arrays dec_block, dec_sp2 and dec_sp3 and their count ndec, which the C code reads with an acquire load, for the threads that publish their decisions (RP_ACQUIRE), here a plain read; the index returned, for the local d; natural numbers for the longs.)

  • find_points.c:3913-3915: modelled by Ratpoints.Sieve.runBlock (deviation of Ratpoints.Sieve.runBlock: the decision’s entries and reciprocals cut as lists for each block, for the numbers sp2 and sp3 that the sieving thread keeps and through which sift and fill_bp_list read the arrays sieve_list and magics; the report returned with the delivery and the store, for the fields of the sieving thread that worker_stat copies into it after the block; the counters and the index of the decision, which worker_init clears before the run (lines 3127-3128), set only here, for each block (lines 3911 and 3914-3915), before they are read; the arguments of the run passed explicitly, for the fields of the run and of the arguments that run_block reads; the delivery r passed and returned, for the pointers info and wk->quit and the count total that run_block keeps from zero and returns; the array bp_list of sp3_max entries on the stack, of which fill_bp_list fills the first sp2, a list made by Ratpoints.Sieve.siftDen; natural numbers for the longs.)

  • find_points.c:3917-3918: modelled by Ratpoints.Sieve.Shape.blockLoop (deviation of Ratpoints.Sieve.Shape.blockLoop: a function of its own for the switch of run_block over the shapes, the step an argument, for the two lines of each shape that sift a denominator (Ratpoints.Sieve.siftDen); the first and last words of the run, which the masks of the word shape compare with, read from the first segment of plan, as the C code reads seg_lo[0] and seg_hi[0]; natural numbers for the longs.)

  • find_points.c:3919-3925: modelled by Ratpoints.Sieve.squaresBlock (deviation of Ratpoints.Sieve.squaresBlock: the denominator sifted by the argument step, for the two calls of each shape (Ratpoints.Sieve.siftDen); the pattern of the class read as its one word, for EXT0(cl->bits); the state of the block passed and returned (Ratpoints.Sieve.BlockState); natural numbers for the longs, the denominators k ^ 2 being at most b_high and so longs for a long b_high (Ratpoints.Sieve.fitsLong_of_mem_squaresDens); no output under DEBUG.)

  • find_points.c:3926-3927: modelled by Ratpoints.Sieve.siftDen (deviation of Ratpoints.Sieve.siftDen: a function of its own for the two calls that each shape makes for a denominator, the residues a list for the array bp_list, which sift reads through its pointer; the state of the block passed and returned (Ratpoints.Sieve.BlockState), for the pointers info and wk->quit, the count total that run_block keeps, the arrays sieve of the entries and the counters of the sieving thread.)

  • find_points.c:3928-3935: modelled by Ratpoints.Sieve.squaresBlock (deviation of Ratpoints.Sieve.squaresBlock: the denominator sifted by the argument step, for the two calls of each shape (Ratpoints.Sieve.siftDen); the pattern of the class read as its one word, for EXT0(cl->bits); the state of the block passed and returned (Ratpoints.Sieve.BlockState); natural numbers for the longs, the denominators k ^ 2 being at most b_high and so longs for a long b_high (Ratpoints.Sieve.fitsLong_of_mem_squaresDens); no output under DEBUG.)

  • find_points.c:3936-3936: modelled by Ratpoints.Sieve.Shape.blockLoop (deviation of Ratpoints.Sieve.Shape.blockLoop: a function of its own for the switch of run_block over the shapes, the step an argument, for the two lines of each shape that sift a denominator (Ratpoints.Sieve.siftDen); the first and last words of the run, which the masks of the word shape compare with, read from the first segment of plan, as the C code reads seg_lo[0] and seg_hi[0]; natural numbers for the longs.)

  • find_points.c:3937-3943: modelled by Ratpoints.Sieve.squares1Block (deviation of Ratpoints.Sieve.squares1Block: the denominator sifted by the argument step, for the two calls of each shape (Ratpoints.Sieve.siftDen); the valuation test a function of its own; the pattern of the class read as its one word; the state of the block passed and returned (Ratpoints.Sieve.BlockState); natural numbers for the longs, the denominators dv k ^ 2 being at most b_high and so longs for a long b_high (Ratpoints.Sieve.fitsLong_of_mem_squares1Dens); no output under DEBUG.)

  • find_points.c:3944-3953: modelled by Ratpoints.Sieve.denInfoTest (deviation of Ratpoints.Sieve.denInfoTest: the test returned, for the flag flag; natural numbers for the ints and longs.)

  • find_points.c:3954-3954: modelled by Ratpoints.Sieve.squares1Block (deviation of Ratpoints.Sieve.squares1Block: the denominator sifted by the argument step, for the two calls of each shape (Ratpoints.Sieve.siftDen); the valuation test a function of its own; the pattern of the class read as its one word; the state of the block passed and returned (Ratpoints.Sieve.BlockState); natural numbers for the longs, the denominators dv k ^ 2 being at most b_high and so longs for a long b_high (Ratpoints.Sieve.fitsLong_of_mem_squares1Dens); no output under DEBUG.)

  • find_points.c:3955-3956: modelled by Ratpoints.Sieve.siftDen (deviation of Ratpoints.Sieve.siftDen: a function of its own for the two calls that each shape makes for a denominator, the residues a list for the array bp_list, which sift reads through its pointer; the state of the block passed and returned (Ratpoints.Sieve.BlockState), for the pointers info and wk->quit, the count total that run_block keeps, the arrays sieve of the entries and the counters of the sieving thread.)

  • find_points.c:3957-3965: modelled by Ratpoints.Sieve.squares1Block (deviation of Ratpoints.Sieve.squares1Block: the denominator sifted by the argument step, for the two calls of each shape (Ratpoints.Sieve.siftDen); the valuation test a function of its own; the pattern of the class read as its one word; the state of the block passed and returned (Ratpoints.Sieve.BlockState); natural numbers for the longs, the denominators dv k ^ 2 being at most b_high and so longs for a long b_high (Ratpoints.Sieve.fitsLong_of_mem_squares1Dens); no output under DEBUG.)

  • find_points.c:3966-3966: modelled by Ratpoints.Sieve.Shape.blockLoop (deviation of Ratpoints.Sieve.Shape.blockLoop: a function of its own for the switch of run_block over the shapes, the step an argument, for the two lines of each shape that sift a denominator (Ratpoints.Sieve.siftDen); the first and last words of the run, which the masks of the word shape compare with, read from the first segment of plan, as the C code reads seg_lo[0] and seg_hi[0]; natural numbers for the longs.)

  • find_points.c:3967-3980: modelled by Ratpoints.Sieve.wordsBlock (deviation of Ratpoints.Sieve.wordsBlock: the denominator sifted by the argument step, for the two calls of each shape, and the tests of the word shape the argument test (Ratpoints.Sieve.wordsTest); the forbidden divisors an array, for the pointer run->forb_ba and their count nfb; the product 64 w for the shift by LONG_SHIFT; the state of the block passed and returned (Ratpoints.Sieve.BlockState); natural numbers for the longs, the products 64 w and the denominators being at most b_high and so longs for a long b_high (Ratpoints.Sieve.fitsLong_of_mem_wordsDens).)

  • find_points.c:3981-3981: modelled by Ratpoints.Sieve.forbStarts (deviation of Ratpoints.Sieve.forbStarts: indices into the words of the divisors, for the pointers cur into the arrays from start to end; a Boolean for the int small; natural numbers for the longs.)

  • find_points.c:3982-3982: modelled by Ratpoints.Sieve.wordsBlock (deviation of Ratpoints.Sieve.wordsBlock: the denominator sifted by the argument step, for the two calls of each shape, and the tests of the word shape the argument test (Ratpoints.Sieve.wordsTest); the forbidden divisors an array, for the pointer run->forb_ba and their count nfb; the product 64 w for the shift by LONG_SHIFT; the state of the block passed and returned (Ratpoints.Sieve.BlockState); natural numbers for the longs, the products 64 w and the denominators being at most b_high and so longs for a long b_high (Ratpoints.Sieve.fitsLong_of_mem_wordsDens).)

  • find_points.c:3983-3988: modelled by Ratpoints.Sieve.forbStarts (deviation of Ratpoints.Sieve.forbStarts: indices into the words of the divisors, for the pointers cur into the arrays from start to end; a Boolean for the int small; natural numbers for the longs.)

  • find_points.c:3989-3989: modelled by Ratpoints.Sieve.wordsBlock (deviation of Ratpoints.Sieve.wordsBlock: the denominator sifted by the argument step, for the two calls of each shape, and the tests of the word shape the argument test (Ratpoints.Sieve.wordsTest); the forbidden divisors an array, for the pointer run->forb_ba and their count nfb; the product 64 w for the shift by LONG_SHIFT; the state of the block passed and returned (Ratpoints.Sieve.BlockState); natural numbers for the longs, the products 64 w and the denominators being at most b_high and so longs for a long b_high (Ratpoints.Sieve.fitsLong_of_mem_wordsDens).)

  • find_points.c:3990-3990: modelled by Ratpoints.Sieve.denWord (deviation of Ratpoints.Sieve.denWord: indices into the words of the divisors, for the pointers cur, and the end of the words of a divisor its prime p, for the pointer end; the remainders by 64 for the masks by LONG_MASK; the positions returned with the word; natural numbers for the longs; no output under DEBUG.)

  • find_points.c:3991-3992: modelled by Ratpoints.Sieve.wordsBlock (deviation of Ratpoints.Sieve.wordsBlock: the denominator sifted by the argument step, for the two calls of each shape, and the tests of the word shape the argument test (Ratpoints.Sieve.wordsTest); the forbidden divisors an array, for the pointer run->forb_ba and their count nfb; the product 64 w for the shift by LONG_SHIFT; the state of the block passed and returned (Ratpoints.Sieve.BlockState); natural numbers for the longs, the products 64 w and the denominators being at most b_high and so longs for a long b_high (Ratpoints.Sieve.fitsLong_of_mem_wordsDens).)

  • find_points.c:3993-4006: modelled by Ratpoints.Sieve.denWord (deviation of Ratpoints.Sieve.denWord: indices into the words of the divisors, for the pointers cur, and the end of the words of a divisor its prime p, for the pointer end; the remainders by 64 for the masks by LONG_MASK; the positions returned with the word; natural numbers for the longs; no output under DEBUG.)

  • find_points.c:4007-4009: modelled by Ratpoints.Sieve.walkDens (deviation of Ratpoints.Sieve.walkDens: the denominator sifted by the argument step, for the two calls of each shape (Ratpoints.Sieve.siftDen), and the tests of the word shape the argument test, for the code of Ratpoints.Sieve.wordsTest in the loop; the lowest set bit by the loop of RP_CTZL (Ratpoints.Sieve.ctz); the class of the denominator read by Ratpoints.Sieve.siftDen; the state of the block passed and returned (Ratpoints.Sieve.BlockState); natural numbers for the longs, the denominators base + j being at most b_high and so longs for a long b_high (Ratpoints.Sieve.fitsLong_of_mem_wordsDens); no output under DEBUG.)

  • find_points.c:4010-4011: modelled by Ratpoints.Sieve.wordsTest (deviation of Ratpoints.Sieve.wordsTest: the binary algorithm of jacobi also where the run calls jacobi1 on the long lcf_long (Ratpoints.Sieve.jacobi); bit v_p(b) of the mask of a natural number, false beyond its bits (Nat.testBit), for the shift and the mask of the unsigned long; the test returned, where the loop goes on to the sieve or to the next denominator; natural numbers for the longs; no output under DEBUG.)

  • find_points.c:4012-4012: modelled by Ratpoints.Sieve.walkDens (deviation of Ratpoints.Sieve.walkDens: the denominator sifted by the argument step, for the two calls of each shape (Ratpoints.Sieve.siftDen), and the tests of the word shape the argument test, for the code of Ratpoints.Sieve.wordsTest in the loop; the lowest set bit by the loop of RP_CTZL (Ratpoints.Sieve.ctz); the class of the denominator read by Ratpoints.Sieve.siftDen; the state of the block passed and returned (Ratpoints.Sieve.BlockState); natural numbers for the longs, the denominators base + j being at most b_high and so longs for a long b_high (Ratpoints.Sieve.fitsLong_of_mem_wordsDens); no output under DEBUG.)

  • find_points.c:4013-4041: modelled by Ratpoints.Sieve.wordsTest (deviation of Ratpoints.Sieve.wordsTest: the binary algorithm of jacobi also where the run calls jacobi1 on the long lcf_long (Ratpoints.Sieve.jacobi); bit v_p(b) of the mask of a natural number, false beyond its bits (Nat.testBit), for the shift and the mask of the unsigned long; the test returned, where the loop goes on to the sieve or to the next denominator; natural numbers for the longs; no output under DEBUG.)

  • find_points.c:4042-4043: modelled by Ratpoints.Sieve.siftDen (deviation of Ratpoints.Sieve.siftDen: a function of its own for the two calls that each shape makes for a denominator, the residues a list for the array bp_list, which sift reads through its pointer; the state of the block passed and returned (Ratpoints.Sieve.BlockState), for the pointers info and wk->quit, the count total that run_block keeps, the arrays sieve of the entries and the counters of the sieving thread.)

  • find_points.c:4044-4053: modelled by Ratpoints.Sieve.walkDens (deviation of Ratpoints.Sieve.walkDens: the denominator sifted by the argument step, for the two calls of each shape (Ratpoints.Sieve.siftDen), and the tests of the word shape the argument test, for the code of Ratpoints.Sieve.wordsTest in the loop; the lowest set bit by the loop of RP_CTZL (Ratpoints.Sieve.ctz); the class of the denominator read by Ratpoints.Sieve.siftDen; the state of the block passed and returned (Ratpoints.Sieve.BlockState); natural numbers for the longs, the denominators base + j being at most b_high and so longs for a long b_high (Ratpoints.Sieve.fitsLong_of_mem_wordsDens); no output under DEBUG.)

  • find_points.c:4054-4058: modelled by Ratpoints.Sieve.wordsBlock (deviation of Ratpoints.Sieve.wordsBlock: the denominator sifted by the argument step, for the two calls of each shape, and the tests of the word shape the argument test (Ratpoints.Sieve.wordsTest); the forbidden divisors an array, for the pointer run->forb_ba and their count nfb; the product 64 w for the shift by LONG_SHIFT; the state of the block passed and returned (Ratpoints.Sieve.BlockState); natural numbers for the longs, the products 64 w and the denominators being at most b_high and so longs for a long b_high (Ratpoints.Sieve.fitsLong_of_mem_wordsDens).)

  • find_points.c:4059-4059: modelled by Ratpoints.Sieve.Shape.blockLoop (deviation of Ratpoints.Sieve.Shape.blockLoop: a function of its own for the switch of run_block over the shapes, the step an argument, for the two lines of each shape that sift a denominator (Ratpoints.Sieve.siftDen); the first and last words of the run, which the masks of the word shape compare with, read from the first segment of plan, as the C code reads seg_lo[0] and seg_hi[0]; natural numbers for the longs.)

  • find_points.c:4060-4065: modelled by Ratpoints.Sieve.allBlock (deviation of Ratpoints.Sieve.allBlock: the denominator sifted by the argument step, for the two calls of each shape (Ratpoints.Sieve.siftDen); the pattern of the class read as its one word; the state of the block passed and returned (Ratpoints.Sieve.BlockState); natural numbers for the longs; no output under DEBUG.)

  • find_points.c:4066-4067: modelled by Ratpoints.Sieve.siftDen (deviation of Ratpoints.Sieve.siftDen: a function of its own for the two calls that each shape makes for a denominator, the residues a list for the array bp_list, which sift reads through its pointer; the state of the block passed and returned (Ratpoints.Sieve.BlockState), for the pointers info and wk->quit, the count total that run_block keeps, the arrays sieve of the entries and the counters of the sieving thread.)

  • find_points.c:4068-4074: modelled by Ratpoints.Sieve.allBlock (deviation of Ratpoints.Sieve.allBlock: the denominator sifted by the argument step, for the two calls of each shape (Ratpoints.Sieve.siftDen); the pattern of the class read as its one word; the state of the block passed and returned (Ratpoints.Sieve.BlockState); natural numbers for the longs; no output under DEBUG.)

  • find_points.c:4075-4076: modelled by Ratpoints.Sieve.Shape.blockLoop (deviation of Ratpoints.Sieve.Shape.blockLoop: a function of its own for the switch of run_block over the shapes, the step an argument, for the two lines of each shape that sift a denominator (Ratpoints.Sieve.siftDen); the first and last words of the run, which the masks of the word shape compare with, read from the first segment of plan, as the C code reads seg_lo[0] and seg_hi[0]; natural numbers for the longs.)

  • find_points.c:4077-4078: modelled by Ratpoints.Sieve.runBlock (deviation of Ratpoints.Sieve.runBlock: the decision’s entries and reciprocals cut as lists for each block, for the numbers sp2 and sp3 that the sieving thread keeps and through which sift and fill_bp_list read the arrays sieve_list and magics; the report returned with the delivery and the store, for the fields of the sieving thread that worker_stat copies into it after the block; the counters and the index of the decision, which worker_init clears before the run (lines 3127-3128), set only here, for each block (lines 3911 and 3914-3915), before they are read; the arguments of the run passed explicitly, for the fields of the run and of the arguments that run_block reads; the delivery r passed and returned, for the pointers info and wk->quit and the count total that run_block keeps from zero and returns; the array bp_list of sp3_max entries on the stack, of which fill_bp_list fills the first sp2, a list made by Ratpoints.Sieve.siftDen; natural numbers for the longs.)

  • find_points.c:4082-4086: modelled by Ratpoints.Sieve.BlockStat (deviation of Ratpoints.Sieve.BlockStat: the counters as a structure, for the six fields; natural numbers for the longs.)

  • find_points.c:4088-4093: modelled by Ratpoints.Sieve.runBlock (deviation of Ratpoints.Sieve.runBlock: the decision’s entries and reciprocals cut as lists for each block, for the numbers sp2 and sp3 that the sieving thread keeps and through which sift and fill_bp_list read the arrays sieve_list and magics; the report returned with the delivery and the store, for the fields of the sieving thread that worker_stat copies into it after the block; the counters and the index of the decision, which worker_init clears before the run (lines 3127-3128), set only here, for each block (lines 3911 and 3914-3915), before they are read; the arguments of the run passed explicitly, for the fields of the run and of the arguments that run_block reads; the delivery r passed and returned, for the pointers info and wk->quit and the count total that run_block keeps from zero and returns; the array bp_list of sp3_max entries on the stack, of which fill_bp_list fills the first sp2, a list made by Ratpoints.Sieve.siftDen; natural numbers for the longs.)

  • find_points.c:4102-4106: modelled by Ratpoints.Sieve.runFold (deviation of Ratpoints.Sieve.runFold: the state of the correction passed and returned (Ratpoints.Sieve.Correction), for the fields of the run and of the arguments; the decision appended to the array, for the store into the three arrays and the release store of their count (RP_PUBLISH), for the threads that read them, here a plain store; natural numbers for the longs.)

  • find_points.c:4107-4113: modelled by Ratpoints.Sieve.RunCounts.fold (deviation of Ratpoints.Sieve.RunCounts.fold: a function of its own for this part of run_fold; the end sp2 passed, for the entry dec_sp2[st->dec] that run_fold reads; the sums of UInt64s, wrapping as the unsigned longs do.)

  • find_points.c:4114-4127: modelled by Ratpoints.Sieve.runFold (deviation of Ratpoints.Sieve.runFold: the state of the correction passed and returned (Ratpoints.Sieve.Correction), for the fields of the run and of the arguments; the decision appended to the array, for the store into the three arrays and the release store of their count (RP_PUBLISH), for the threads that read them, here a plain store; natural numbers for the longs.)

  • find_points.c:4129-4519: excluded (threads): the pool of threads (the lock of the tables of rows, the workers, the collection of the points of a block, run_threaded) and its stubs for a build without threads; the pool sieves the blocks apart and delivers them in their order, a block not starting before the block RP_ADAPT_LAG + 1 before it is folded, so that the decision of each block and the output are those of the blocks sifted in turn on one thread, which the model does, but for the failure of the search (RATPOINTS_NO_MEMORY) when a thread of the pool has no memory to store a point of its block before the delivery reaches it (lines 4245-4250, 4482, 4501), a failure that the model, allocating nothing, cannot meet

  • find_points.c:4523-4528: modelled by Ratpoints.findPointsVerbose (deviation of Ratpoints.findPointsVerbose: one function for find_points, find_points_work and the start of find_points_work_1, which the library calls in turn, and the rest of which is Ratpoints.findPointsWork. The refusals of the program, in its order and with its errors (Ratpoints.Refusal), returned apart from the outcome with the data of the callback, for the negative codes of the library (RATPOINTS_NON_SQUAREFREE and RATPOINTS_BAD_ARGS; RATPOINTS_WORK_LENGTH_TOO_SMALL and RATPOINTS_NO_MEMORY cannot arise), which share the long that find_points returns with the count, the caller keeping its data behind the pointer info: fewer than two coefficients are refused on the length of c, as the program refuses them, where the library refuses an empty list as a negative degree and one coefficient as the degree 0 (a longer list of degree 0 fails the test of the leading zeros first); and the height bound, which the program checks before it calls the library, comes before the test of the leading zeros, which the library makes first, so that 5 0 with H = 0 is error 4, as the program gives it. The degree with the leading zeros dropped is Ratpoints.BruteForce.degree c. A natural number H for the long height of the arguments (ratpoints.h:362), so that H = 0 stands for the heights below 1 that line 4658 refuses; a height that is not a long, 2 ^ 63 or more, is refused with error 4, as the program refuses it when it reads the height (Ratpoints.Cli.heightBound), where the library cannot be given one, its height being a long. The end of the type ratpoints_args (ratpoints.h:399-400) with its first fields, whose other fields are those of the options, the parameters, the result of the choice of the moduli and the outcome (Ratpoints.Options, Ratpoints.SieveOptions, Ratpoints.Params, Ratpoints.SievingInfo, Ratpoints.Outcome), of the divisor set-up (Ratpoints.Setup.setupUs1), or excluded. A list for the array of GMP integers and its scratch integers work, with nothing written back to the caller but the data of the callback, the count, three bits of the flags, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), which are 0 unless the search sets them, as find_points_work zeroes them on entry with the working field sp3, so that there is no state between calls and the reset of the flags clears nothing; the callback a function that returns what the call gives (Ratpoints.Answer), and its data a value, for the pointer info; the bit RATPOINTS_VERBOSE of the flags as the print channel print, a function that prints a text into the data of the callback, which holds the standard output of the caller, so that the text comes between the points as on the standard output of the C program, and which prints nothing when the bit is clear; the options of the output as fields of the options (Ratpoints.Options), copied into the flags of the check (Ratpoints.CheckFlags) with the flag of the reversal, for the bits of args->flags that the mask of line 4606 keeps; the points at infinity and the square test of the leading coefficient are decided where they are used (Ratpoints.Sieve.pointsAtInfinity, Ratpoints.Setup.reversal, Ratpoints.sturmRegion, Ratpoints.searchPoints); no failure for lack of memory, which the model cannot meet.)

  • find_points.c:4542-4545: excluded (interface): the input fields of the arguments that find_points_work saves, so that a caller who reuses the arguments for the next curve does not find the normalizations and choices of the search in them; the model writes nothing back

  • find_points.c:4546-4546: modelled by Ratpoints.findPointsVerbose (deviation of Ratpoints.findPointsVerbose: one function for find_points, find_points_work and the start of find_points_work_1, which the library calls in turn, and the rest of which is Ratpoints.findPointsWork. The refusals of the program, in its order and with its errors (Ratpoints.Refusal), returned apart from the outcome with the data of the callback, for the negative codes of the library (RATPOINTS_NON_SQUAREFREE and RATPOINTS_BAD_ARGS; RATPOINTS_WORK_LENGTH_TOO_SMALL and RATPOINTS_NO_MEMORY cannot arise), which share the long that find_points returns with the count, the caller keeping its data behind the pointer info: fewer than two coefficients are refused on the length of c, as the program refuses them, where the library refuses an empty list as a negative degree and one coefficient as the degree 0 (a longer list of degree 0 fails the test of the leading zeros first); and the height bound, which the program checks before it calls the library, comes before the test of the leading zeros, which the library makes first, so that 5 0 with H = 0 is error 4, as the program gives it. The degree with the leading zeros dropped is Ratpoints.BruteForce.degree c. A natural number H for the long height of the arguments (ratpoints.h:362), so that H = 0 stands for the heights below 1 that line 4658 refuses; a height that is not a long, 2 ^ 63 or more, is refused with error 4, as the program refuses it when it reads the height (Ratpoints.Cli.heightBound), where the library cannot be given one, its height being a long. The end of the type ratpoints_args (ratpoints.h:399-400) with its first fields, whose other fields are those of the options, the parameters, the result of the choice of the moduli and the outcome (Ratpoints.Options, Ratpoints.SieveOptions, Ratpoints.Params, Ratpoints.SievingInfo, Ratpoints.Outcome), of the divisor set-up (Ratpoints.Setup.setupUs1), or excluded. A list for the array of GMP integers and its scratch integers work, with nothing written back to the caller but the data of the callback, the count, three bits of the flags, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), which are 0 unless the search sets them, as find_points_work zeroes them on entry with the working field sp3, so that there is no state between calls and the reset of the flags clears nothing; the callback a function that returns what the call gives (Ratpoints.Answer), and its data a value, for the pointer info; the bit RATPOINTS_VERBOSE of the flags as the print channel print, a function that prints a text into the data of the callback, which holds the standard output of the caller, so that the text comes between the points as on the standard output of the C program, and which prints nothing when the bit is clear; the options of the output as fields of the options (Ratpoints.Options), copied into the flags of the check (Ratpoints.CheckFlags) with the flag of the reversal, for the bits of args->flags that the mask of line 4606 keeps; the points at infinity and the square test of the leading coefficient are decided where they are used (Ratpoints.Sieve.pointsAtInfinity, Ratpoints.Setup.reversal, Ratpoints.sturmRegion, Ratpoints.searchPoints); no failure for lack of memory, which the model cannot meet.)

  • find_points.c:4551-4552: modelled by Ratpoints.findPointsVerbose (deviation of Ratpoints.findPointsVerbose: one function for find_points, find_points_work and the start of find_points_work_1, which the library calls in turn, and the rest of which is Ratpoints.findPointsWork. The refusals of the program, in its order and with its errors (Ratpoints.Refusal), returned apart from the outcome with the data of the callback, for the negative codes of the library (RATPOINTS_NON_SQUAREFREE and RATPOINTS_BAD_ARGS; RATPOINTS_WORK_LENGTH_TOO_SMALL and RATPOINTS_NO_MEMORY cannot arise), which share the long that find_points returns with the count, the caller keeping its data behind the pointer info: fewer than two coefficients are refused on the length of c, as the program refuses them, where the library refuses an empty list as a negative degree and one coefficient as the degree 0 (a longer list of degree 0 fails the test of the leading zeros first); and the height bound, which the program checks before it calls the library, comes before the test of the leading zeros, which the library makes first, so that 5 0 with H = 0 is error 4, as the program gives it. The degree with the leading zeros dropped is Ratpoints.BruteForce.degree c. A natural number H for the long height of the arguments (ratpoints.h:362), so that H = 0 stands for the heights below 1 that line 4658 refuses; a height that is not a long, 2 ^ 63 or more, is refused with error 4, as the program refuses it when it reads the height (Ratpoints.Cli.heightBound), where the library cannot be given one, its height being a long. The end of the type ratpoints_args (ratpoints.h:399-400) with its first fields, whose other fields are those of the options, the parameters, the result of the choice of the moduli and the outcome (Ratpoints.Options, Ratpoints.SieveOptions, Ratpoints.Params, Ratpoints.SievingInfo, Ratpoints.Outcome), of the divisor set-up (Ratpoints.Setup.setupUs1), or excluded. A list for the array of GMP integers and its scratch integers work, with nothing written back to the caller but the data of the callback, the count, three bits of the flags, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), which are 0 unless the search sets them, as find_points_work zeroes them on entry with the working field sp3, so that there is no state between calls and the reset of the flags clears nothing; the callback a function that returns what the call gives (Ratpoints.Answer), and its data a value, for the pointer info; the bit RATPOINTS_VERBOSE of the flags as the print channel print, a function that prints a text into the data of the callback, which holds the standard output of the caller, so that the text comes between the points as on the standard output of the C program, and which prints nothing when the bit is clear; the options of the output as fields of the options (Ratpoints.Options), copied into the flags of the check (Ratpoints.CheckFlags) with the flag of the reversal, for the bits of args->flags that the mask of line 4606 keeps; the points at infinity and the square test of the leading coefficient are decided where they are used (Ratpoints.Sieve.pointsAtInfinity, Ratpoints.Setup.reversal, Ratpoints.sturmRegion, Ratpoints.searchPoints); no failure for lack of memory, which the model cannot meet.)

  • find_points.c:4557-4559: modelled by Ratpoints.findPointsVerbose (deviation of Ratpoints.findPointsVerbose: one function for find_points, find_points_work and the start of find_points_work_1, which the library calls in turn, and the rest of which is Ratpoints.findPointsWork. The refusals of the program, in its order and with its errors (Ratpoints.Refusal), returned apart from the outcome with the data of the callback, for the negative codes of the library (RATPOINTS_NON_SQUAREFREE and RATPOINTS_BAD_ARGS; RATPOINTS_WORK_LENGTH_TOO_SMALL and RATPOINTS_NO_MEMORY cannot arise), which share the long that find_points returns with the count, the caller keeping its data behind the pointer info: fewer than two coefficients are refused on the length of c, as the program refuses them, where the library refuses an empty list as a negative degree and one coefficient as the degree 0 (a longer list of degree 0 fails the test of the leading zeros first); and the height bound, which the program checks before it calls the library, comes before the test of the leading zeros, which the library makes first, so that 5 0 with H = 0 is error 4, as the program gives it. The degree with the leading zeros dropped is Ratpoints.BruteForce.degree c. A natural number H for the long height of the arguments (ratpoints.h:362), so that H = 0 stands for the heights below 1 that line 4658 refuses; a height that is not a long, 2 ^ 63 or more, is refused with error 4, as the program refuses it when it reads the height (Ratpoints.Cli.heightBound), where the library cannot be given one, its height being a long. The end of the type ratpoints_args (ratpoints.h:399-400) with its first fields, whose other fields are those of the options, the parameters, the result of the choice of the moduli and the outcome (Ratpoints.Options, Ratpoints.SieveOptions, Ratpoints.Params, Ratpoints.SievingInfo, Ratpoints.Outcome), of the divisor set-up (Ratpoints.Setup.setupUs1), or excluded. A list for the array of GMP integers and its scratch integers work, with nothing written back to the caller but the data of the callback, the count, three bits of the flags, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), which are 0 unless the search sets them, as find_points_work zeroes them on entry with the working field sp3, so that there is no state between calls and the reset of the flags clears nothing; the callback a function that returns what the call gives (Ratpoints.Answer), and its data a value, for the pointer info; the bit RATPOINTS_VERBOSE of the flags as the print channel print, a function that prints a text into the data of the callback, which holds the standard output of the caller, so that the text comes between the points as on the standard output of the C program, and which prints nothing when the bit is clear; the options of the output as fields of the options (Ratpoints.Options), copied into the flags of the check (Ratpoints.CheckFlags) with the flag of the reversal, for the bits of args->flags that the mask of line 4606 keeps; the points at infinity and the square test of the leading coefficient are decided where they are used (Ratpoints.Sieve.pointsAtInfinity, Ratpoints.Setup.reversal, Ratpoints.sturmRegion, Ratpoints.searchPoints); no failure for lack of memory, which the model cannot meet.)

  • find_points.c:4560-4563: excluded (interface): the input fields of the arguments that find_points_work puts back

  • find_points.c:4564-4565: modelled by Ratpoints.findPointsVerbose (deviation of Ratpoints.findPointsVerbose: one function for find_points, find_points_work and the start of find_points_work_1, which the library calls in turn, and the rest of which is Ratpoints.findPointsWork. The refusals of the program, in its order and with its errors (Ratpoints.Refusal), returned apart from the outcome with the data of the callback, for the negative codes of the library (RATPOINTS_NON_SQUAREFREE and RATPOINTS_BAD_ARGS; RATPOINTS_WORK_LENGTH_TOO_SMALL and RATPOINTS_NO_MEMORY cannot arise), which share the long that find_points returns with the count, the caller keeping its data behind the pointer info: fewer than two coefficients are refused on the length of c, as the program refuses them, where the library refuses an empty list as a negative degree and one coefficient as the degree 0 (a longer list of degree 0 fails the test of the leading zeros first); and the height bound, which the program checks before it calls the library, comes before the test of the leading zeros, which the library makes first, so that 5 0 with H = 0 is error 4, as the program gives it. The degree with the leading zeros dropped is Ratpoints.BruteForce.degree c. A natural number H for the long height of the arguments (ratpoints.h:362), so that H = 0 stands for the heights below 1 that line 4658 refuses; a height that is not a long, 2 ^ 63 or more, is refused with error 4, as the program refuses it when it reads the height (Ratpoints.Cli.heightBound), where the library cannot be given one, its height being a long. The end of the type ratpoints_args (ratpoints.h:399-400) with its first fields, whose other fields are those of the options, the parameters, the result of the choice of the moduli and the outcome (Ratpoints.Options, Ratpoints.SieveOptions, Ratpoints.Params, Ratpoints.SievingInfo, Ratpoints.Outcome), of the divisor set-up (Ratpoints.Setup.setupUs1), or excluded. A list for the array of GMP integers and its scratch integers work, with nothing written back to the caller but the data of the callback, the count, three bits of the flags, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), which are 0 unless the search sets them, as find_points_work zeroes them on entry with the working field sp3, so that there is no state between calls and the reset of the flags clears nothing; the callback a function that returns what the call gives (Ratpoints.Answer), and its data a value, for the pointer info; the bit RATPOINTS_VERBOSE of the flags as the print channel print, a function that prints a text into the data of the callback, which holds the standard output of the caller, so that the text comes between the points as on the standard output of the C program, and which prints nothing when the bit is clear; the options of the output as fields of the options (Ratpoints.Options), copied into the flags of the check (Ratpoints.CheckFlags) with the flag of the reversal, for the bits of args->flags that the mask of line 4606 keeps; the points at infinity and the square test of the leading coefficient are decided where they are used (Ratpoints.Sieve.pointsAtInfinity, Ratpoints.Setup.reversal, Ratpoints.sturmRegion, Ratpoints.searchPoints); no failure for lack of memory, which the model cannot meet.)

  • find_points.c:4567-4571: modelled by Ratpoints.findPointsVerbose (deviation of Ratpoints.findPointsVerbose: one function for find_points, find_points_work and the start of find_points_work_1, which the library calls in turn, and the rest of which is Ratpoints.findPointsWork. The refusals of the program, in its order and with its errors (Ratpoints.Refusal), returned apart from the outcome with the data of the callback, for the negative codes of the library (RATPOINTS_NON_SQUAREFREE and RATPOINTS_BAD_ARGS; RATPOINTS_WORK_LENGTH_TOO_SMALL and RATPOINTS_NO_MEMORY cannot arise), which share the long that find_points returns with the count, the caller keeping its data behind the pointer info: fewer than two coefficients are refused on the length of c, as the program refuses them, where the library refuses an empty list as a negative degree and one coefficient as the degree 0 (a longer list of degree 0 fails the test of the leading zeros first); and the height bound, which the program checks before it calls the library, comes before the test of the leading zeros, which the library makes first, so that 5 0 with H = 0 is error 4, as the program gives it. The degree with the leading zeros dropped is Ratpoints.BruteForce.degree c. A natural number H for the long height of the arguments (ratpoints.h:362), so that H = 0 stands for the heights below 1 that line 4658 refuses; a height that is not a long, 2 ^ 63 or more, is refused with error 4, as the program refuses it when it reads the height (Ratpoints.Cli.heightBound), where the library cannot be given one, its height being a long. The end of the type ratpoints_args (ratpoints.h:399-400) with its first fields, whose other fields are those of the options, the parameters, the result of the choice of the moduli and the outcome (Ratpoints.Options, Ratpoints.SieveOptions, Ratpoints.Params, Ratpoints.SievingInfo, Ratpoints.Outcome), of the divisor set-up (Ratpoints.Setup.setupUs1), or excluded. A list for the array of GMP integers and its scratch integers work, with nothing written back to the caller but the data of the callback, the count, three bits of the flags, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), which are 0 unless the search sets them, as find_points_work zeroes them on entry with the working field sp3, so that there is no state between calls and the reset of the flags clears nothing; the callback a function that returns what the call gives (Ratpoints.Answer), and its data a value, for the pointer info; the bit RATPOINTS_VERBOSE of the flags as the print channel print, a function that prints a text into the data of the callback, which holds the standard output of the caller, so that the text comes between the points as on the standard output of the C program, and which prints nothing when the bit is clear; the options of the output as fields of the options (Ratpoints.Options), copied into the flags of the check (Ratpoints.CheckFlags) with the flag of the reversal, for the bits of args->flags that the mask of line 4606 keeps; the points at infinity and the square test of the leading coefficient are decided where they are used (Ratpoints.Sieve.pointsAtInfinity, Ratpoints.Setup.reversal, Ratpoints.sturmRegion, Ratpoints.searchPoints); no failure for lack of memory, which the model cannot meet.)

  • find_points.c:4572-4572: excluded (threads): the worker of the calling thread, the state with which a thread sieves its blocks (its survivors, its third stage); the model sieves the blocks in turn, without threads, and passes what the sieve needs as arguments

  • find_points.c:4573-4573: modelled by Ratpoints.sieving (deviation of Ratpoints.sieving: a function of its own for the block of the sieving in find_points_work_1; the range of the denominators and the search intervals as arguments, for the fields b_low, b_high, domain and num_inter of the arguments that run_setup and the run read; the flags of the denominators as Booleans and an option, for the bits of args->flags and the arrays args->den_info and args->divisors that run_setup reads; the array of the row offsets made with zeros, for the array on the stack, whose entries the C code leaves unset until class_offsets writes them, with one offset in each row for each of the sp3_max sieve entries of the run, the reserve of the correction included; the delivery passed and returned, for the pointers info and wk.quit and the count total, and the ends of the second and the third stage of the last block returned with it, for the fields sp2 and sp3 of the arguments that the run writes; no sieving thread made (worker_init, worker_clear), whose fields the components that the run calls take as arguments, and no pool of threads (excluded with the threads); no failure for lack of memory, which the model cannot meet.)

  • find_points.c:4577-4585: modelled by Ratpoints.findPointsWork (deviation of Ratpoints.findPointsWork: a function of its own for the part of find_points_work_1 after the test of the leading zeros; the refusals returned apart from the outcome, with the data of the callback, for the negative codes that the C code returns, the caller keeping its data behind the pointer info; the outcome of the return of line 4889, which leaves the flags of the squares clear and no interval, with the data info, the count 0, the flag of the reversal, no interval and no moduli used, the flag being in fact clear there (the cases 1 and 3 of the reversal check leave an odd degree, and in case 2 the reversed polynomial takes the value c_d > 0 at 0, in the default interval, which the Sturm step keeps); the test of the longs (Ratpoints.Setup.useCLong), which the C code makes between the reversal check and the search intervals, made by the search, where it is used; the report under RATPOINTS_VERBOSE printed through the print channel, that of the reversal check and of the Sturm step after them, from their results, where the C code prints in their course; no failure for lack of memory, which the model cannot meet.)

  • find_points.c:4588-4589: modelled by Ratpoints.searchPoints (deviation of Ratpoints.searchPoints: the range of the denominators, the search intervals and the flag sturm_empty as arguments, for the fields b_low, b_high, domain and num_inter of the arguments and the local flag of find_points_work_1; the flags of the denominators as Booleans, for the bits of args->flags; the divisors of the leading coefficient with their records as lists, for the arrays args->den_info and args->divisors of the arguments; the square test lcfsq of line 4906 made on the polynomial searched (Ratpoints.Setup.isSquare), where the C code computes it before the reversal check (line 4634) and clears it in case 2 (line 4770): the same value for an even degree, the only one that reads it; the array size normalized for the height bound where the estimate of the run reads it (Ratpoints.arraySizeAt); the test on point_at_infty of the 2-adic exit recomputed, as Ratpoints.Sieve.pointsAtInfinity decides it; the 2-adic exit returns the delivery with the message, nothing delivered, where find_points_work_1 returns the count 0; the delivery passed, for the pointer info, the local flag quit of find_points_work_1 and the count total, and the result with the bits of the flags written back, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), for the bits that find_points_work_1 sets in args->flags, the intervals that it leaves in args->domain and the fields sp1_used, sp2_used and sp3_used that the part after the choice sets (Ratpoints.chooseAndSearch); the report under RATPOINTS_VERBOSE printed through the print channel, the lines of the tests on the denominators together after the divisor set-up, which prints nothing; no output under DEBUG.)

  • find_points.c:4595-4596: modelled by Ratpoints.searchPoints (deviation of Ratpoints.searchPoints: the range of the denominators, the search intervals and the flag sturm_empty as arguments, for the fields b_low, b_high, domain and num_inter of the arguments and the local flag of find_points_work_1; the flags of the denominators as Booleans, for the bits of args->flags; the divisors of the leading coefficient with their records as lists, for the arrays args->den_info and args->divisors of the arguments; the square test lcfsq of line 4906 made on the polynomial searched (Ratpoints.Setup.isSquare), where the C code computes it before the reversal check (line 4634) and clears it in case 2 (line 4770): the same value for an even degree, the only one that reads it; the array size normalized for the height bound where the estimate of the run reads it (Ratpoints.arraySizeAt); the test on point_at_infty of the 2-adic exit recomputed, as Ratpoints.Sieve.pointsAtInfinity decides it; the 2-adic exit returns the delivery with the message, nothing delivered, where find_points_work_1 returns the count 0; the delivery passed, for the pointer info, the local flag quit of find_points_work_1 and the count total, and the result with the bits of the flags written back, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), for the bits that find_points_work_1 sets in args->flags, the intervals that it leaves in args->domain and the fields sp1_used, sp2_used and sp3_used that the part after the choice sets (Ratpoints.chooseAndSearch); the report under RATPOINTS_VERBOSE printed through the print channel, the lines of the tests on the denominators together after the divisor set-up, which prints nothing; no output under DEBUG.)

  • find_points.c:4599-4600: modelled by Ratpoints.Setup.useCLong (deviation of Ratpoints.Setup.useCLong: no array c_long: the coefficients stay integers, which Ratpoints.Sieve.modLong reads as longs, as mpz_get_si gives them exactly when they fit; the flag is returned, for the int that the loop sets, and the loop, which stops at the first coefficient that is not a long, is List.all.)

  • find_points.c:4602-4602: modelled by Ratpoints.searchPoints (deviation of Ratpoints.searchPoints: the range of the denominators, the search intervals and the flag sturm_empty as arguments, for the fields b_low, b_high, domain and num_inter of the arguments and the local flag of find_points_work_1; the flags of the denominators as Booleans, for the bits of args->flags; the divisors of the leading coefficient with their records as lists, for the arrays args->den_info and args->divisors of the arguments; the square test lcfsq of line 4906 made on the polynomial searched (Ratpoints.Setup.isSquare), where the C code computes it before the reversal check (line 4634) and clears it in case 2 (line 4770): the same value for an even degree, the only one that reads it; the array size normalized for the height bound where the estimate of the run reads it (Ratpoints.arraySizeAt); the test on point_at_infty of the 2-adic exit recomputed, as Ratpoints.Sieve.pointsAtInfinity decides it; the 2-adic exit returns the delivery with the message, nothing delivered, where find_points_work_1 returns the count 0; the delivery passed, for the pointer info, the local flag quit of find_points_work_1 and the count total, and the result with the bits of the flags written back, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), for the bits that find_points_work_1 sets in args->flags, the intervals that it leaves in args->domain and the fields sp1_used, sp2_used and sp3_used that the part after the choice sets (Ratpoints.chooseAndSearch); the report under RATPOINTS_VERBOSE printed through the print channel, the lines of the tests on the denominators together after the divisor set-up, which prints nothing; no output under DEBUG.)

  • find_points.c:4603-4604: modelled by Ratpoints.searchPoints (deviation of Ratpoints.searchPoints: the range of the denominators, the search intervals and the flag sturm_empty as arguments, for the fields b_low, b_high, domain and num_inter of the arguments and the local flag of find_points_work_1; the flags of the denominators as Booleans, for the bits of args->flags; the divisors of the leading coefficient with their records as lists, for the arrays args->den_info and args->divisors of the arguments; the square test lcfsq of line 4906 made on the polynomial searched (Ratpoints.Setup.isSquare), where the C code computes it before the reversal check (line 4634) and clears it in case 2 (line 4770): the same value for an even degree, the only one that reads it; the array size normalized for the height bound where the estimate of the run reads it (Ratpoints.arraySizeAt); the test on point_at_infty of the 2-adic exit recomputed, as Ratpoints.Sieve.pointsAtInfinity decides it; the 2-adic exit returns the delivery with the message, nothing delivered, where find_points_work_1 returns the count 0; the delivery passed, for the pointer info, the local flag quit of find_points_work_1 and the count total, and the result with the bits of the flags written back, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), for the bits that find_points_work_1 sets in args->flags, the intervals that it leaves in args->domain and the fields sp1_used, sp2_used and sp3_used that the part after the choice sets (Ratpoints.chooseAndSearch); the report under RATPOINTS_VERBOSE printed through the print channel, the lines of the tests on the denominators together after the divisor set-up, which prints nothing; no output under DEBUG.)

  • find_points.c:4606-4606: modelled by Ratpoints.findPointsVerbose (deviation of Ratpoints.findPointsVerbose: one function for find_points, find_points_work and the start of find_points_work_1, which the library calls in turn, and the rest of which is Ratpoints.findPointsWork. The refusals of the program, in its order and with its errors (Ratpoints.Refusal), returned apart from the outcome with the data of the callback, for the negative codes of the library (RATPOINTS_NON_SQUAREFREE and RATPOINTS_BAD_ARGS; RATPOINTS_WORK_LENGTH_TOO_SMALL and RATPOINTS_NO_MEMORY cannot arise), which share the long that find_points returns with the count, the caller keeping its data behind the pointer info: fewer than two coefficients are refused on the length of c, as the program refuses them, where the library refuses an empty list as a negative degree and one coefficient as the degree 0 (a longer list of degree 0 fails the test of the leading zeros first); and the height bound, which the program checks before it calls the library, comes before the test of the leading zeros, which the library makes first, so that 5 0 with H = 0 is error 4, as the program gives it. The degree with the leading zeros dropped is Ratpoints.BruteForce.degree c. A natural number H for the long height of the arguments (ratpoints.h:362), so that H = 0 stands for the heights below 1 that line 4658 refuses; a height that is not a long, 2 ^ 63 or more, is refused with error 4, as the program refuses it when it reads the height (Ratpoints.Cli.heightBound), where the library cannot be given one, its height being a long. The end of the type ratpoints_args (ratpoints.h:399-400) with its first fields, whose other fields are those of the options, the parameters, the result of the choice of the moduli and the outcome (Ratpoints.Options, Ratpoints.SieveOptions, Ratpoints.Params, Ratpoints.SievingInfo, Ratpoints.Outcome), of the divisor set-up (Ratpoints.Setup.setupUs1), or excluded. A list for the array of GMP integers and its scratch integers work, with nothing written back to the caller but the data of the callback, the count, three bits of the flags, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), which are 0 unless the search sets them, as find_points_work zeroes them on entry with the working field sp3, so that there is no state between calls and the reset of the flags clears nothing; the callback a function that returns what the call gives (Ratpoints.Answer), and its data a value, for the pointer info; the bit RATPOINTS_VERBOSE of the flags as the print channel print, a function that prints a text into the data of the callback, which holds the standard output of the caller, so that the text comes between the points as on the standard output of the C program, and which prints nothing when the bit is clear; the options of the output as fields of the options (Ratpoints.Options), copied into the flags of the check (Ratpoints.CheckFlags) with the flag of the reversal, for the bits of args->flags that the mask of line 4606 keeps; the points at infinity and the square test of the leading coefficient are decided where they are used (Ratpoints.Sieve.pointsAtInfinity, Ratpoints.Setup.reversal, Ratpoints.sturmRegion, Ratpoints.searchPoints); no failure for lack of memory, which the model cannot meet.)

  • find_points.c:4607-4607: modelled by Ratpoints.searchPoints (deviation of Ratpoints.searchPoints: the range of the denominators, the search intervals and the flag sturm_empty as arguments, for the fields b_low, b_high, domain and num_inter of the arguments and the local flag of find_points_work_1; the flags of the denominators as Booleans, for the bits of args->flags; the divisors of the leading coefficient with their records as lists, for the arrays args->den_info and args->divisors of the arguments; the square test lcfsq of line 4906 made on the polynomial searched (Ratpoints.Setup.isSquare), where the C code computes it before the reversal check (line 4634) and clears it in case 2 (line 4770): the same value for an even degree, the only one that reads it; the array size normalized for the height bound where the estimate of the run reads it (Ratpoints.arraySizeAt); the test on point_at_infty of the 2-adic exit recomputed, as Ratpoints.Sieve.pointsAtInfinity decides it; the 2-adic exit returns the delivery with the message, nothing delivered, where find_points_work_1 returns the count 0; the delivery passed, for the pointer info, the local flag quit of find_points_work_1 and the count total, and the result with the bits of the flags written back, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), for the bits that find_points_work_1 sets in args->flags, the intervals that it leaves in args->domain and the fields sp1_used, sp2_used and sp3_used that the part after the choice sets (Ratpoints.chooseAndSearch); the report under RATPOINTS_VERBOSE printed through the print channel, the lines of the tests on the denominators together after the divisor set-up, which prints nothing; no output under DEBUG.)

  • find_points.c:4610-4612: excluded (memory): the reset of the bump allocators of the buffers that find_points_init allocates, from which the set-up and the sieve take their memory; the model allocates nothing itself

  • find_points.c:4614-4616: excluded (instrumentation): the message under DEBUG at the start of find_points_work_1

  • find_points.c:4618-4623: excluded (interface): the checks of the coefficient array and of the work array that find_points_init sets up, which only a caller of the library can fail (the work array is missing when find_points_init refused the degree and the caller then gave an admissible one, since find_points_work refuses an inadmissible degree first at lines 4557-4558, or for lack of memory, which the model cannot meet)

  • find_points.c:4624-4633: modelled by Ratpoints.findPointsVerbose (deviation of Ratpoints.findPointsVerbose: one function for find_points, find_points_work and the start of find_points_work_1, which the library calls in turn, and the rest of which is Ratpoints.findPointsWork. The refusals of the program, in its order and with its errors (Ratpoints.Refusal), returned apart from the outcome with the data of the callback, for the negative codes of the library (RATPOINTS_NON_SQUAREFREE and RATPOINTS_BAD_ARGS; RATPOINTS_WORK_LENGTH_TOO_SMALL and RATPOINTS_NO_MEMORY cannot arise), which share the long that find_points returns with the count, the caller keeping its data behind the pointer info: fewer than two coefficients are refused on the length of c, as the program refuses them, where the library refuses an empty list as a negative degree and one coefficient as the degree 0 (a longer list of degree 0 fails the test of the leading zeros first); and the height bound, which the program checks before it calls the library, comes before the test of the leading zeros, which the library makes first, so that 5 0 with H = 0 is error 4, as the program gives it. The degree with the leading zeros dropped is Ratpoints.BruteForce.degree c. A natural number H for the long height of the arguments (ratpoints.h:362), so that H = 0 stands for the heights below 1 that line 4658 refuses; a height that is not a long, 2 ^ 63 or more, is refused with error 4, as the program refuses it when it reads the height (Ratpoints.Cli.heightBound), where the library cannot be given one, its height being a long. The end of the type ratpoints_args (ratpoints.h:399-400) with its first fields, whose other fields are those of the options, the parameters, the result of the choice of the moduli and the outcome (Ratpoints.Options, Ratpoints.SieveOptions, Ratpoints.Params, Ratpoints.SievingInfo, Ratpoints.Outcome), of the divisor set-up (Ratpoints.Setup.setupUs1), or excluded. A list for the array of GMP integers and its scratch integers work, with nothing written back to the caller but the data of the callback, the count, three bits of the flags, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), which are 0 unless the search sets them, as find_points_work zeroes them on entry with the working field sp3, so that there is no state between calls and the reset of the flags clears nothing; the callback a function that returns what the call gives (Ratpoints.Answer), and its data a value, for the pointer info; the bit RATPOINTS_VERBOSE of the flags as the print channel print, a function that prints a text into the data of the callback, which holds the standard output of the caller, so that the text comes between the points as on the standard output of the C program, and which prints nothing when the bit is clear; the options of the output as fields of the options (Ratpoints.Options), copied into the flags of the check (Ratpoints.CheckFlags) with the flag of the reversal, for the bits of args->flags that the mask of line 4606 keeps; the points at infinity and the square test of the leading coefficient are decided where they are used (Ratpoints.Sieve.pointsAtInfinity, Ratpoints.Setup.reversal, Ratpoints.sturmRegion, Ratpoints.searchPoints); no failure for lack of memory, which the model cannot meet.)

  • find_points.c:4634-4634: modelled by Ratpoints.Sieve.pointsAtInfinity (deviation of Ratpoints.Sieve.pointsAtInfinity: the flags fl as an argument, for the bits RATPOINTS_REVERSED, RATPOINTS_NO_CHECK and RATPOINTS_NO_Y of the flags of the search (args->flags); the delivery r passed and returned, for the pointer info, the local flag quit and the count total of find_points_work_1; the return when the callback stops the search (lines 5100-5103) made by the caller (Ratpoints.chooseAndSearch), which also prints the line before them under RATPOINTS_VERBOSE (Ratpoints.Report.atInfinity), the line that there are points at infinity coming with the report of the tests on the denominators (Ratpoints.Report.setup); no output under DEBUG; the square test of c_d and the decision whether there are points at infinity are made on the list that it is given, after the reversal check, when the points are delivered, where the C code computes lcfsq before the check (line 4634), which clears it in case 2 (line 4770), the only reversal after which the degree is even, and leaves it, unread, with the odd degree that cases 1 and 3 leave, and sets point_at_infty before the exits of the search (lines 4894-4899); the square root by Nat.sqrt, for mpz_sqrt.)

  • find_points.c:4636-4638: excluded (instrumentation): the message under DEBUG before the checks of the parameters

  • find_points.c:4640-4641: modelled by Ratpoints.Options.normalize (deviation of Ratpoints.Options.normalize: the normalized options returned, for the fields of the arguments that the C code normalizes in place and restores in find_points_work (lines 4542-4545 and 4560-4563), which the caller does not see either; no clamp of the number of the search intervals, which a list cannot make negative; the bit RATPOINTS_NO_REVERSE_AUTO, which the C code sets in the flags and the reversal check tests with RATPOINTS_NO_REVERSE (line 4739), as the switch reverse cleared; integers for the longs.)

  • find_points.c:4643-4649: modelled by Ratpoints.SieveOptions.normalize (deviation of Ratpoints.SieveOptions.normalize: the normalized options returned, for the fields of the arguments that the C code normalizes in place and restores in find_points_work (lines 4542-4545 and 4560-4563); the array size normalized with the height bound where it is read (Ratpoints.arraySizeAt); no enlargement of the buffer of the rows (line 4654), which the model does not have; integers for the longs.)

  • find_points.c:4654-4654: excluded (memory): the enlargement of ba_buffer for more primes than find_points_init sized it for, which fails only for lack of memory

  • find_points.c:4655-4656: modelled by Ratpoints.SieveOptions.normalize (deviation of Ratpoints.SieveOptions.normalize: the normalized options returned, for the fields of the arguments that the C code normalizes in place and restores in find_points_work (lines 4542-4545 and 4560-4563); the array size normalized with the height bound where it is read (Ratpoints.arraySizeAt); no enlargement of the buffer of the rows (line 4654), which the model does not have; integers for the longs.)

  • find_points.c:4658-4658: modelled by Ratpoints.findPointsVerbose (deviation of Ratpoints.findPointsVerbose: one function for find_points, find_points_work and the start of find_points_work_1, which the library calls in turn, and the rest of which is Ratpoints.findPointsWork. The refusals of the program, in its order and with its errors (Ratpoints.Refusal), returned apart from the outcome with the data of the callback, for the negative codes of the library (RATPOINTS_NON_SQUAREFREE and RATPOINTS_BAD_ARGS; RATPOINTS_WORK_LENGTH_TOO_SMALL and RATPOINTS_NO_MEMORY cannot arise), which share the long that find_points returns with the count, the caller keeping its data behind the pointer info: fewer than two coefficients are refused on the length of c, as the program refuses them, where the library refuses an empty list as a negative degree and one coefficient as the degree 0 (a longer list of degree 0 fails the test of the leading zeros first); and the height bound, which the program checks before it calls the library, comes before the test of the leading zeros, which the library makes first, so that 5 0 with H = 0 is error 4, as the program gives it. The degree with the leading zeros dropped is Ratpoints.BruteForce.degree c. A natural number H for the long height of the arguments (ratpoints.h:362), so that H = 0 stands for the heights below 1 that line 4658 refuses; a height that is not a long, 2 ^ 63 or more, is refused with error 4, as the program refuses it when it reads the height (Ratpoints.Cli.heightBound), where the library cannot be given one, its height being a long. The end of the type ratpoints_args (ratpoints.h:399-400) with its first fields, whose other fields are those of the options, the parameters, the result of the choice of the moduli and the outcome (Ratpoints.Options, Ratpoints.SieveOptions, Ratpoints.Params, Ratpoints.SievingInfo, Ratpoints.Outcome), of the divisor set-up (Ratpoints.Setup.setupUs1), or excluded. A list for the array of GMP integers and its scratch integers work, with nothing written back to the caller but the data of the callback, the count, three bits of the flags, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), which are 0 unless the search sets them, as find_points_work zeroes them on entry with the working field sp3, so that there is no state between calls and the reset of the flags clears nothing; the callback a function that returns what the call gives (Ratpoints.Answer), and its data a value, for the pointer info; the bit RATPOINTS_VERBOSE of the flags as the print channel print, a function that prints a text into the data of the callback, which holds the standard output of the caller, so that the text comes between the points as on the standard output of the C program, and which prints nothing when the bit is clear; the options of the output as fields of the options (Ratpoints.Options), copied into the flags of the check (Ratpoints.CheckFlags) with the flag of the reversal, for the bits of args->flags that the mask of line 4606 keeps; the points at infinity and the square test of the leading coefficient are decided where they are used (Ratpoints.Sieve.pointsAtInfinity, Ratpoints.Setup.reversal, Ratpoints.sturmRegion, Ratpoints.searchPoints); no failure for lack of memory, which the model cannot meet.)

  • find_points.c:4659-4661: modelled by Ratpoints.Options.normalize (deviation of Ratpoints.Options.normalize: the normalized options returned, for the fields of the arguments that the C code normalizes in place and restores in find_points_work (lines 4542-4545 and 4560-4563), which the caller does not see either; no clamp of the number of the search intervals, which a list cannot make negative; the bit RATPOINTS_NO_REVERSE_AUTO, which the C code sets in the flags and the reversal check tests with RATPOINTS_NO_REVERSE (line 4739), as the switch reverse cleared; integers for the longs.)

  • find_points.c:4662-4665: modelled by Ratpoints.SieveOptions.normalize (deviation of Ratpoints.SieveOptions.normalize: the normalized options returned, for the fields of the arguments that the C code normalizes in place and restores in find_points_work (lines 4542-4545 and 4560-4563); the array size normalized with the height bound where it is read (Ratpoints.arraySizeAt); no enlargement of the buffer of the rows (line 4654), which the model does not have; integers for the longs.)

  • find_points.c:4666-4677: modelled by Ratpoints.arraySizeAt (deviation of Ratpoints.arraySizeAt: a Nat for the long field, so that only 0 stands for the default, which the library takes for every value ≤ 0; 64 for LONG_LENGTH; and the macro CEIL of a natural number x by d as (x + d - 1) / d, which is its value for every x ≥ 0.)

  • find_points.c:4678-4689: modelled by Ratpoints.Options.normalize (deviation of Ratpoints.Options.normalize: the normalized options returned, for the fields of the arguments that the C code normalizes in place and restores in find_points_work (lines 4542-4545 and 4560-4563), which the caller does not see either; no clamp of the number of the search intervals, which a list cannot make negative; the bit RATPOINTS_NO_REVERSE_AUTO, which the C code sets in the flags and the reversal check tests with RATPOINTS_NO_REVERSE (line 4739), as the switch reverse cleared; integers for the longs.)

  • find_points.c:4691-4725: modelled by Ratpoints.Report.arguments (deviation of Ratpoints.Report.arguments: the fields of the arguments as arguments, as the search normalizes them: the options of the sieve as Ratpoints.SieveOptions.normalize gives them, the range of the denominators, the depth and the switch of the reversal as Ratpoints.Options.normalize gives them, the switch for the bits RATPOINTS_NO_REVERSE and RATPOINTS_NO_REVERSE_AUTO of the flags, and the bits RATPOINTS_NO_CHECK and RATPOINTS_NO_JACOBI as Booleans; integers for the longs.)

  • find_points.c:4727-4730: excluded (instrumentation): the message under DEBUG before the reversal check

  • find_points.c:4732-4739: modelled by Ratpoints.Setup.reversal (deviation of Ratpoints.Setup.reversal: a new list for the reversal in place, and nothing written back to the caller: the reversed coefficients, the degree and the flag RATPOINTS_REVERSED are returned instead; the switch for the test of the flags RATPOINTS_NO_REVERSE and RATPOINTS_NO_REVERSE_AUTO, which is on when neither is set, as the normalized options give it (Ratpoints.Options.normalize: off for a search region or a range of the denominators); the square test of c_d made here, where the C code reads the flag lcfsq that the set-up computes before (line 4634), and no flag lcfsq for the reversed list, which case 2 clears, since Ratpoints.Sieve.pointsAtInfinity tests the leading coefficient of the list it is given; integers and their absolute values for the GMP integers, with no scratch integers work[0] and work[1]; the report under RATPOINTS_VERBOSE printed by the caller from the result (Ratpoints.Report.reversal).)

  • find_points.c:4740-4743: modelled by Ratpoints.Report.reversal (deviation of Ratpoints.Report.reversal: one text, from the result of the check, for the messages that the C code prints in its course, the case of a reversal read from the degree and the constant term as the check decides it: case 1 for even d and c₀ = 0, case 2 for even d otherwise and case 3 for odd d.)

  • find_points.c:4744-4756: modelled by Ratpoints.Setup.reversal (deviation of Ratpoints.Setup.reversal: a new list for the reversal in place, and nothing written back to the caller: the reversed coefficients, the degree and the flag RATPOINTS_REVERSED are returned instead; the switch for the test of the flags RATPOINTS_NO_REVERSE and RATPOINTS_NO_REVERSE_AUTO, which is on when neither is set, as the normalized options give it (Ratpoints.Options.normalize: off for a search region or a range of the denominators); the square test of c_d made here, where the C code reads the flag lcfsq that the set-up computes before (line 4634), and no flag lcfsq for the reversed list, which case 2 clears, since Ratpoints.Sieve.pointsAtInfinity tests the leading coefficient of the list it is given; integers and their absolute values for the GMP integers, with no scratch integers work[0] and work[1]; the report under RATPOINTS_VERBOSE printed by the caller from the result (Ratpoints.Report.reversal).)

  • find_points.c:4757-4758: modelled by Ratpoints.Report.reversal (deviation of Ratpoints.Report.reversal: one text, from the result of the check, for the messages that the C code prints in its course, the case of a reversal read from the degree and the constant term as the check decides it: case 1 for even d and c₀ = 0, case 2 for even d otherwise and case 3 for odd d.)

  • find_points.c:4759-4770: modelled by Ratpoints.Setup.reversal (deviation of Ratpoints.Setup.reversal: a new list for the reversal in place, and nothing written back to the caller: the reversed coefficients, the degree and the flag RATPOINTS_REVERSED are returned instead; the switch for the test of the flags RATPOINTS_NO_REVERSE and RATPOINTS_NO_REVERSE_AUTO, which is on when neither is set, as the normalized options give it (Ratpoints.Options.normalize: off for a search region or a range of the denominators); the square test of c_d made here, where the C code reads the flag lcfsq that the set-up computes before (line 4634), and no flag lcfsq for the reversed list, which case 2 clears, since Ratpoints.Sieve.pointsAtInfinity tests the leading coefficient of the list it is given; integers and their absolute values for the GMP integers, with no scratch integers work[0] and work[1]; the report under RATPOINTS_VERBOSE printed by the caller from the result (Ratpoints.Report.reversal).)

  • find_points.c:4771-4774: modelled by Ratpoints.Report.reversal (deviation of Ratpoints.Report.reversal: one text, from the result of the check, for the messages that the C code prints in its course, the case of a reversal read from the degree and the constant term as the check decides it: case 1 for even d and c₀ = 0, case 2 for even d otherwise and case 3 for odd d.)

  • find_points.c:4775-4790: modelled by Ratpoints.Setup.reversal (deviation of Ratpoints.Setup.reversal: a new list for the reversal in place, and nothing written back to the caller: the reversed coefficients, the degree and the flag RATPOINTS_REVERSED are returned instead; the switch for the test of the flags RATPOINTS_NO_REVERSE and RATPOINTS_NO_REVERSE_AUTO, which is on when neither is set, as the normalized options give it (Ratpoints.Options.normalize: off for a search region or a range of the denominators); the square test of c_d made here, where the C code reads the flag lcfsq that the set-up computes before (line 4634), and no flag lcfsq for the reversed list, which case 2 clears, since Ratpoints.Sieve.pointsAtInfinity tests the leading coefficient of the list it is given; integers and their absolute values for the GMP integers, with no scratch integers work[0] and work[1]; the report under RATPOINTS_VERBOSE printed by the caller from the result (Ratpoints.Report.reversal).)

  • find_points.c:4791-4801: modelled by Ratpoints.Report.reversal (deviation of Ratpoints.Report.reversal: one text, from the result of the check, for the messages that the C code prints in its course, the case of a reversal read from the degree and the constant term as the check decides it: case 1 for even d and c₀ = 0, case 2 for even d otherwise and case 3 for odd d.)

  • find_points.c:4802-4803: modelled by Ratpoints.Setup.reversal (deviation of Ratpoints.Setup.reversal: a new list for the reversal in place, and nothing written back to the caller: the reversed coefficients, the degree and the flag RATPOINTS_REVERSED are returned instead; the switch for the test of the flags RATPOINTS_NO_REVERSE and RATPOINTS_NO_REVERSE_AUTO, which is on when neither is set, as the normalized options give it (Ratpoints.Options.normalize: off for a search region or a range of the denominators); the square test of c_d made here, where the C code reads the flag lcfsq that the set-up computes before (line 4634), and no flag lcfsq for the reversed list, which case 2 clears, since Ratpoints.Sieve.pointsAtInfinity tests the leading coefficient of the list it is given; integers and their absolute values for the GMP integers, with no scratch integers work[0] and work[1]; the report under RATPOINTS_VERBOSE printed by the caller from the result (Ratpoints.Report.reversal).)

  • find_points.c:4804-4807: modelled by Ratpoints.Report.reversal (deviation of Ratpoints.Report.reversal: one text, from the result of the check, for the messages that the C code prints in its course, the case of a reversal read from the degree and the constant term as the check decides it: case 1 for even d and c₀ = 0, case 2 for even d otherwise and case 3 for odd d.)

  • find_points.c:4809-4812: excluded (instrumentation): the message under DEBUG after the reversal check when it reverses

  • find_points.c:4814-4823: modelled by Ratpoints.Setup.useCLong (deviation of Ratpoints.Setup.useCLong: no array c_long: the coefficients stay integers, which Ratpoints.Sieve.modLong reads as longs, as mpz_get_si gives them exactly when they fit; the flag is returned, for the int that the loop sets, and the loop, which stops at the first coefficient that is not a long, is List.all.)

  • find_points.c:4825-4827: excluded (instrumentation): the message under DEBUG before the search region and the Sturm step

  • find_points.c:4829-4829: modelled by Ratpoints.searchIntervals (deviation of Ratpoints.searchIntervals: the intervals returned as a list, for the array domain and the number num_inter of the arguments, which the C code sets to the default interval in place; none for the code RATPOINTS_BAD_ARGS that the C code returns (Ratpoints.Refusal.badArgs); the test of a null pointer domain (line 4830) excluded, the interface of the library; natural numbers for the long index.)

  • find_points.c:4830-4830: excluded (interface): the check of the array of search intervals, which only a caller of the library can fail

  • find_points.c:4831-4855: modelled by Ratpoints.searchIntervals (deviation of Ratpoints.searchIntervals: the intervals returned as a list, for the array domain and the number num_inter of the arguments, which the C code sets to the default interval in place; none for the code RATPOINTS_BAD_ARGS that the C code returns (Ratpoints.Refusal.badArgs); the test of a null pointer domain (line 4830) excluded, the interface of the library; natural numbers for the long index.)

  • find_points.c:4857-4859: modelled by Ratpoints.sturmRegion (deviation of Ratpoints.sturmRegion: the result as a refusal, none, or the intervals with the flag sturm_empty, for the codes that the C code returns at lines 4879 and 4889, the intervals that it leaves in domain with their number num_inter, and its local flag sturm_empty; the square test lcfsq made on the polynomial searched (Ratpoints.Setup.isSquare), where the C code computes it before the reversal check (line 4634) and clears it in case 2 (line 4770): the same value for an even degree, the only one that reads it; no failure for lack of memory (RATPOINTS_NO_MEMORY), which the model cannot meet; the report under RATPOINTS_VERBOSE printed by the caller from the result (Ratpoints.Report.sturmStep).)

  • find_points.c:4860-4861: modelled by Ratpoints.Report.sturmStep (deviation of Ratpoints.Report.sturmStep: one text, from the result of the step, for the line before the step and the message after it, which the C code decides by the code that _ratpoints_compute_sturm returns: negative for the refusal, 0 when the step keeps no interval, and the number of the intervals kept otherwise.)

  • find_points.c:4862-4863: modelled by Ratpoints.sturmRegion (deviation of Ratpoints.sturmRegion: the result as a refusal, none, or the intervals with the flag sturm_empty, for the codes that the C code returns at lines 4879 and 4889, the intervals that it leaves in domain with their number num_inter, and its local flag sturm_empty; the square test lcfsq made on the polynomial searched (Ratpoints.Setup.isSquare), where the C code computes it before the reversal check (line 4634) and clears it in case 2 (line 4770): the same value for an even degree, the only one that reads it; no failure for lack of memory (RATPOINTS_NO_MEMORY), which the model cannot meet; the report under RATPOINTS_VERBOSE printed by the caller from the result (Ratpoints.Report.sturmStep).)

  • find_points.c:4864-4878: modelled by Ratpoints.Report.sturmStep (deviation of Ratpoints.Report.sturmStep: one text, from the result of the step, for the line before the step and the message after it, which the C code decides by the code that _ratpoints_compute_sturm returns: negative for the refusal, 0 when the step keeps no interval, and the number of the intervals kept otherwise.)

  • find_points.c:4879-4892: modelled by Ratpoints.sturmRegion (deviation of Ratpoints.sturmRegion: the result as a refusal, none, or the intervals with the flag sturm_empty, for the codes that the C code returns at lines 4879 and 4889, the intervals that it leaves in domain with their number num_inter, and its local flag sturm_empty; the square test lcfsq made on the polynomial searched (Ratpoints.Setup.isSquare), where the C code computes it before the reversal check (line 4634) and clears it in case 2 (line 4770): the same value for an even degree, the only one that reads it; no failure for lack of memory (RATPOINTS_NO_MEMORY), which the model cannot meet; the report under RATPOINTS_VERBOSE printed by the caller from the result (Ratpoints.Report.sturmStep).)

  • find_points.c:4894-4896: modelled by Ratpoints.Sieve.pointsAtInfinity (deviation of Ratpoints.Sieve.pointsAtInfinity: the flags fl as an argument, for the bits RATPOINTS_REVERSED, RATPOINTS_NO_CHECK and RATPOINTS_NO_Y of the flags of the search (args->flags); the delivery r passed and returned, for the pointer info, the local flag quit and the count total of find_points_work_1; the return when the callback stops the search (lines 5100-5103) made by the caller (Ratpoints.chooseAndSearch), which also prints the line before them under RATPOINTS_VERBOSE (Ratpoints.Report.atInfinity), the line that there are points at infinity coming with the report of the tests on the denominators (Ratpoints.Report.setup); no output under DEBUG; the square test of c_d and the decision whether there are points at infinity are made on the list that it is given, after the reversal check, when the points are delivered, where the C code computes lcfsq before the check (line 4634), which clears it in case 2 (line 4770), the only reversal after which the degree is even, and leaves it, unread, with the odd degree that cases 1 and 3 leave, and sets point_at_infty before the exits of the search (lines 4894-4899); the square root by Nat.sqrt, for mpz_sqrt.)

  • find_points.c:4897-4898: modelled by Ratpoints.Report.setup (deviation of Ratpoints.Report.setup: one text for the messages between the Sturm step and the 2-adic information, the lines before the divisor set-up printed with those after it, from its result: the set-up prints nothing; the divisors as a list, for the zero-terminated array divisors.)

  • find_points.c:4899-4899: modelled by Ratpoints.Sieve.pointsAtInfinity (deviation of Ratpoints.Sieve.pointsAtInfinity: the flags fl as an argument, for the bits RATPOINTS_REVERSED, RATPOINTS_NO_CHECK and RATPOINTS_NO_Y of the flags of the search (args->flags); the delivery r passed and returned, for the pointer info, the local flag quit and the count total of find_points_work_1; the return when the callback stops the search (lines 5100-5103) made by the caller (Ratpoints.chooseAndSearch), which also prints the line before them under RATPOINTS_VERBOSE (Ratpoints.Report.atInfinity), the line that there are points at infinity coming with the report of the tests on the denominators (Ratpoints.Report.setup); no output under DEBUG; the square test of c_d and the decision whether there are points at infinity are made on the list that it is given, after the reversal check, when the points are delivered, where the C code computes lcfsq before the check (line 4634), which clears it in case 2 (line 4770), the only reversal after which the degree is even, and leaves it, unread, with the odd degree that cases 1 and 3 leave, and sets point_at_infty before the exits of the search (lines 4894-4899); the square root by Nat.sqrt, for mpz_sqrt.)

  • find_points.c:4900-4914: modelled by Ratpoints.searchPoints (deviation of Ratpoints.searchPoints: the range of the denominators, the search intervals and the flag sturm_empty as arguments, for the fields b_low, b_high, domain and num_inter of the arguments and the local flag of find_points_work_1; the flags of the denominators as Booleans, for the bits of args->flags; the divisors of the leading coefficient with their records as lists, for the arrays args->den_info and args->divisors of the arguments; the square test lcfsq of line 4906 made on the polynomial searched (Ratpoints.Setup.isSquare), where the C code computes it before the reversal check (line 4634) and clears it in case 2 (line 4770): the same value for an even degree, the only one that reads it; the array size normalized for the height bound where the estimate of the run reads it (Ratpoints.arraySizeAt); the test on point_at_infty of the 2-adic exit recomputed, as Ratpoints.Sieve.pointsAtInfinity decides it; the 2-adic exit returns the delivery with the message, nothing delivered, where find_points_work_1 returns the count 0; the delivery passed, for the pointer info, the local flag quit of find_points_work_1 and the count total, and the result with the bits of the flags written back, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), for the bits that find_points_work_1 sets in args->flags, the intervals that it leaves in args->domain and the fields sp1_used, sp2_used and sp3_used that the part after the choice sets (Ratpoints.chooseAndSearch); the report under RATPOINTS_VERBOSE printed through the print channel, the lines of the tests on the denominators together after the divisor set-up, which prints nothing; no output under DEBUG.)

  • find_points.c:4915-4918: modelled by Ratpoints.Report.setup (deviation of Ratpoints.Report.setup: one text for the messages between the Sturm step and the 2-adic information, the lines before the divisor set-up printed with those after it, from its result: the set-up prints nothing; the divisors as a list, for the zero-terminated array divisors.)

  • find_points.c:4919-4920: modelled by Ratpoints.searchPoints (deviation of Ratpoints.searchPoints: the range of the denominators, the search intervals and the flag sturm_empty as arguments, for the fields b_low, b_high, domain and num_inter of the arguments and the local flag of find_points_work_1; the flags of the denominators as Booleans, for the bits of args->flags; the divisors of the leading coefficient with their records as lists, for the arrays args->den_info and args->divisors of the arguments; the square test lcfsq of line 4906 made on the polynomial searched (Ratpoints.Setup.isSquare), where the C code computes it before the reversal check (line 4634) and clears it in case 2 (line 4770): the same value for an even degree, the only one that reads it; the array size normalized for the height bound where the estimate of the run reads it (Ratpoints.arraySizeAt); the test on point_at_infty of the 2-adic exit recomputed, as Ratpoints.Sieve.pointsAtInfinity decides it; the 2-adic exit returns the delivery with the message, nothing delivered, where find_points_work_1 returns the count 0; the delivery passed, for the pointer info, the local flag quit of find_points_work_1 and the count total, and the result with the bits of the flags written back, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), for the bits that find_points_work_1 sets in args->flags, the intervals that it leaves in args->domain and the fields sp1_used, sp2_used and sp3_used that the part after the choice sets (Ratpoints.chooseAndSearch); the report under RATPOINTS_VERBOSE printed through the print channel, the lines of the tests on the denominators together after the divisor set-up, which prints nothing; no output under DEBUG.)

  • find_points.c:4921-4926: modelled by Ratpoints.Report.setup (deviation of Ratpoints.Report.setup: one text for the messages between the Sturm step and the 2-adic information, the lines before the divisor set-up printed with those after it, from its result: the set-up prints nothing; the divisors as a list, for the zero-terminated array divisors.)

  • find_points.c:4927-4927: modelled by Ratpoints.searchPoints (deviation of Ratpoints.searchPoints: the range of the denominators, the search intervals and the flag sturm_empty as arguments, for the fields b_low, b_high, domain and num_inter of the arguments and the local flag of find_points_work_1; the flags of the denominators as Booleans, for the bits of args->flags; the divisors of the leading coefficient with their records as lists, for the arrays args->den_info and args->divisors of the arguments; the square test lcfsq of line 4906 made on the polynomial searched (Ratpoints.Setup.isSquare), where the C code computes it before the reversal check (line 4634) and clears it in case 2 (line 4770): the same value for an even degree, the only one that reads it; the array size normalized for the height bound where the estimate of the run reads it (Ratpoints.arraySizeAt); the test on point_at_infty of the 2-adic exit recomputed, as Ratpoints.Sieve.pointsAtInfinity decides it; the 2-adic exit returns the delivery with the message, nothing delivered, where find_points_work_1 returns the count 0; the delivery passed, for the pointer info, the local flag quit of find_points_work_1 and the count total, and the result with the bits of the flags written back, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), for the bits that find_points_work_1 sets in args->flags, the intervals that it leaves in args->domain and the fields sp1_used, sp2_used and sp3_used that the part after the choice sets (Ratpoints.chooseAndSearch); the report under RATPOINTS_VERBOSE printed through the print channel, the lines of the tests on the denominators together after the divisor set-up, which prints nothing; no output under DEBUG.)

  • find_points.c:4928-4941: modelled by Ratpoints.Report.setup (deviation of Ratpoints.Report.setup: one text for the messages between the Sturm step and the 2-adic information, the lines before the divisor set-up printed with those after it, from its result: the set-up prints nothing; the divisors as a list, for the zero-terminated array divisors.)

  • find_points.c:4942-4943: modelled by Ratpoints.searchPoints (deviation of Ratpoints.searchPoints: the range of the denominators, the search intervals and the flag sturm_empty as arguments, for the fields b_low, b_high, domain and num_inter of the arguments and the local flag of find_points_work_1; the flags of the denominators as Booleans, for the bits of args->flags; the divisors of the leading coefficient with their records as lists, for the arrays args->den_info and args->divisors of the arguments; the square test lcfsq of line 4906 made on the polynomial searched (Ratpoints.Setup.isSquare), where the C code computes it before the reversal check (line 4634) and clears it in case 2 (line 4770): the same value for an even degree, the only one that reads it; the array size normalized for the height bound where the estimate of the run reads it (Ratpoints.arraySizeAt); the test on point_at_infty of the 2-adic exit recomputed, as Ratpoints.Sieve.pointsAtInfinity decides it; the 2-adic exit returns the delivery with the message, nothing delivered, where find_points_work_1 returns the count 0; the delivery passed, for the pointer info, the local flag quit of find_points_work_1 and the count total, and the result with the bits of the flags written back, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), for the bits that find_points_work_1 sets in args->flags, the intervals that it leaves in args->domain and the fields sp1_used, sp2_used and sp3_used that the part after the choice sets (Ratpoints.chooseAndSearch); the report under RATPOINTS_VERBOSE printed through the print channel, the lines of the tests on the denominators together after the divisor set-up, which prints nothing; no output under DEBUG.)

  • find_points.c:4946-4947: modelled by Ratpoints.Report.setup (deviation of Ratpoints.Report.setup: one text for the messages between the Sturm step and the 2-adic information, the lines before the divisor set-up printed with those after it, from its result: the set-up prints nothing; the divisors as a list, for the zero-terminated array divisors.)

  • find_points.c:4948-4948: modelled by Ratpoints.searchPoints (deviation of Ratpoints.searchPoints: the range of the denominators, the search intervals and the flag sturm_empty as arguments, for the fields b_low, b_high, domain and num_inter of the arguments and the local flag of find_points_work_1; the flags of the denominators as Booleans, for the bits of args->flags; the divisors of the leading coefficient with their records as lists, for the arrays args->den_info and args->divisors of the arguments; the square test lcfsq of line 4906 made on the polynomial searched (Ratpoints.Setup.isSquare), where the C code computes it before the reversal check (line 4634) and clears it in case 2 (line 4770): the same value for an even degree, the only one that reads it; the array size normalized for the height bound where the estimate of the run reads it (Ratpoints.arraySizeAt); the test on point_at_infty of the 2-adic exit recomputed, as Ratpoints.Sieve.pointsAtInfinity decides it; the 2-adic exit returns the delivery with the message, nothing delivered, where find_points_work_1 returns the count 0; the delivery passed, for the pointer info, the local flag quit of find_points_work_1 and the count total, and the result with the bits of the flags written back, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), for the bits that find_points_work_1 sets in args->flags, the intervals that it leaves in args->domain and the fields sp1_used, sp2_used and sp3_used that the part after the choice sets (Ratpoints.chooseAndSearch); the report under RATPOINTS_VERBOSE printed through the print channel, the lines of the tests on the denominators together after the divisor set-up, which prints nothing; no output under DEBUG.)

  • find_points.c:4954-4959: modelled by Ratpoints.searchPoints (deviation of Ratpoints.searchPoints: the range of the denominators, the search intervals and the flag sturm_empty as arguments, for the fields b_low, b_high, domain and num_inter of the arguments and the local flag of find_points_work_1; the flags of the denominators as Booleans, for the bits of args->flags; the divisors of the leading coefficient with their records as lists, for the arrays args->den_info and args->divisors of the arguments; the square test lcfsq of line 4906 made on the polynomial searched (Ratpoints.Setup.isSquare), where the C code computes it before the reversal check (line 4634) and clears it in case 2 (line 4770): the same value for an even degree, the only one that reads it; the array size normalized for the height bound where the estimate of the run reads it (Ratpoints.arraySizeAt); the test on point_at_infty of the 2-adic exit recomputed, as Ratpoints.Sieve.pointsAtInfinity decides it; the 2-adic exit returns the delivery with the message, nothing delivered, where find_points_work_1 returns the count 0; the delivery passed, for the pointer info, the local flag quit of find_points_work_1 and the count total, and the result with the bits of the flags written back, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), for the bits that find_points_work_1 sets in args->flags, the intervals that it leaves in args->domain and the fields sp1_used, sp2_used and sp3_used that the part after the choice sets (Ratpoints.chooseAndSearch); the report under RATPOINTS_VERBOSE printed through the print channel, the lines of the tests on the denominators together after the divisor set-up, which prints nothing; no output under DEBUG.)

  • find_points.c:4960-4961: modelled by Ratpoints.Report.noClasses

  • find_points.c:4962-4963: modelled by Ratpoints.searchPoints (deviation of Ratpoints.searchPoints: the range of the denominators, the search intervals and the flag sturm_empty as arguments, for the fields b_low, b_high, domain and num_inter of the arguments and the local flag of find_points_work_1; the flags of the denominators as Booleans, for the bits of args->flags; the divisors of the leading coefficient with their records as lists, for the arrays args->den_info and args->divisors of the arguments; the square test lcfsq of line 4906 made on the polynomial searched (Ratpoints.Setup.isSquare), where the C code computes it before the reversal check (line 4634) and clears it in case 2 (line 4770): the same value for an even degree, the only one that reads it; the array size normalized for the height bound where the estimate of the run reads it (Ratpoints.arraySizeAt); the test on point_at_infty of the 2-adic exit recomputed, as Ratpoints.Sieve.pointsAtInfinity decides it; the 2-adic exit returns the delivery with the message, nothing delivered, where find_points_work_1 returns the count 0; the delivery passed, for the pointer info, the local flag quit of find_points_work_1 and the count total, and the result with the bits of the flags written back, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), for the bits that find_points_work_1 sets in args->flags, the intervals that it leaves in args->domain and the fields sp1_used, sp2_used and sp3_used that the part after the choice sets (Ratpoints.chooseAndSearch); the report under RATPOINTS_VERBOSE printed through the print channel, the lines of the tests on the denominators together after the divisor set-up, which prints nothing; no output under DEBUG.)

  • find_points.c:4965-4968: excluded (instrumentation): the denominators of the 2-adic information under DEBUG, where the report under RATPOINTS_VERBOSE has the packing of the numerators

  • find_points.c:4969-4985: modelled by Ratpoints.Report.packing (deviation of Ratpoints.Report.packing: the pattern of a class, one word in the model, for the first word of its bit array (EXT0), which repeats the pattern; a list for the array rep.)

  • find_points.c:4988-4991: modelled by Ratpoints.Report.packing (deviation of Ratpoints.Report.packing: the pattern of a class, one word in the model, for the first word of its bit array (EXT0), which repeats the pattern; a list for the array rep.)

  • find_points.c:4992-4995: modelled by Ratpoints.searchPoints (deviation of Ratpoints.searchPoints: the range of the denominators, the search intervals and the flag sturm_empty as arguments, for the fields b_low, b_high, domain and num_inter of the arguments and the local flag of find_points_work_1; the flags of the denominators as Booleans, for the bits of args->flags; the divisors of the leading coefficient with their records as lists, for the arrays args->den_info and args->divisors of the arguments; the square test lcfsq of line 4906 made on the polynomial searched (Ratpoints.Setup.isSquare), where the C code computes it before the reversal check (line 4634) and clears it in case 2 (line 4770): the same value for an even degree, the only one that reads it; the array size normalized for the height bound where the estimate of the run reads it (Ratpoints.arraySizeAt); the test on point_at_infty of the 2-adic exit recomputed, as Ratpoints.Sieve.pointsAtInfinity decides it; the 2-adic exit returns the delivery with the message, nothing delivered, where find_points_work_1 returns the count 0; the delivery passed, for the pointer info, the local flag quit of find_points_work_1 and the count total, and the result with the bits of the flags written back, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), for the bits that find_points_work_1 sets in args->flags, the intervals that it leaves in args->domain and the fields sp1_used, sp2_used and sp3_used that the part after the choice sets (Ratpoints.chooseAndSearch); the report under RATPOINTS_VERBOSE printed through the print channel, the lines of the tests on the denominators together after the divisor set-up, which prints nothing; no output under DEBUG.)

  • find_points.c:4996-5006: modelled by Ratpoints.chooseAndSearch (deviation of Ratpoints.chooseAndSearch: a function of its own for the part of find_points_work_1 from the call of sieving_info on; the shape of the run as an argument, for the fields of the arguments and the local variables of find_points_work_1 that the C code passes on (the range of the denominators, the search intervals, the flags of the denominators, the classes and the word den_bits); the exit returns the delivery with the message, nothing delivered, where sieving_info returns the prime and find_points_work_1 the count 0; the delivery passed and returned, for the pointer info, the local flag quit of find_points_work_1 and the count total, and the numbers of the moduli used returned with it, for the fields sp1_used, sp2_used and sp3_used of the arguments, which find_points_work zeroes on entry; the report under RATPOINTS_VERBOSE printed through the print channel, that of the choice after it returns, where sieving_info prints it at its end; no failure for lack of memory, which the model cannot meet; no output under DEBUG.)

  • find_points.c:5007-5009: modelled by Ratpoints.Report.noPoints

  • find_points.c:5010-5012: modelled by Ratpoints.chooseAndSearch (deviation of Ratpoints.chooseAndSearch: a function of its own for the part of find_points_work_1 from the call of sieving_info on; the shape of the run as an argument, for the fields of the arguments and the local variables of find_points_work_1 that the C code passes on (the range of the denominators, the search intervals, the flags of the denominators, the classes and the word den_bits); the exit returns the delivery with the message, nothing delivered, where sieving_info returns the prime and find_points_work_1 the count 0; the delivery passed and returned, for the pointer info, the local flag quit of find_points_work_1 and the count total, and the numbers of the moduli used returned with it, for the fields sp1_used, sp2_used and sp3_used of the arguments, which find_points_work zeroes on entry; the report under RATPOINTS_VERBOSE printed through the print channel, that of the choice after it returns, where sieving_info prints it at its end; no failure for lack of memory, which the model cannot meet; no output under DEBUG.)

  • find_points.c:5014-5026: excluded (instrumentation): the moduli of the first two stages under DEBUG, where the report under RATPOINTS_VERBOSE has those of the three stages, the cost of a check and the forbidden divisors

  • find_points.c:5027-5042: modelled by Ratpoints.Report.moduli (deviation of Ratpoints.Report.moduli: the moduli of the stages as the moduli of the sieve entries in their order, for the fields p of the entries of sieve_list; the doubles as values of Lean’s Float (Ratpoints.Double.ofFloat), the product with the reference computed in its arithmetic; the numbers of the moduli of the second and the third stage integers, for the differences of the longs.)

  • find_points.c:5043-5048: modelled by Ratpoints.Report.excluded (deviation of Ratpoints.Report.excluded: loops over the lists, for the loops over the zero-terminated arrays forb_ba and forbidden; the switch of the Jacobi test as a Boolean, for the bit RATPOINTS_USE_JACOBI of the flags.)

  • find_points.c:5049-5058: modelled by Ratpoints.Report.excludedValuations (deviation of Ratpoints.Report.excludedValuations: natural numbers for the longs and for the mask, a while loop for each of the two loops for, the first with the power and the valuation in the order of its body.)

  • find_points.c:5059-5063: modelled by Ratpoints.Report.excluded (deviation of Ratpoints.Report.excluded: loops over the lists, for the loops over the zero-terminated arrays forb_ba and forbidden; the switch of the Jacobi test as a Boolean, for the bit RATPOINTS_USE_JACOBI of the flags.)

  • find_points.c:5064-5066: modelled by Ratpoints.Report.moduli (deviation of Ratpoints.Report.moduli: the moduli of the stages as the moduli of the sieve entries in their order, for the fields p of the entries of sieve_list; the doubles as values of Lean’s Float (Ratpoints.Double.ofFloat), the product with the reference computed in its arithmetic; the numbers of the moduli of the second and the third stage integers, for the differences of the longs.)

  • find_points.c:5068-5074: modelled by Ratpoints.Sieve.pointsAtInfinity (deviation of Ratpoints.Sieve.pointsAtInfinity: the flags fl as an argument, for the bits RATPOINTS_REVERSED, RATPOINTS_NO_CHECK and RATPOINTS_NO_Y of the flags of the search (args->flags); the delivery r passed and returned, for the pointer info, the local flag quit and the count total of find_points_work_1; the return when the callback stops the search (lines 5100-5103) made by the caller (Ratpoints.chooseAndSearch), which also prints the line before them under RATPOINTS_VERBOSE (Ratpoints.Report.atInfinity), the line that there are points at infinity coming with the report of the tests on the denominators (Ratpoints.Report.setup); no output under DEBUG; the square test of c_d and the decision whether there are points at infinity are made on the list that it is given, after the reversal check, when the points are delivered, where the C code computes lcfsq before the check (line 4634), which clears it in case 2 (line 4770), the only reversal after which the degree is even, and leaves it, unread, with the odd degree that cases 1 and 3 leave, and sets point_at_infty before the exits of the search (lines 4894-4899); the square root by Nat.sqrt, for mpz_sqrt.)

  • find_points.c:5075-5077: modelled by Ratpoints.Report.atInfinity

  • find_points.c:5078-5099: modelled by Ratpoints.Sieve.pointsAtInfinity (deviation of Ratpoints.Sieve.pointsAtInfinity: the flags fl as an argument, for the bits RATPOINTS_REVERSED, RATPOINTS_NO_CHECK and RATPOINTS_NO_Y of the flags of the search (args->flags); the delivery r passed and returned, for the pointer info, the local flag quit and the count total of find_points_work_1; the return when the callback stops the search (lines 5100-5103) made by the caller (Ratpoints.chooseAndSearch), which also prints the line before them under RATPOINTS_VERBOSE (Ratpoints.Report.atInfinity), the line that there are points at infinity coming with the report of the tests on the denominators (Ratpoints.Report.setup); no output under DEBUG; the square test of c_d and the decision whether there are points at infinity are made on the list that it is given, after the reversal check, when the points are delivered, where the C code computes lcfsq before the check (line 4634), which clears it in case 2 (line 4770), the only reversal after which the degree is even, and leaves it, unread, with the odd degree that cases 1 and 3 leave, and sets point_at_infty before the exits of the search (lines 4894-4899); the square root by Nat.sqrt, for mpz_sqrt.)

  • find_points.c:5100-5103: modelled by Ratpoints.chooseAndSearch (deviation of Ratpoints.chooseAndSearch: a function of its own for the part of find_points_work_1 from the call of sieving_info on; the shape of the run as an argument, for the fields of the arguments and the local variables of find_points_work_1 that the C code passes on (the range of the denominators, the search intervals, the flags of the denominators, the classes and the word den_bits); the exit returns the delivery with the message, nothing delivered, where sieving_info returns the prime and find_points_work_1 the count 0; the delivery passed and returned, for the pointer info, the local flag quit of find_points_work_1 and the count total, and the numbers of the moduli used returned with it, for the fields sp1_used, sp2_used and sp3_used of the arguments, which find_points_work zeroes on entry; the report under RATPOINTS_VERBOSE printed through the print channel, that of the choice after it returns, where sieving_info prints it at its end; no failure for lack of memory, which the model cannot meet; no output under DEBUG.)

  • find_points.c:5104-5104: modelled by Ratpoints.Report.sieving (deviation of Ratpoints.Report.sieving: one text for the line feed after the points at infinity and the line before the sieve, between which the C code returns when the Sturm step has left no interval.)

  • find_points.c:5105-5106: modelled by Ratpoints.chooseAndSearch (deviation of Ratpoints.chooseAndSearch: a function of its own for the part of find_points_work_1 from the call of sieving_info on; the shape of the run as an argument, for the fields of the arguments and the local variables of find_points_work_1 that the C code passes on (the range of the denominators, the search intervals, the flags of the denominators, the classes and the word den_bits); the exit returns the delivery with the message, nothing delivered, where sieving_info returns the prime and find_points_work_1 the count 0; the delivery passed and returned, for the pointer info, the local flag quit of find_points_work_1 and the count total, and the numbers of the moduli used returned with it, for the fields sp1_used, sp2_used and sp3_used of the arguments, which find_points_work zeroes on entry; the report under RATPOINTS_VERBOSE printed through the print channel, that of the choice after it returns, where sieving_info prints it at its end; no failure for lack of memory, which the model cannot meet; no output under DEBUG.)

  • find_points.c:5108-5110: excluded (instrumentation): the message before the sieve under DEBUG

  • find_points.c:5111-5113: modelled by Ratpoints.Report.sieving (deviation of Ratpoints.Report.sieving: one text for the line feed after the points at infinity and the line before the sieve, between which the C code returns when the Sturm step has left no interval.)

  • find_points.c:5116-5116: modelled by Ratpoints.sieving (deviation of Ratpoints.sieving: a function of its own for the block of the sieving in find_points_work_1; the range of the denominators and the search intervals as arguments, for the fields b_low, b_high, domain and num_inter of the arguments that run_setup and the run read; the flags of the denominators as Booleans and an option, for the bits of args->flags and the arrays args->den_info and args->divisors that run_setup reads; the array of the row offsets made with zeros, for the array on the stack, whose entries the C code leaves unset until class_offsets writes them, with one offset in each row for each of the sp3_max sieve entries of the run, the reserve of the correction included; the delivery passed and returned, for the pointers info and wk.quit and the count total, and the ends of the second and the third stage of the last block returned with it, for the fields sp2 and sp3 of the arguments that the run writes; no sieving thread made (worker_init, worker_clear), whose fields the components that the run calls take as arguments, and no pool of threads (excluded with the threads); no failure for lack of memory, which the model cannot meet.)

  • find_points.c:5119-5119: modelled by Ratpoints.sieving (deviation of Ratpoints.sieving: a function of its own for the block of the sieving in find_points_work_1; the range of the denominators and the search intervals as arguments, for the fields b_low, b_high, domain and num_inter of the arguments that run_setup and the run read; the flags of the denominators as Booleans and an option, for the bits of args->flags and the arrays args->den_info and args->divisors that run_setup reads; the array of the row offsets made with zeros, for the array on the stack, whose entries the C code leaves unset until class_offsets writes them, with one offset in each row for each of the sp3_max sieve entries of the run, the reserve of the correction included; the delivery passed and returned, for the pointers info and wk.quit and the count total, and the ends of the second and the third stage of the last block returned with it, for the fields sp2 and sp3 of the arguments that the run writes; no sieving thread made (worker_init, worker_clear), whose fields the components that the run calls take as arguments, and no pool of threads (excluded with the threads); no failure for lack of memory, which the model cannot meet.)

  • find_points.c:5120-5120: modelled by Ratpoints.Sieve.sieveRun (deviation of Ratpoints.Sieve.sieveRun: the blocks on the calling thread alone, without the pool of threads, which sifts them apart and delivers them in the same order, the decision of each block depending only on the folds of the blocks at least Ratpoints.adaptLag + 1 before it (excluded with the threads); the ends of the last block returned, for the fields sp2 and sp3 of the arguments that line 5163 writes; the store of the tables of rows passed from one block to the next, for the arrays sieve of the entries of the arguments, its last state not returned, as nothing reads the tables of rows after the run; the delivery r passed and returned, for the pointers info and wk.quit and the count total; natural numbers for the longs.)

  • find_points.c:5122-5125: excluded (instrumentation): the message under DEBUG before the allocation of the survivors

  • find_points.c:5127-5128: excluded (memory): worker_init, which allocates the survivors array of the worker of the calling thread and sets up its state, and fails only for lack of memory; the model passes what the sieve needs as arguments

  • find_points.c:5129-5129: excluded (threads): the worker of the calling thread without a pool: the calling thread sieves; the model has no threads

  • find_points.c:5132-5132: modelled by Ratpoints.sieving (deviation of Ratpoints.sieving: a function of its own for the block of the sieving in find_points_work_1; the range of the denominators and the search intervals as arguments, for the fields b_low, b_high, domain and num_inter of the arguments that run_setup and the run read; the flags of the denominators as Booleans and an option, for the bits of args->flags and the arrays args->den_info and args->divisors that run_setup reads; the array of the row offsets made with zeros, for the array on the stack, whose entries the C code leaves unset until class_offsets writes them, with one offset in each row for each of the sp3_max sieve entries of the run, the reserve of the correction included; the delivery passed and returned, for the pointers info and wk.quit and the count total, and the ends of the second and the third stage of the last block returned with it, for the fields sp2 and sp3 of the arguments that the run writes; no sieving thread made (worker_init, worker_clear), whose fields the components that the run calls take as arguments, and no pool of threads (excluded with the threads); no failure for lack of memory, which the model cannot meet.)

  • find_points.c:5133-5136: excluded (instrumentation): the end of the message under DEBUG about the allocation of the survivors

  • find_points.c:5137-5139: modelled by Ratpoints.sieving (deviation of Ratpoints.sieving: a function of its own for the block of the sieving in find_points_work_1; the range of the denominators and the search intervals as arguments, for the fields b_low, b_high, domain and num_inter of the arguments that run_setup and the run read; the flags of the denominators as Booleans and an option, for the bits of args->flags and the arrays args->den_info and args->divisors that run_setup reads; the array of the row offsets made with zeros, for the array on the stack, whose entries the C code leaves unset until class_offsets writes them, with one offset in each row for each of the sp3_max sieve entries of the run, the reserve of the correction included; the delivery passed and returned, for the pointers info and wk.quit and the count total, and the ends of the second and the third stage of the last block returned with it, for the fields sp2 and sp3 of the arguments that the run writes; no sieving thread made (worker_init, worker_clear), whose fields the components that the run calls take as arguments, and no pool of threads (excluded with the threads); no failure for lack of memory, which the model cannot meet.)

  • find_points.c:5140-5151: excluded (threads): the pool of threads, when asked for, with a survivors array for each thread, and the threaded run with its failure; the model has no threads, which deliver the blocks in their order

  • find_points.c:5152-5160: modelled by Ratpoints.Sieve.sieveRun (deviation of Ratpoints.Sieve.sieveRun: the blocks on the calling thread alone, without the pool of threads, which sifts them apart and delivers them in the same order, the decision of each block depending only on the folds of the blocks at least Ratpoints.adaptLag + 1 before it (excluded with the threads); the ends of the last block returned, for the fields sp2 and sp3 of the arguments that line 5163 writes; the store of the tables of rows passed from one block to the next, for the arrays sieve of the entries of the arguments, its last state not returned, as nothing reads the tables of rows after the run; the delivery r passed and returned, for the pointers info and wk.quit and the count total; natural numbers for the longs.)

  • find_points.c:5161-5161: excluded (threads): the end of the block of the pool of threads

  • find_points.c:5163-5163: modelled by Ratpoints.Sieve.sieveRun (deviation of Ratpoints.Sieve.sieveRun: the blocks on the calling thread alone, without the pool of threads, which sifts them apart and delivers them in the same order, the decision of each block depending only on the folds of the blocks at least Ratpoints.adaptLag + 1 before it (excluded with the threads); the ends of the last block returned, for the fields sp2 and sp3 of the arguments that line 5163 writes; the store of the tables of rows passed from one block to the next, for the arrays sieve of the entries of the arguments, its last state not returned, as nothing reads the tables of rows after the run; the delivery r passed and returned, for the pointers info and wk.quit and the count total; natural numbers for the longs.)

  • find_points.c:5164-5164: excluded (memory): the release of the run (run_clear)

  • find_points.c:5166-5166: excluded (memory): the release of the worker of the calling thread (worker_clear)

  • find_points.c:5167-5167: modelled by Ratpoints.sieving (deviation of Ratpoints.sieving: a function of its own for the block of the sieving in find_points_work_1; the range of the denominators and the search intervals as arguments, for the fields b_low, b_high, domain and num_inter of the arguments that run_setup and the run read; the flags of the denominators as Booleans and an option, for the bits of args->flags and the arrays args->den_info and args->divisors that run_setup reads; the array of the row offsets made with zeros, for the array on the stack, whose entries the C code leaves unset until class_offsets writes them, with one offset in each row for each of the sp3_max sieve entries of the run, the reserve of the correction included; the delivery passed and returned, for the pointers info and wk.quit and the count total, and the ends of the second and the third stage of the last block returned with it, for the fields sp2 and sp3 of the arguments that the run writes; no sieving thread made (worker_init, worker_clear), whose fields the components that the run calls take as arguments, and no pool of threads (excluded with the threads); no failure for lack of memory, which the model cannot meet.)

  • find_points.c:5169-5208: excluded (instrumentation): the report on the shape of the run under RP_PRIME_STATS and RP_PHASE_TIMING, which prints on stderr what run_shape predicted against what the run did

  • find_points.c:5210-5213: modelled by Ratpoints.chooseAndSearch (deviation of Ratpoints.chooseAndSearch: a function of its own for the part of find_points_work_1 from the call of sieving_info on; the shape of the run as an argument, for the fields of the arguments and the local variables of find_points_work_1 that the C code passes on (the range of the denominators, the search intervals, the flags of the denominators, the classes and the word den_bits); the exit returns the delivery with the message, nothing delivered, where sieving_info returns the prime and find_points_work_1 the count 0; the delivery passed and returned, for the pointer info, the local flag quit of find_points_work_1 and the count total, and the numbers of the moduli used returned with it, for the fields sp1_used, sp2_used and sp3_used of the arguments, which find_points_work zeroes on entry; the report under RATPOINTS_VERBOSE printed through the print channel, that of the choice after it returns, where sieving_info prints it at its end; no failure for lack of memory, which the model cannot meet; no output under DEBUG.)

  • find_points.c:5215-5217: excluded (instrumentation): the message under DEBUG at the end of find_points_work_1

  • find_points.c:5219-5220: modelled by Ratpoints.findPointsVerbose (deviation of Ratpoints.findPointsVerbose: one function for find_points, find_points_work and the start of find_points_work_1, which the library calls in turn, and the rest of which is Ratpoints.findPointsWork. The refusals of the program, in its order and with its errors (Ratpoints.Refusal), returned apart from the outcome with the data of the callback, for the negative codes of the library (RATPOINTS_NON_SQUAREFREE and RATPOINTS_BAD_ARGS; RATPOINTS_WORK_LENGTH_TOO_SMALL and RATPOINTS_NO_MEMORY cannot arise), which share the long that find_points returns with the count, the caller keeping its data behind the pointer info: fewer than two coefficients are refused on the length of c, as the program refuses them, where the library refuses an empty list as a negative degree and one coefficient as the degree 0 (a longer list of degree 0 fails the test of the leading zeros first); and the height bound, which the program checks before it calls the library, comes before the test of the leading zeros, which the library makes first, so that 5 0 with H = 0 is error 4, as the program gives it. The degree with the leading zeros dropped is Ratpoints.BruteForce.degree c. A natural number H for the long height of the arguments (ratpoints.h:362), so that H = 0 stands for the heights below 1 that line 4658 refuses; a height that is not a long, 2 ^ 63 or more, is refused with error 4, as the program refuses it when it reads the height (Ratpoints.Cli.heightBound), where the library cannot be given one, its height being a long. The end of the type ratpoints_args (ratpoints.h:399-400) with its first fields, whose other fields are those of the options, the parameters, the result of the choice of the moduli and the outcome (Ratpoints.Options, Ratpoints.SieveOptions, Ratpoints.Params, Ratpoints.SievingInfo, Ratpoints.Outcome), of the divisor set-up (Ratpoints.Setup.setupUs1), or excluded. A list for the array of GMP integers and its scratch integers work, with nothing written back to the caller but the data of the callback, the count, three bits of the flags, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), which are 0 unless the search sets them, as find_points_work zeroes them on entry with the working field sp3, so that there is no state between calls and the reset of the flags clears nothing; the callback a function that returns what the call gives (Ratpoints.Answer), and its data a value, for the pointer info; the bit RATPOINTS_VERBOSE of the flags as the print channel print, a function that prints a text into the data of the callback, which holds the standard output of the caller, so that the text comes between the points as on the standard output of the C program, and which prints nothing when the bit is clear; the options of the output as fields of the options (Ratpoints.Options), copied into the flags of the check (Ratpoints.CheckFlags) with the flag of the reversal, for the bits of args->flags that the mask of line 4606 keeps; the points at infinity and the square test of the leading coefficient are decided where they are used (Ratpoints.Sieve.pointsAtInfinity, Ratpoints.Setup.reversal, Ratpoints.sturmRegion, Ratpoints.searchPoints); no failure for lack of memory, which the model cannot meet.)

  • find_points.c:5226-5229: modelled by Ratpoints.findPointsVerbose (deviation of Ratpoints.findPointsVerbose: one function for find_points, find_points_work and the start of find_points_work_1, which the library calls in turn, and the rest of which is Ratpoints.findPointsWork. The refusals of the program, in its order and with its errors (Ratpoints.Refusal), returned apart from the outcome with the data of the callback, for the negative codes of the library (RATPOINTS_NON_SQUAREFREE and RATPOINTS_BAD_ARGS; RATPOINTS_WORK_LENGTH_TOO_SMALL and RATPOINTS_NO_MEMORY cannot arise), which share the long that find_points returns with the count, the caller keeping its data behind the pointer info: fewer than two coefficients are refused on the length of c, as the program refuses them, where the library refuses an empty list as a negative degree and one coefficient as the degree 0 (a longer list of degree 0 fails the test of the leading zeros first); and the height bound, which the program checks before it calls the library, comes before the test of the leading zeros, which the library makes first, so that 5 0 with H = 0 is error 4, as the program gives it. The degree with the leading zeros dropped is Ratpoints.BruteForce.degree c. A natural number H for the long height of the arguments (ratpoints.h:362), so that H = 0 stands for the heights below 1 that line 4658 refuses; a height that is not a long, 2 ^ 63 or more, is refused with error 4, as the program refuses it when it reads the height (Ratpoints.Cli.heightBound), where the library cannot be given one, its height being a long. The end of the type ratpoints_args (ratpoints.h:399-400) with its first fields, whose other fields are those of the options, the parameters, the result of the choice of the moduli and the outcome (Ratpoints.Options, Ratpoints.SieveOptions, Ratpoints.Params, Ratpoints.SievingInfo, Ratpoints.Outcome), of the divisor set-up (Ratpoints.Setup.setupUs1), or excluded. A list for the array of GMP integers and its scratch integers work, with nothing written back to the caller but the data of the callback, the count, three bits of the flags, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), which are 0 unless the search sets them, as find_points_work zeroes them on entry with the working field sp3, so that there is no state between calls and the reset of the flags clears nothing; the callback a function that returns what the call gives (Ratpoints.Answer), and its data a value, for the pointer info; the bit RATPOINTS_VERBOSE of the flags as the print channel print, a function that prints a text into the data of the callback, which holds the standard output of the caller, so that the text comes between the points as on the standard output of the C program, and which prints nothing when the bit is clear; the options of the output as fields of the options (Ratpoints.Options), copied into the flags of the check (Ratpoints.CheckFlags) with the flag of the reversal, for the bits of args->flags that the mask of line 4606 keeps; the points at infinity and the square test of the leading coefficient are decided where they are used (Ratpoints.Sieve.pointsAtInfinity, Ratpoints.Setup.reversal, Ratpoints.sturmRegion, Ratpoints.searchPoints); no failure for lack of memory, which the model cannot meet.)

  • find_points.c:5232-5232: excluded (memory): find_points_init, which allocates the work array and the buffers of the search; its refusal of a degree outside 0, ..., RATPOINTS_MAX_DEGREE never takes effect, since find_points_work refuses the same degrees first

  • find_points.c:5235-5235: modelled by Ratpoints.findPointsVerbose (deviation of Ratpoints.findPointsVerbose: one function for find_points, find_points_work and the start of find_points_work_1, which the library calls in turn, and the rest of which is Ratpoints.findPointsWork. The refusals of the program, in its order and with its errors (Ratpoints.Refusal), returned apart from the outcome with the data of the callback, for the negative codes of the library (RATPOINTS_NON_SQUAREFREE and RATPOINTS_BAD_ARGS; RATPOINTS_WORK_LENGTH_TOO_SMALL and RATPOINTS_NO_MEMORY cannot arise), which share the long that find_points returns with the count, the caller keeping its data behind the pointer info: fewer than two coefficients are refused on the length of c, as the program refuses them, where the library refuses an empty list as a negative degree and one coefficient as the degree 0 (a longer list of degree 0 fails the test of the leading zeros first); and the height bound, which the program checks before it calls the library, comes before the test of the leading zeros, which the library makes first, so that 5 0 with H = 0 is error 4, as the program gives it. The degree with the leading zeros dropped is Ratpoints.BruteForce.degree c. A natural number H for the long height of the arguments (ratpoints.h:362), so that H = 0 stands for the heights below 1 that line 4658 refuses; a height that is not a long, 2 ^ 63 or more, is refused with error 4, as the program refuses it when it reads the height (Ratpoints.Cli.heightBound), where the library cannot be given one, its height being a long. The end of the type ratpoints_args (ratpoints.h:399-400) with its first fields, whose other fields are those of the options, the parameters, the result of the choice of the moduli and the outcome (Ratpoints.Options, Ratpoints.SieveOptions, Ratpoints.Params, Ratpoints.SievingInfo, Ratpoints.Outcome), of the divisor set-up (Ratpoints.Setup.setupUs1), or excluded. A list for the array of GMP integers and its scratch integers work, with nothing written back to the caller but the data of the callback, the count, three bits of the flags, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), which are 0 unless the search sets them, as find_points_work zeroes them on entry with the working field sp3, so that there is no state between calls and the reset of the flags clears nothing; the callback a function that returns what the call gives (Ratpoints.Answer), and its data a value, for the pointer info; the bit RATPOINTS_VERBOSE of the flags as the print channel print, a function that prints a text into the data of the callback, which holds the standard output of the caller, so that the text comes between the points as on the standard output of the C program, and which prints nothing when the bit is clear; the options of the output as fields of the options (Ratpoints.Options), copied into the flags of the check (Ratpoints.CheckFlags) with the flag of the reversal, for the bits of args->flags that the mask of line 4606 keeps; the points at infinity and the square test of the leading coefficient are decided where they are used (Ratpoints.Sieve.pointsAtInfinity, Ratpoints.Setup.reversal, Ratpoints.sturmRegion, Ratpoints.searchPoints); no failure for lack of memory, which the model cannot meet.)

  • find_points.c:5238-5238: excluded (memory): find_points_clear, which releases them

  • find_points.c:5241-5242: modelled by Ratpoints.findPointsVerbose (deviation of Ratpoints.findPointsVerbose: one function for find_points, find_points_work and the start of find_points_work_1, which the library calls in turn, and the rest of which is Ratpoints.findPointsWork. The refusals of the program, in its order and with its errors (Ratpoints.Refusal), returned apart from the outcome with the data of the callback, for the negative codes of the library (RATPOINTS_NON_SQUAREFREE and RATPOINTS_BAD_ARGS; RATPOINTS_WORK_LENGTH_TOO_SMALL and RATPOINTS_NO_MEMORY cannot arise), which share the long that find_points returns with the count, the caller keeping its data behind the pointer info: fewer than two coefficients are refused on the length of c, as the program refuses them, where the library refuses an empty list as a negative degree and one coefficient as the degree 0 (a longer list of degree 0 fails the test of the leading zeros first); and the height bound, which the program checks before it calls the library, comes before the test of the leading zeros, which the library makes first, so that 5 0 with H = 0 is error 4, as the program gives it. The degree with the leading zeros dropped is Ratpoints.BruteForce.degree c. A natural number H for the long height of the arguments (ratpoints.h:362), so that H = 0 stands for the heights below 1 that line 4658 refuses; a height that is not a long, 2 ^ 63 or more, is refused with error 4, as the program refuses it when it reads the height (Ratpoints.Cli.heightBound), where the library cannot be given one, its height being a long. The end of the type ratpoints_args (ratpoints.h:399-400) with its first fields, whose other fields are those of the options, the parameters, the result of the choice of the moduli and the outcome (Ratpoints.Options, Ratpoints.SieveOptions, Ratpoints.Params, Ratpoints.SievingInfo, Ratpoints.Outcome), of the divisor set-up (Ratpoints.Setup.setupUs1), or excluded. A list for the array of GMP integers and its scratch integers work, with nothing written back to the caller but the data of the callback, the count, three bits of the flags, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), which are 0 unless the search sets them, as find_points_work zeroes them on entry with the working field sp3, so that there is no state between calls and the reset of the flags clears nothing; the callback a function that returns what the call gives (Ratpoints.Answer), and its data a value, for the pointer info; the bit RATPOINTS_VERBOSE of the flags as the print channel print, a function that prints a text into the data of the callback, which holds the standard output of the caller, so that the text comes between the points as on the standard output of the C program, and which prints nothing when the bit is clear; the options of the output as fields of the options (Ratpoints.Options), copied into the flags of the check (Ratpoints.CheckFlags) with the flag of the reversal, for the bits of args->flags that the mask of line 4606 keeps; the points at infinity and the square test of the leading coefficient are decided where they are used (Ratpoints.Sieve.pointsAtInfinity, Ratpoints.Setup.reversal, Ratpoints.sturmRegion, Ratpoints.searchPoints); no failure for lack of memory, which the model cannot meet.)

  • find_points.c:5250-5338: modelled by Ratpoints.Sieve.checkPoint (deviation of Ratpoints.Sieve.checkPoint: the products w as a thunk, which the sieve of one denominator makes for each denominator (Ratpoints.Sieve.sift) and which is forced when the first numerator of b reaches the check, for the array work of the sieving thread, which worker_init gives it, and its flag compute_bc, which sift sets and _ratpoints_check_point clears when it computes the products; the degree d and the flags fl as arguments, handed down from Ratpoints.Sieve.sieveRun through the components that call the check, for the degree and the bits RATPOINTS_REVERSED, RATPOINTS_NO_CHECK and RATPOINTS_NO_Y of the flags of the search, which _ratpoints_check_point reads through its worker (args->degree, args->flags); the delivery r passed and returned, for the pointers info and wk->quit and the count total that _ratpoints_check_point keeps from zero and returns, and the three branches of the map of the reversal at each call one definition (Ratpoints.Delivery.callMapped); the square root and the test of the remainder by Nat.sqrt on v, for mpz_sqrtrem; integers for the longs a and b (the negations of the map stay longs by Ratpoints.fitsLong_neg); no measurements of the time of the check and of its products (RP_CHECK, RP_BC_TIC, RP_BC_TOC under RP_PHASE_TIMING), and no output under DEBUG.)

sift.c

  • sift.c:30-30: excluded (other): the include of the private header; the model has no headers

  • sift.c:55-176: excluded (instrumentation): RP_PHASE_TIMING and RP_PHASE_COUNTS, development instrumentation that times the parts of _ratpoints_sift0 with rdtsc, counts what survives each and prints one line on stderr at exit, with the arm of the production build, where the timers RP_TIC and RP_TOC are empty and RP_CHECK is the call it wraps

  • sift.c:194-201: excluded (instrumentation): RP_STOP_AFTER, development instrumentation that cuts the pipeline short after a step so that its cost can be measured, 0 in the production build, with the exact check of its level 4 replaced by a count

  • sift.c:202-205: modelled by Ratpoints.Sieve.checkPoint (deviation of Ratpoints.Sieve.checkPoint: the products w as a thunk, which the sieve of one denominator makes for each denominator (Ratpoints.Sieve.sift) and which is forced when the first numerator of b reaches the check, for the array work of the sieving thread, which worker_init gives it, and its flag compute_bc, which sift sets and _ratpoints_check_point clears when it computes the products; the degree d and the flags fl as arguments, handed down from Ratpoints.Sieve.sieveRun through the components that call the check, for the degree and the bits RATPOINTS_REVERSED, RATPOINTS_NO_CHECK and RATPOINTS_NO_Y of the flags of the search, which _ratpoints_check_point reads through its worker (args->degree, args->flags); the delivery r passed and returned, for the pointers info and wk->quit and the count total that _ratpoints_check_point keeps from zero and returns, and the three branches of the map of the reversal at each call one definition (Ratpoints.Delivery.callMapped); the square root and the test of the remainder by Nat.sqrt on v, for mpz_sqrtrem; integers for the longs a and b (the negations of the map stay longs by Ratpoints.fitsLong_neg); no measurements of the time of the check and of its products (RP_CHECK, RP_BC_TIC, RP_BC_TOC under RP_PHASE_TIMING), and no output under DEBUG.)

  • sift.c:207-213: excluded (instrumentation): the sink into which the levels of RP_STOP_AFTER accumulate the work they leave out, printed on stderr at exit

  • sift.c:225-238: excluded (instrumentation): RP_MOD_CHOICE, a development switch that chooses the reduction of the word numbers of the chunked first stage at run time, from the environment variable RP_MOD_MUL, so that the two reductions can be timed in one binary; in the production build RP_USE_MOD_MUL is the constant 1, the reduction by the reciprocal wherever it is exact

  • sift.c:243-247: modelled by Ratpoints.Sieve.modMul (deviation of Ratpoints.Sieve.modMul: integers for the longs a and the result, and natural numbers for the long p and the unsigned long reciprocal m; |a| a natural number, for the long that RP_MULMOD converts to an unsigned long.)

  • sift.c:262-264: modelled by Ratpoints.Sieve.walkWord (deviation of Ratpoints.Sieve.walkWord: the lowest set bit by the loop of RP_CTZL for a compiler without the builtin (Ratpoints.Sieve.ctz); one definition for the body at the three places of the extraction, the first word of a bit array, the others, and a word of the arm of the second stage for one word at a time; natural numbers and integers for the longs; the delivery r passed and returned, for the pointers info and wk->quit and the count total of _ratpoints_sift0, to which RP_CHECK_POINT adds the count of the check (lines 1168, 1240, 1250, 1279, 1287); the return after a stop (lines 1169, 1241, 1251, 1280, 1288) a return from the walk, which its callers pass on, testing the flag after it (Ratpoints.Sieve.siftBitArrayByWords, Ratpoints.Sieve.siftBitArrayWhole, then Ratpoints.Sieve.scanPiece after the bit array), where the C code returns from _ratpoints_sift0; the counters passed and returned, for the field n_bits of the sieving thread (lines 1166, 1233, 1271); no counts under RP_PHASE_COUNTS; no output under DEBUG.)

  • sift.c:291-301: modelled by Ratpoints.Sieve.stage3 (deviation of Ratpoints.Sieve.stage3: a list for the array csp and its length n; the residue computed by Ratpoints.Sieve.CheckSpec.index; a Boolean for the int.)

  • sift.c:302-308: modelled by Ratpoints.Sieve.CheckSpec.index (deviation of Ratpoints.Sieve.CheckSpec.index: a function of its own for the lines of the loop of stage3 that compute the residue; integers for the longs, Int.tmod for C’s %, which truncates, and the value made a natural number, for the long that RP_MULMOD converts to an unsigned long, and for the long residue, both non-negative; the obligations that the longs a binv + bias and am binv stay in range left to lemmas: for |a| ≤ H and binv < p, a binv + p H lies between H and 2 p H - H (Ratpoints.Sieve.le_mul_add_natCast_mul, Ratpoints.Sieve.mul_add_natCast_mul_le_two_mul_mul_sub), below 2 ^ 32 with the bias, and am binv < p ^ 2 (Ratpoints.Sieve.toNat_emod_mul_lt_sq).)

  • sift.c:309-312: modelled by Ratpoints.Sieve.stage3 (deviation of Ratpoints.Sieve.stage3: a list for the array csp and its length n; the residue computed by Ratpoints.Sieve.CheckSpec.index; a Boolean for the int.)

  • sift.c:318-327: modelled by Ratpoints.Sieve.relprime (deviation of Ratpoints.Sieve.relprime: Int64 for long, toUInt64 for the cast to unsigned long, and the toInt64 of the count for the long that RP_CTZL returns; the negation of a negative m as a conditional expression, for the statement if(m < 0); for m = -2 ^ 63, whose negation overflows in the C code, the model wraps; the contract excludes that value, which the search never passes, its numerators being at most H < 2 ^ 63 in absolute value; m &&& 1 == 0 for !(m & 1); the lowest set bit by the loop of RP_CTZL for a compiler without the builtin (Ratpoints.Sieve.ctz), where gcc and clang take __builtin_ctzl; the builtin is undefined on 0 and the loop does not end there, which the contract excludes, with n ≥ 1 and m ≠ 0 at the calls; the loop of the binary algorithm a function of its own (Ratpoints.Sieve.relprimeOdd); a Boolean for the int.)

  • sift.c:328-342: modelled by Ratpoints.Sieve.relprimeOdd (deviation of Ratpoints.Sieve.relprimeOdd: Int64 for long, toUInt64 for the cast to unsigned long, and the toInt64 of the count for the long that RP_CTZL returns; 63 for LONG_LENGTH - 1; Int64 in two’s complement, the representation of the negative longs on which the and d &&& msk and the exclusive or d ^^^ msk of the step act, and >>> on Int64 the arithmetic shift, for the >> of a negative long, both of which the C standard leaves to the implementation (the representation before C23) and gcc defines so; the lowest set bit by the loop of RP_CTZL for a compiler without the builtin (Ratpoints.Sieve.ctz), where gcc and clang take __builtin_ctzl; the loop a function of its own, for the end of the function relprime.)

  • sift.c:343-343: modelled by Ratpoints.Sieve.relprime (deviation of Ratpoints.Sieve.relprime: Int64 for long, toUInt64 for the cast to unsigned long, and the toInt64 of the count for the long that RP_CTZL returns; the negation of a negative m as a conditional expression, for the statement if(m < 0); for m = -2 ^ 63, whose negation overflows in the C code, the model wraps; the contract excludes that value, which the search never passes, its numerators being at most H < 2 ^ 63 in absolute value; m &&& 1 == 0 for !(m & 1); the lowest set bit by the loop of RP_CTZL for a compiler without the builtin (Ratpoints.Sieve.ctz), where gcc and clang take __builtin_ctzl; the builtin is undefined on 0 and the loop does not end there, which the contract excludes, with n ≥ 1 and m ≠ 0 at the calls; the loop of the binary algorithm a function of its own (Ratpoints.Sieve.relprimeOdd); a Boolean for the int.)

  • sift.c:349-367: excluded (instrumentation): RP_MOD_COUNTS, development instrumentation that counts how often the helper mod divides and prints the counts on stderr at exit, with the arm of the production build, where the counters RP_MOD_TICK and RP_MOD_DIV are empty

  • sift.c:370-389: modelled by Ratpoints.Sieve.modLong (deviation of Ratpoints.Sieve.modLong: one definition for the two copies of the function, in find_points.c and in sift.c, which are the same but for the hooks of the counts of the reductions in sift.c (RP_MOD_TICK, RP_MOD_DIV), empty unless RP_MOD_COUNTS is set; integers for the longs, with the obligations that the values it computes stay in the range of a long stated as lemmas: for 0 ≤ b < 2 ^ 59, 16 b (Ratpoints.fitsLong_sixteen_mul), its negation (Ratpoints.fitsLong_neg), and a + 16 b for -16 b ≤ a < 0 (Ratpoints.fitsLong_add_sixteen_mul), its other values lying between -b and 16 b; Int.tmod for C’s division of longs, which truncates; the multiples 16 b, 8 b, 4 b and 2 b as products, for the shifts of b1.)

  • sift.c:405-413: modelled by Ratpoints.Sieve.fillChecks (deviation of Ratpoints.Sieve.fillChecks: a list, made by a map over the entries of the third stage and their reciprocals (List.zipWith), for the loop over the positions sp2, …, sp3 - 1 of sieve_list and magics that fills the array checks of the sieving thread; no bound RATPOINTS_NUM_PRIMES on its length (stage3_list and the arrays of the pool, find_points.c:339, find_points.c:4372), which ratpoints never reaches since each entry of sieve_list owns its own prime (find_points.c:329-331), where the model takes any entries, which may repeat a prime; the thunk that the sieve of one denominator makes of it (Ratpoints.Sieve.sift), for the flag stage3_filled of the sieving thread, which sift clears and fill_checks sets.)

  • sift.c:414-428: modelled by Ratpoints.Sieve.checkOf (deviation of Ratpoints.Sieve.checkOf: the entry of one prime, for one pass of the loop of fill_checks (Ratpoints.Sieve.fillChecks), with the reciprocal magics[n] as the argument mg; the fields of the prime read from its table, the single factor of its sieve entry, where the C code reads them from the sieve entry of the prime, which has them itself; the exact comparison 2 p H < stage3Limit of natural numbers, for the comparison of the double product p · 2.0 · H with the double RP_STAGE3_LIMIT, which has the same outcome for every H < 2 ^ 63, the product being exact below 2 ^ 53 and rounded monotonically above, beyond the bound; natural numbers for the longs, the product p H computed only when it is below 2 ^ 31; the inverse 0 for an entry of another shape, for which the C code has no case.)

  • sift.c:429-431: modelled by Ratpoints.Sieve.fillChecks (deviation of Ratpoints.Sieve.fillChecks: a list, made by a map over the entries of the third stage and their reciprocals (List.zipWith), for the loop over the positions sp2, …, sp3 - 1 of sieve_list and magics that fills the array checks of the sieving thread; no bound RATPOINTS_NUM_PRIMES on its length (stage3_list and the arrays of the pool, find_points.c:339, find_points.c:4372), which ratpoints never reaches since each entry of sieve_list owns its own prime (find_points.c:329-331), where the model takes any entries, which may repeat a prime; the thunk that the sieve of one denominator makes of it (Ratpoints.Sieve.sift), for the flag stage3_filled of the sieving thread, which sift clears and fill_checks sets.)

  • sift.c:438-446: modelled by Ratpoints.Sieve.accepted (deviation of Ratpoints.Sieve.accepted: the integer a and the natural number b of the loops of the model converted to the 64-bit words that they are in the C code (Int.toInt64, Nat.toInt64), which is exact for |a| < 2 ^ 63 and b < 2 ^ 63, as the numerators and the denominators of a search with a height bound below 2 ^ 63 are (Ratpoints.findPoints); the thunk checks, which the sieve of one denominator makes for each denominator (Ratpoints.Sieve.sift), for the array of the sieving thread and its flag stage3_filled, which accepted tests before it fills the array when the stage has primes (n ≠ 0); the counters passed and returned, for the fields n_coprime and n_checks of the sieving thread; a Boolean for the int.)

  • sift.c:452-465: modelled by Ratpoints.Sieve.tailLeg (deviation of Ratpoints.Sieve.tailLeg: the registers a vector of 8 bit arrays, made of zeros, for the array reg[8]; the pointer surv as the array surv and the index base of the first bit array of the tail, past the whole chunks; indices into the rows for the pointers; the size of the local array of the sieve specs for the number sp1 of the moduli; no pragmas that make the compiler unroll the loops over the registers (RP_UNROLL_REGS, sift.c:466-472, excluded); natural numbers for the longs w and off.)

  • sift.c:466-472: excluded (other): RP_UNROLL_REGS, the pragma GCC unroll 8 with which tail_leg makes gcc and clang unroll its loops over the registers before they decide what to keep in registers, empty on other compilers or when given empty; it carries no meaning

  • sift.c:473-496: modelled by Ratpoints.Sieve.tailLeg (deviation of Ratpoints.Sieve.tailLeg: the registers a vector of 8 bit arrays, made of zeros, for the array reg[8]; the pointer surv as the array surv and the index base of the first bit array of the tail, past the whole chunks; indices into the rows for the pointers; the size of the local array of the sieve specs for the number sp1 of the moduli; no pragmas that make the compiler unroll the loops over the registers (RP_UNROLL_REGS, sift.c:466-472, excluded); natural numbers for the longs w and off.)

  • sift.c:498-531: modelled by Ratpoints.Sieve.siftPiece (deviation of Ratpoints.Sieve.siftPiece: the arm of the first stage chosen by a test on the constant Ratpoints.chunk, for the conditional compilation #if (RATPOINTS_CHUNK > 1) && (RATPOINTS_CHUNK <= 16) (sift.c:452, sift.c:575, sift.c:943), which compiles one arm only, and tail_leg with the chunked one; a fresh array of zeros for each piece, for the survivors array of the sieving thread, which every piece reuses, with one bit array more for the alignment, and whose words malloc leaves uninitialized; the piece by its first word number w0 and its number n of bit arrays, for w_low and w_high, and an index for the pointer to its last bit array; the moduli of the first two stages with their rows and offsets as the list specs and the end sp1 of the first stage, for the sieve specs sieves and the number sp1 that the sieving thread keeps, the reciprocals of their moduli as the list mgs, for the array magics of the arguments, and the thunk checks, for the table checks of the third stage and its length nchecks = sp3 - sp2; the class cl as a value, for the pointer cls; integers for the longs of the test small, which stay longs, and a Boolean for its int; the counters cnt passed and returned, for the field n_words of the sieving thread, which counts the n Ratpoints.rbaPack words of the piece (line 548), the product of UInt64s as the C code multiplies the unsigned long by RBA_PACK; the thunk w of the products of the check as an argument, where _ratpoints_check_point computes the products when the first survivor of b reaches it; the delivery r passed and returned, for the pointers info and wk->quit and the count total that _ratpoints_sift0 keeps from zero and returns, and its returns at a stop within the walk through the set bits of a word passed on by the scan (Ratpoints.Sieve.scanPiece); natural numbers and integers for the longs; no measurements of the phases (RP_TIC, RP_TOC, RP_PHASE_TIMING) and no stop after one of them (RP_STOP_AFTER).)

  • sift.c:533-544: excluded (instrumentation): the output under DEBUG at the start of _ratpoints_sift0: the denominator, the number of bit arrays, the 2-adic pattern and the masks

  • sift.c:548-548: modelled by Ratpoints.Sieve.siftPiece (deviation of Ratpoints.Sieve.siftPiece: the arm of the first stage chosen by a test on the constant Ratpoints.chunk, for the conditional compilation #if (RATPOINTS_CHUNK > 1) && (RATPOINTS_CHUNK <= 16) (sift.c:452, sift.c:575, sift.c:943), which compiles one arm only, and tail_leg with the chunked one; a fresh array of zeros for each piece, for the survivors array of the sieving thread, which every piece reuses, with one bit array more for the alignment, and whose words malloc leaves uninitialized; the piece by its first word number w0 and its number n of bit arrays, for w_low and w_high, and an index for the pointer to its last bit array; the moduli of the first two stages with their rows and offsets as the list specs and the end sp1 of the first stage, for the sieve specs sieves and the number sp1 that the sieving thread keeps, the reciprocals of their moduli as the list mgs, for the array magics of the arguments, and the thunk checks, for the table checks of the third stage and its length nchecks = sp3 - sp2; the class cl as a value, for the pointer cls; integers for the longs of the test small, which stay longs, and a Boolean for its int; the counters cnt passed and returned, for the field n_words of the sieving thread, which counts the n Ratpoints.rbaPack words of the piece (line 548), the product of UInt64s as the C code multiplies the unsigned long by RBA_PACK; the thunk w of the products of the check as an argument, where _ratpoints_check_point computes the products when the first survivor of b reaches it; the delivery r passed and returned, for the pointers info and wk->quit and the count total that _ratpoints_sift0 keeps from zero and returns, and its returns at a stop within the walk through the set bits of a word passed on by the scan (Ratpoints.Sieve.scanPiece); natural numbers and integers for the longs; no measurements of the phases (RP_TIC, RP_TOC, RP_PHASE_TIMING) and no stop after one of them (RP_STOP_AFTER).)

  • sift.c:550-573: excluded (instrumentation): the counts of the calls, of the bit arrays and of the bits under RP_PHASE_TIMING and RP_PHASE_COUNTS, the start of the timing of the first stage (RP_TIC) and the output of the cut points under DEBUG, before the first stage

  • sift.c:575-575: modelled by Ratpoints.Sieve.andRowsChunked (deviation of Ratpoints.Sieve.andRowsChunked: no moduli tested by the size of the local array of the sieve specs, for sp1 == 0; the bit arrays set to the class word by a loop that counts up, bit array n - 1 - i at the step i, for the loop that counts down from the last; the class word written into each word of a bit array, for the vector RBA(packed) that get_2adic_info makes once per class (find_points.c:1098) and _ratpoints_sift0 copies into each bit array (bits64, sift.c:519); the end of the whole chunks the index full, for the word number w_high_full, which is also the index of the first bit array of the tail, for the pointer surv after the chunks; natural numbers and integers for the longs.)

  • sift.c:596-606: modelled by Ratpoints.Sieve.chunkStarts (deviation of Ratpoints.Sieve.chunkStarts: a local array of the sieve specs, in which the starts are set, for the sieve specs sieves of the sieving thread, whose field start the C code writes and nothing reads after the first stage; the moduli of the stage with their rows and their reciprocals as two lists, for the first sp1 sieve specs and the array magics from position 0 on; the reduction by the reciprocal under small alone, for small && RP_USE_MOD_MUL, with RP_USE_MOD_MUL the constant 1 of the production build (sift.c:236-238, excluded with the switch of the development builds); the start an index into the row, for the pointer ptr plus the remainder; integers for the longs, the sum a = w_low + offset staying a long where the helper mod reduces it outside small (Ratpoints.Sieve.fitsLong_add); a Boolean for the int small.)

  • sift.c:608-620: modelled by Ratpoints.Sieve.andRowsChunked (deviation of Ratpoints.Sieve.andRowsChunked: no moduli tested by the size of the local array of the sieve specs, for sp1 == 0; the bit arrays set to the class word by a loop that counts up, bit array n - 1 - i at the step i, for the loop that counts down from the last; the class word written into each word of a bit array, for the vector RBA(packed) that get_2adic_info makes once per class (find_points.c:1098) and _ratpoints_sift0 copies into each bit array (bits64, sift.c:519); the end of the whole chunks the index full, for the word number w_high_full, which is also the index of the first bit array of the tail, for the pointer surv after the chunks; natural numbers and integers for the longs.)

  • sift.c:624-624: modelled by Ratpoints.Sieve.andChunks (deviation of Ratpoints.Sieve.andChunks: the index c of the first bit array of the chunk in surv, from 0, for the word number w_low_new, from w_low, and the pointer surv into the survivors, which the loop steps on together, and full the index of the end of the whole chunks, for the word number w_high_full; the stores a loop over the registers, for the code that the build unrolls under #if (RATPOINTS_CHUNK >= k), for k up to 16; the local array of the sieve specs, for the sieve specs of the sieving thread.)

  • sift.c:625-681: modelled by Ratpoints.Sieve.chunkSieve (deviation of Ratpoints.Sieve.chunkSieve: the registers reg0, …, reg15 a vector of chunk bit arrays, made of zeros and then loaded, and the loads and the ands of the registers loops over its bit arrays, for the variables that the build declares and the code that it unrolls under #if (RATPOINTS_CHUNK >= k), for k up to 16; the pointers siv0 and siv1 after the loads and the ands as the start plus chunk, for the pointers that each load and each and steps on by one bit array; indices into the rows for the pointers start and end; the local array of the sieve specs, for the sieve specs of the sieving thread, and its size for the number sp1 of the moduli of the stage; no output under DEBUG.)

  • sift.c:683-683: modelled by Ratpoints.Sieve.wrapStart (deviation of Ratpoints.Sieve.wrapStart: one definition for the loop at its two places, after the first modulus of a chunk and after each further one; indices into the row for the pointers.)

  • sift.c:684-804: modelled by Ratpoints.Sieve.chunkSieve (deviation of Ratpoints.Sieve.chunkSieve: the registers reg0, …, reg15 a vector of chunk bit arrays, made of zeros and then loaded, and the loads and the ands of the registers loops over its bit arrays, for the variables that the build declares and the code that it unrolls under #if (RATPOINTS_CHUNK >= k), for k up to 16; the pointers siv0 and siv1 after the loads and the ands as the start plus chunk, for the pointers that each load and each and steps on by one bit array; indices into the rows for the pointers start and end; the local array of the sieve specs, for the sieve specs of the sieving thread, and its size for the number sp1 of the moduli of the stage; no output under DEBUG.)

  • sift.c:805-805: modelled by Ratpoints.Sieve.wrapStart (deviation of Ratpoints.Sieve.wrapStart: one definition for the loop at its two places, after the first modulus of a chunk and after each further one; indices into the row for the pointers.)

  • sift.c:806-863: modelled by Ratpoints.Sieve.chunkSieve (deviation of Ratpoints.Sieve.chunkSieve: the registers reg0, …, reg15 a vector of chunk bit arrays, made of zeros and then loaded, and the loads and the ands of the registers loops over its bit arrays, for the variables that the build declares and the code that it unrolls under #if (RATPOINTS_CHUNK >= k), for k up to 16; the pointers siv0 and siv1 after the loads and the ands as the start plus chunk, for the pointers that each load and each and steps on by one bit array; indices into the rows for the pointers start and end; the local array of the sieve specs, for the sieve specs of the sieving thread, and its size for the number sp1 of the moduli of the stage; no output under DEBUG.)

  • sift.c:864-913: modelled by Ratpoints.Sieve.andChunks (deviation of Ratpoints.Sieve.andChunks: the index c of the first bit array of the chunk in surv, from 0, for the word number w_low_new, from w_low, and the pointer surv into the survivors, which the loop steps on together, and full the index of the end of the whole chunks, for the word number w_high_full; the stores a loop over the registers, for the code that the build unrolls under #if (RATPOINTS_CHUNK >= k), for k up to 16; the local array of the sieve specs, for the sieve specs of the sieving thread.)

  • sift.c:915-940: modelled by Ratpoints.Sieve.tailLegs (deviation of Ratpoints.Sieve.tailLegs: the conditions on the chunk tested with those on t, for the conditional compilation #if (RATPOINTS_CHUNK > 8), > 4 and > 2; no check at compile time that the chunk is at most 16, the #error of the C code, which its place inside the conditional compilation of the chunked first stage for a chunk up to 16 makes dead code: a chunk above 16 compiles the first stage one row at a time, and the model chooses the arm by the same test (Ratpoints.Sieve.siftPiece, Ratpoints.Sieve.andRows); natural numbers for the longs.)

  • sift.c:941-941: modelled by Ratpoints.Sieve.andRowsChunked (deviation of Ratpoints.Sieve.andRowsChunked: no moduli tested by the size of the local array of the sieve specs, for sp1 == 0; the bit arrays set to the class word by a loop that counts up, bit array n - 1 - i at the step i, for the loop that counts down from the last; the class word written into each word of a bit array, for the vector RBA(packed) that get_2adic_info makes once per class (find_points.c:1098) and _ratpoints_sift0 copies into each bit array (bits64, sift.c:519); the end of the whole chunks the index full, for the word number w_high_full, which is also the index of the first bit array of the tail, for the pointer surv after the chunks; natural numbers and integers for the longs.)

  • sift.c:943-1022: modelled by Ratpoints.Sieve.andRows (deviation of Ratpoints.Sieve.andRows: the bit arrays set to the class word by a loop that counts up, bit array n - 1 - i at the step i, for the loop that counts down from the last; the class word written into each word of a bit array, for the vector RBA(packed) that get_2adic_info makes once per class (find_points.c:1098) and _ratpoints_sift0 copies into each bit array (bits64, sift.c:519, sift.c:954); the moduli of the stage with their rows and their reciprocals as two lists, for the first sp1 sieve specs and the array magics from position 0 on; the value -w_low - offset written out in both reductions, for the long a, which stays a long where the helper mod reduces it outside small (Ratpoints.Sieve.fitsLong_neg_sub); indices for the pointers into the rows and into the survivors, and the number of whole periods and the rest computed before their loops; natural numbers and integers for the longs; a Boolean for the int small; no output under DEBUG.)

  • sift.c:1024-1024: excluded (instrumentation): the end of the timing of the first stage (RP_TOC), empty in the production build

  • sift.c:1030-1041: modelled by Ratpoints.Sieve.siftPiece (deviation of Ratpoints.Sieve.siftPiece: the arm of the first stage chosen by a test on the constant Ratpoints.chunk, for the conditional compilation #if (RATPOINTS_CHUNK > 1) && (RATPOINTS_CHUNK <= 16) (sift.c:452, sift.c:575, sift.c:943), which compiles one arm only, and tail_leg with the chunked one; a fresh array of zeros for each piece, for the survivors array of the sieving thread, which every piece reuses, with one bit array more for the alignment, and whose words malloc leaves uninitialized; the piece by its first word number w0 and its number n of bit arrays, for w_low and w_high, and an index for the pointer to its last bit array; the moduli of the first two stages with their rows and offsets as the list specs and the end sp1 of the first stage, for the sieve specs sieves and the number sp1 that the sieving thread keeps, the reciprocals of their moduli as the list mgs, for the array magics of the arguments, and the thunk checks, for the table checks of the third stage and its length nchecks = sp3 - sp2; the class cl as a value, for the pointer cls; integers for the longs of the test small, which stay longs, and a Boolean for its int; the counters cnt passed and returned, for the field n_words of the sieving thread, which counts the n Ratpoints.rbaPack words of the piece (line 548), the product of UInt64s as the C code multiplies the unsigned long by RBA_PACK; the thunk w of the products of the check as an argument, where _ratpoints_check_point computes the products when the first survivor of b reaches it; the delivery r passed and returned, for the pointers info and wk->quit and the count total that _ratpoints_sift0 keeps from zero and returns, and its returns at a stop within the walk through the set bits of a word passed on by the scan (Ratpoints.Sieve.scanPiece); natural numbers and integers for the longs; no measurements of the phases (RP_TIC, RP_TOC, RP_PHASE_TIMING) and no stop after one of them (RP_STOP_AFTER).)

  • sift.c:1043-1054: excluded (instrumentation): the bit arrays of the piece printed under DEBUG after the first stage and the masks

  • sift.c:1056-1058: modelled by Ratpoints.Sieve.siftPiece (deviation of Ratpoints.Sieve.siftPiece: the arm of the first stage chosen by a test on the constant Ratpoints.chunk, for the conditional compilation #if (RATPOINTS_CHUNK > 1) && (RATPOINTS_CHUNK <= 16) (sift.c:452, sift.c:575, sift.c:943), which compiles one arm only, and tail_leg with the chunked one; a fresh array of zeros for each piece, for the survivors array of the sieving thread, which every piece reuses, with one bit array more for the alignment, and whose words malloc leaves uninitialized; the piece by its first word number w0 and its number n of bit arrays, for w_low and w_high, and an index for the pointer to its last bit array; the moduli of the first two stages with their rows and offsets as the list specs and the end sp1 of the first stage, for the sieve specs sieves and the number sp1 that the sieving thread keeps, the reciprocals of their moduli as the list mgs, for the array magics of the arguments, and the thunk checks, for the table checks of the third stage and its length nchecks = sp3 - sp2; the class cl as a value, for the pointer cls; integers for the longs of the test small, which stay longs, and a Boolean for its int; the counters cnt passed and returned, for the field n_words of the sieving thread, which counts the n Ratpoints.rbaPack words of the piece (line 548), the product of UInt64s as the C code multiplies the unsigned long by RBA_PACK; the thunk w of the products of the check as an argument, where _ratpoints_check_point computes the products when the first survivor of b reaches it; the delivery r passed and returned, for the pointers info and wk->quit and the count total that _ratpoints_sift0 keeps from zero and returns, and its returns at a stop within the walk through the set bits of a word passed on by the scan (Ratpoints.Sieve.scanPiece); natural numbers and integers for the longs; no measurements of the phases (RP_TIC, RP_TOC, RP_PHASE_TIMING) and no stop after one of them (RP_STOP_AFTER).)

  • sift.c:1061-1082: modelled by Ratpoints.Sieve.scanPiece (deviation of Ratpoints.Sieve.scanPiece: indices for the pointers into the survivors, and a scan that holds its position as an index, where ratpoints recovers the word number from a pointer difference; the copy nums of the bit array a vector of Ratpoints.rbaPack words; the sentinel ~zero of every build as Ratpoints.rbaPack words ~~~0, written one at a time; natural numbers and integers for the longs; the counters cnt passed and returned, for the field n_arrays of the sieving thread, which counts one up for each bit array that is not zero (line 1092); the delivery r passed and returned, for the pointers info and wk->quit and the count total of _ratpoints_sift0, and the flag quit tested after each bit array, where the C code returns from _ratpoints_sift0 within the walk through the set bits of a word (Ratpoints.Sieve.walkWord).)

  • sift.c:1083-1083: modelled by Ratpoints.Sieve.secondStage (deviation of Ratpoints.Sieve.secondStage: the moduli of the stage with their rows and their reciprocals as two lists, for the pointers ssp and mg that step through the sieve specs and the array magics from position sp1 on and the count sp2 - sp1, with no bound 2 RATPOINTS_NUM_PRIMES on their number (the length of magics, find_points.c:347), which ratpoints never reaches since each entry of sieve_list owns its own prime (find_points.c:329-331), where the model takes any moduli, which may repeat; one bit array of Ratpoints.rbaPack words, for the vector nums; natural numbers and integers for the longs, and the sum v a natural number for the long that RP_MULMOD converts to an unsigned long, which is not negative under small, and which stays a long where the helper mod reduces it outside small (Ratpoints.Sieve.fitsLong_add); a Boolean for the int small; no count of the ands of the second stage under RP_PHASE_COUNTS, and no output under DEBUG.)

  • sift.c:1084-1084: modelled by Ratpoints.useLongInPhase2 (deviation of Ratpoints.useLongInPhase2: a constant of the model, set here, for the macro that the compiler is given or not (-DUSE_LONG_IN_PHASE_2), which the C code tests with #ifdef and #ifndef.)

  • sift.c:1085-1085: modelled by Ratpoints.Sieve.secondStage (deviation of Ratpoints.Sieve.secondStage: the moduli of the stage with their rows and their reciprocals as two lists, for the pointers ssp and mg that step through the sieve specs and the array magics from position sp1 on and the count sp2 - sp1, with no bound 2 RATPOINTS_NUM_PRIMES on their number (the length of magics, find_points.c:347), which ratpoints never reaches since each entry of sieve_list owns its own prime (find_points.c:329-331), where the model takes any moduli, which may repeat; one bit array of Ratpoints.rbaPack words, for the vector nums; natural numbers and integers for the longs, and the sum v a natural number for the long that RP_MULMOD converts to an unsigned long, which is not negative under small, and which stays a long where the helper mod reduces it outside small (Ratpoints.Sieve.fitsLong_add); a Boolean for the int small; no count of the ands of the second stage under RP_PHASE_COUNTS, and no output under DEBUG.)

  • sift.c:1086-1086: modelled by Ratpoints.useLongInPhase2 (deviation of Ratpoints.useLongInPhase2: a constant of the model, set here, for the macro that the compiler is given or not (-DUSE_LONG_IN_PHASE_2), which the C code tests with #ifdef and #ifndef.)

  • sift.c:1088-1092: modelled by Ratpoints.Sieve.scanPiece (deviation of Ratpoints.Sieve.scanPiece: indices for the pointers into the survivors, and a scan that holds its position as an index, where ratpoints recovers the word number from a pointer difference; the copy nums of the bit array a vector of Ratpoints.rbaPack words; the sentinel ~zero of every build as Ratpoints.rbaPack words ~~~0, written one at a time; natural numbers and integers for the longs; the counters cnt passed and returned, for the field n_arrays of the sieving thread, which counts one up for each bit array that is not zero (line 1092); the delivery r passed and returned, for the pointers info and wk->quit and the count total of _ratpoints_sift0, and the flag quit tested after each bit array, where the C code returns from _ratpoints_sift0 within the walk through the set bits of a word (Ratpoints.Sieve.walkWord).)

  • sift.c:1094-1111: modelled by Ratpoints.Sieve.siftBitArray (deviation of Ratpoints.Sieve.siftBitArray: the arm chosen by the argument useLong, so that the guards run both in the same build, for the arm that the build compiles (#ifdef USE_LONG_IN_PHASE_2), each arm a function of its own; a function of its own for the body of the loop of the scan over one bit array; no counts under RP_PHASE_COUNTS, no stop after a phase (RP_STOP_AFTER), and no output under DEBUG.)

  • sift.c:1113-1113: modelled by Ratpoints.useLongInPhase2 (deviation of Ratpoints.useLongInPhase2: a constant of the model, set here, for the macro that the compiler is given or not (-DUSE_LONG_IN_PHASE_2), which the C code tests with #ifdef and #ifndef.)

  • sift.c:1126-1134: modelled by Ratpoints.Sieve.siftBitArrayByWords (deviation of Ratpoints.Sieve.siftBitArrayByWords: the stride, the first numerator and the steps as natural numbers and integers, the powers 2 ^ k for the shifts 1L << k, RBA_LENGTH << k and LONG_LENGTH << k, the last two of which stay ints, while the first numerators of the words, the numerators of bits of the bit arrays of a height bound below 2 ^ 63, stay longs (Ratpoints.Sieve.NumClass.fitsLong_numerator); the words of the bit array read as entries of the vector, for EXT; natural numbers and integers for the longs; the delivery r passed and returned, for the pointers info and wk->quit and the count total of _ratpoints_sift0, and the flag quit tested after each walk through the set bits of a word, where the C code returns from _ratpoints_sift0 within the walk (Ratpoints.Sieve.walkWord); no counts under RP_PHASE_COUNTS and no stop after a phase (RP_STOP_AFTER).)

  • sift.c:1135-1136: modelled by Ratpoints.Sieve.secondStageWord (deviation of Ratpoints.Sieve.secondStageWord: the moduli of the stage with their rows and their reciprocals as two lists, for the pointers sspk and mg that step through the sieve specs and the array magics from position sp1 on and the count sp2 - sp1, with no bound 2 RATPOINTS_NUM_PRIMES on their number (the length of magics, find_points.c:347), which ratpoints never reaches since each entry of sieve_list owns its own prime (find_points.c:329-331), where the model takes any moduli, which may repeat; natural numbers and integers for the longs, and the sum v a natural number for the long that RP_MULMOD converts to an unsigned long, which is not negative under small, and which stays a long where the helper mod reduces it outside small (Ratpoints.Sieve.fitsLong_add); a Boolean for the int small; no count of the ands of the second stage under RP_PHASE_COUNTS.)

  • sift.c:1137-1139: modelled by Ratpoints.Sieve.siftBitArrayByWords (deviation of Ratpoints.Sieve.siftBitArrayByWords: the stride, the first numerator and the steps as natural numbers and integers, the powers 2 ^ k for the shifts 1L << k, RBA_LENGTH << k and LONG_LENGTH << k, the last two of which stay ints, while the first numerators of the words, the numerators of bits of the bit arrays of a height bound below 2 ^ 63, stay longs (Ratpoints.Sieve.NumClass.fitsLong_numerator); the words of the bit array read as entries of the vector, for EXT; natural numbers and integers for the longs; the delivery r passed and returned, for the pointers info and wk->quit and the count total of _ratpoints_sift0, and the flag quit tested after each walk through the set bits of a word, where the C code returns from _ratpoints_sift0 within the walk (Ratpoints.Sieve.walkWord); no counts under RP_PHASE_COUNTS and no stop after a phase (RP_STOP_AFTER).)

  • sift.c:1141-1152: modelled by Ratpoints.Sieve.secondStageWord (deviation of Ratpoints.Sieve.secondStageWord: the moduli of the stage with their rows and their reciprocals as two lists, for the pointers sspk and mg that step through the sieve specs and the array magics from position sp1 on and the count sp2 - sp1, with no bound 2 RATPOINTS_NUM_PRIMES on their number (the length of magics, find_points.c:347), which ratpoints never reaches since each entry of sieve_list owns its own prime (find_points.c:329-331), where the model takes any moduli, which may repeat; natural numbers and integers for the longs, and the sum v a natural number for the long that RP_MULMOD converts to an unsigned long, which is not negative under small, and which stays a long where the helper mod reduces it outside small (Ratpoints.Sieve.fitsLong_add); a Boolean for the int small; no count of the ands of the second stage under RP_PHASE_COUNTS.)

  • sift.c:1154-1159: modelled by Ratpoints.Sieve.siftBitArrayByWords (deviation of Ratpoints.Sieve.siftBitArrayByWords: the stride, the first numerator and the steps as natural numbers and integers, the powers 2 ^ k for the shifts 1L << k, RBA_LENGTH << k and LONG_LENGTH << k, the last two of which stay ints, while the first numerators of the words, the numerators of bits of the bit arrays of a height bound below 2 ^ 63, stay longs (Ratpoints.Sieve.NumClass.fitsLong_numerator); the words of the bit array read as entries of the vector, for EXT; natural numbers and integers for the longs; the delivery r passed and returned, for the pointers info and wk->quit and the count total of _ratpoints_sift0, and the flag quit tested after each walk through the set bits of a word, where the C code returns from _ratpoints_sift0 within the walk (Ratpoints.Sieve.walkWord); no counts under RP_PHASE_COUNTS and no stop after a phase (RP_STOP_AFTER).)

  • sift.c:1161-1171: modelled by Ratpoints.Sieve.walkWord (deviation of Ratpoints.Sieve.walkWord: the lowest set bit by the loop of RP_CTZL for a compiler without the builtin (Ratpoints.Sieve.ctz); one definition for the body at the three places of the extraction, the first word of a bit array, the others, and a word of the arm of the second stage for one word at a time; natural numbers and integers for the longs; the delivery r passed and returned, for the pointers info and wk->quit and the count total of _ratpoints_sift0, to which RP_CHECK_POINT adds the count of the check (lines 1168, 1240, 1250, 1279, 1287); the return after a stop (lines 1169, 1241, 1251, 1280, 1288) a return from the walk, which its callers pass on, testing the flag after it (Ratpoints.Sieve.siftBitArrayByWords, Ratpoints.Sieve.siftBitArrayWhole, then Ratpoints.Sieve.scanPiece after the bit array), where the C code returns from _ratpoints_sift0; the counters passed and returned, for the field n_bits of the sieving thread (lines 1166, 1233, 1271); no counts under RP_PHASE_COUNTS; no output under DEBUG.)

  • sift.c:1172-1173: modelled by Ratpoints.Sieve.siftBitArrayByWords (deviation of Ratpoints.Sieve.siftBitArrayByWords: the stride, the first numerator and the steps as natural numbers and integers, the powers 2 ^ k for the shifts 1L << k, RBA_LENGTH << k and LONG_LENGTH << k, the last two of which stay ints, while the first numerators of the words, the numerators of bits of the bit arrays of a height bound below 2 ^ 63, stay longs (Ratpoints.Sieve.NumClass.fitsLong_numerator); the words of the bit array read as entries of the vector, for EXT; natural numbers and integers for the longs; the delivery r passed and returned, for the pointers info and wk->quit and the count total of _ratpoints_sift0, and the flag quit tested after each walk through the set bits of a word, where the C code returns from _ratpoints_sift0 within the walk (Ratpoints.Sieve.walkWord); no counts under RP_PHASE_COUNTS and no stop after a phase (RP_STOP_AFTER).)

  • sift.c:1174-1174: modelled by Ratpoints.useLongInPhase2 (deviation of Ratpoints.useLongInPhase2: a constant of the model, set here, for the macro that the compiler is given or not (-DUSE_LONG_IN_PHASE_2), which the C code tests with #ifdef and #ifndef.)

  • sift.c:1175-1202: modelled by Ratpoints.Sieve.secondStage (deviation of Ratpoints.Sieve.secondStage: the moduli of the stage with their rows and their reciprocals as two lists, for the pointers ssp and mg that step through the sieve specs and the array magics from position sp1 on and the count sp2 - sp1, with no bound 2 RATPOINTS_NUM_PRIMES on their number (the length of magics, find_points.c:347), which ratpoints never reaches since each entry of sieve_list owns its own prime (find_points.c:329-331), where the model takes any moduli, which may repeat; one bit array of Ratpoints.rbaPack words, for the vector nums; natural numbers and integers for the longs, and the sum v a natural number for the long that RP_MULMOD converts to an unsigned long, which is not negative under small, and which stays a long where the helper mod reduces it outside small (Ratpoints.Sieve.fitsLong_add); a Boolean for the int small; no count of the ands of the second stage under RP_PHASE_COUNTS, and no output under DEBUG.)

  • sift.c:1204-1210: modelled by Ratpoints.Sieve.siftBitArrayWhole (deviation of Ratpoints.Sieve.siftBitArrayWhole: the stride, the first numerator and the steps as natural numbers and integers, the powers 2 ^ k for the shifts 1L << k, RBA_LENGTH << k and LONG_LENGTH << k, the last two of which stay ints, while the first numerators of the words, the numerators of bits of the bit arrays of a height bound below 2 ^ 63, stay longs (Ratpoints.Sieve.NumClass.fitsLong_numerator); the words of the bit array read as entries of the vector, for EXT0 and EXT; natural numbers and integers for the longs; the delivery r passed and returned, for the pointers info and wk->quit and the count total of _ratpoints_sift0, and the flag quit tested after each walk through the set bits of a word and the rest of the bit array left at a stop, where the C code returns from _ratpoints_sift0 within the walk (Ratpoints.Sieve.walkWord); no counts under RP_PHASE_COUNTS and no stop after a phase (RP_STOP_AFTER).)

  • sift.c:1213-1226: modelled by Ratpoints.Sieve.siftBitArrayWhole (deviation of Ratpoints.Sieve.siftBitArrayWhole: the stride, the first numerator and the steps as natural numbers and integers, the powers 2 ^ k for the shifts 1L << k, RBA_LENGTH << k and LONG_LENGTH << k, the last two of which stay ints, while the first numerators of the words, the numerators of bits of the bit arrays of a height bound below 2 ^ 63, stay longs (Ratpoints.Sieve.NumClass.fitsLong_numerator); the words of the bit array read as entries of the vector, for EXT0 and EXT; natural numbers and integers for the longs; the delivery r passed and returned, for the pointers info and wk->quit and the count total of _ratpoints_sift0, and the flag quit tested after each walk through the set bits of a word and the rest of the bit array left at a stop, where the C code returns from _ratpoints_sift0 within the walk (Ratpoints.Sieve.walkWord); no counts under RP_PHASE_COUNTS and no stop after a phase (RP_STOP_AFTER).)

  • sift.c:1227-1255: modelled by Ratpoints.Sieve.walkWord (deviation of Ratpoints.Sieve.walkWord: the lowest set bit by the loop of RP_CTZL for a compiler without the builtin (Ratpoints.Sieve.ctz); one definition for the body at the three places of the extraction, the first word of a bit array, the others, and a word of the arm of the second stage for one word at a time; natural numbers and integers for the longs; the delivery r passed and returned, for the pointers info and wk->quit and the count total of _ratpoints_sift0, to which RP_CHECK_POINT adds the count of the check (lines 1168, 1240, 1250, 1279, 1287); the return after a stop (lines 1169, 1241, 1251, 1280, 1288) a return from the walk, which its callers pass on, testing the flag after it (Ratpoints.Sieve.siftBitArrayByWords, Ratpoints.Sieve.siftBitArrayWhole, then Ratpoints.Sieve.scanPiece after the bit array), where the C code returns from _ratpoints_sift0; the counters passed and returned, for the field n_bits of the sieving thread (lines 1166, 1233, 1271); no counts under RP_PHASE_COUNTS; no output under DEBUG.)

  • sift.c:1257-1264: modelled by Ratpoints.Sieve.siftBitArrayWhole (deviation of Ratpoints.Sieve.siftBitArrayWhole: the stride, the first numerator and the steps as natural numbers and integers, the powers 2 ^ k for the shifts 1L << k, RBA_LENGTH << k and LONG_LENGTH << k, the last two of which stay ints, while the first numerators of the words, the numerators of bits of the bit arrays of a height bound below 2 ^ 63, stay longs (Ratpoints.Sieve.NumClass.fitsLong_numerator); the words of the bit array read as entries of the vector, for EXT0 and EXT; natural numbers and integers for the longs; the delivery r passed and returned, for the pointers info and wk->quit and the count total of _ratpoints_sift0, and the flag quit tested after each walk through the set bits of a word and the rest of the bit array left at a stop, where the C code returns from _ratpoints_sift0 within the walk (Ratpoints.Sieve.walkWord); no counts under RP_PHASE_COUNTS and no stop after a phase (RP_STOP_AFTER).)

  • sift.c:1265-1292: modelled by Ratpoints.Sieve.walkWord (deviation of Ratpoints.Sieve.walkWord: the lowest set bit by the loop of RP_CTZL for a compiler without the builtin (Ratpoints.Sieve.ctz); one definition for the body at the three places of the extraction, the first word of a bit array, the others, and a word of the arm of the second stage for one word at a time; natural numbers and integers for the longs; the delivery r passed and returned, for the pointers info and wk->quit and the count total of _ratpoints_sift0, to which RP_CHECK_POINT adds the count of the check (lines 1168, 1240, 1250, 1279, 1287); the return after a stop (lines 1169, 1241, 1251, 1280, 1288) a return from the walk, which its callers pass on, testing the flag after it (Ratpoints.Sieve.siftBitArrayByWords, Ratpoints.Sieve.siftBitArrayWhole, then Ratpoints.Sieve.scanPiece after the bit array), where the C code returns from _ratpoints_sift0; the counters passed and returned, for the field n_bits of the sieving thread (lines 1166, 1233, 1271); no counts under RP_PHASE_COUNTS; no output under DEBUG.)

  • sift.c:1293-1296: modelled by Ratpoints.Sieve.siftBitArrayWhole (deviation of Ratpoints.Sieve.siftBitArrayWhole: the stride, the first numerator and the steps as natural numbers and integers, the powers 2 ^ k for the shifts 1L << k, RBA_LENGTH << k and LONG_LENGTH << k, the last two of which stay ints, while the first numerators of the words, the numerators of bits of the bit arrays of a height bound below 2 ^ 63, stay longs (Ratpoints.Sieve.NumClass.fitsLong_numerator); the words of the bit array read as entries of the vector, for EXT0 and EXT; natural numbers and integers for the longs; the delivery r passed and returned, for the pointers info and wk->quit and the count total of _ratpoints_sift0, and the flag quit tested after each walk through the set bits of a word and the rest of the bit array left at a stop, where the C code returns from _ratpoints_sift0 within the walk (Ratpoints.Sieve.walkWord); no counts under RP_PHASE_COUNTS and no stop after a phase (RP_STOP_AFTER).)

  • sift.c:1297-1297: modelled by Ratpoints.useLongInPhase2 (deviation of Ratpoints.useLongInPhase2: a constant of the model, set here, for the macro that the compiler is given or not (-DUSE_LONG_IN_PHASE_2), which the C code tests with #ifdef and #ifndef.)

  • sift.c:1298-1299: modelled by Ratpoints.Sieve.scanPiece (deviation of Ratpoints.Sieve.scanPiece: indices for the pointers into the survivors, and a scan that holds its position as an index, where ratpoints recovers the word number from a pointer difference; the copy nums of the bit array a vector of Ratpoints.rbaPack words; the sentinel ~zero of every build as Ratpoints.rbaPack words ~~~0, written one at a time; natural numbers and integers for the longs; the counters cnt passed and returned, for the field n_arrays of the sieving thread, which counts one up for each bit array that is not zero (line 1092); the delivery r passed and returned, for the pointers info and wk->quit and the count total of _ratpoints_sift0, and the flag quit tested after each bit array, where the C code returns from _ratpoints_sift0 within the walk through the set bits of a word (Ratpoints.Sieve.walkWord).)

  • sift.c:1300-1305: modelled by Ratpoints.Sieve.siftPiece (deviation of Ratpoints.Sieve.siftPiece: the arm of the first stage chosen by a test on the constant Ratpoints.chunk, for the conditional compilation #if (RATPOINTS_CHUNK > 1) && (RATPOINTS_CHUNK <= 16) (sift.c:452, sift.c:575, sift.c:943), which compiles one arm only, and tail_leg with the chunked one; a fresh array of zeros for each piece, for the survivors array of the sieving thread, which every piece reuses, with one bit array more for the alignment, and whose words malloc leaves uninitialized; the piece by its first word number w0 and its number n of bit arrays, for w_low and w_high, and an index for the pointer to its last bit array; the moduli of the first two stages with their rows and offsets as the list specs and the end sp1 of the first stage, for the sieve specs sieves and the number sp1 that the sieving thread keeps, the reciprocals of their moduli as the list mgs, for the array magics of the arguments, and the thunk checks, for the table checks of the third stage and its length nchecks = sp3 - sp2; the class cl as a value, for the pointer cls; integers for the longs of the test small, which stay longs, and a Boolean for its int; the counters cnt passed and returned, for the field n_words of the sieving thread, which counts the n Ratpoints.rbaPack words of the piece (line 548), the product of UInt64s as the C code multiplies the unsigned long by RBA_PACK; the thunk w of the products of the check as an argument, where _ratpoints_check_point computes the products when the first survivor of b reaches it; the delivery r passed and returned, for the pointers info and wk->quit and the count total that _ratpoints_sift0 keeps from zero and returns, and its returns at a stop within the walk through the set bits of a word passed on by the scan (Ratpoints.Sieve.scanPiece); natural numbers and integers for the longs; no measurements of the phases (RP_TIC, RP_TOC, RP_PHASE_TIMING) and no stop after one of them (RP_STOP_AFTER).)

init.c

  • init.c:30-30: excluded (other): the include of the private header; the model has no headers

  • init.c:42-46: modelled by Ratpoints.Sieve.initBit (deviation of Ratpoints.Sieve.initBit: the form of the production builds, where RP_INIT_BRANCH is not set; a Boolean for the int entry of is_f_square, which is 0 or 1.)

  • init.c:62-63: modelled by Ratpoints.Sieve.initFourDecl (deviation of Ratpoints.Sieve.initFourDecl: the form of the production builds, where RP_INIT_ONEWAY is not set; the residues returned, for the variables that the macro declares in its caller; natural numbers for the longs.)

  • init.c:64-64: modelled by Ratpoints.Sieve.initFourLoop (deviation of Ratpoints.Sieve.initFourLoop: the form of the production builds, where RP_INIT_ONEWAY is not set; the table, the prime, the step, the word, the residues and the bounds as arguments and the word, the bit and the residues returned, for the variables of its caller that the macro reads and writes; Booleans for the int entries of is_f_square; the steps ab += d4; if (ab >= p) ab -= p; as conditional values.)

  • init.c:65-70: modelled by Ratpoints.Sieve.initFourDecl (deviation of Ratpoints.Sieve.initFourDecl: the form of the production builds, where RP_INIT_ONEWAY is not set; the residues returned, for the variables that the macro declares in its caller; natural numbers for the longs.)

  • init.c:72-83: modelled by Ratpoints.Sieve.initFourLoop (deviation of Ratpoints.Sieve.initFourLoop: the form of the production builds, where RP_INIT_ONEWAY is not set; the table, the prime, the step, the word, the residues and the bounds as arguments and the word, the bit and the residues returned, for the variables of its caller that the macro reads and writes; Booleans for the int entries of is_f_square; the steps ab += d4; if (ab >= p) ab -= p; as conditional values.)

  • init.c:88-93: excluded (instrumentation): RP_INIT_NOACC, a probe for bench_init that leaves out computing the pattern of a row; the tables it produces are wrong

  • init.c:97-98: excluded (instrumentation): RP_INIT_NOREP, a probe for bench_init that leaves out replicating a row over the words of a bit array; the tables it produces are wrong

  • init.c:99-111: modelled by Ratpoints.Sieve.initReplicate (deviation of Ratpoints.Sieve.initReplicate: the row passed and returned, for the pointer si of its caller.)

  • init.c:118-125: modelled by Ratpoints.Sieve.sieveInit1 (deviation of Ratpoints.Sieve.sieveInit1: one function for every prime below 64, the prime that of its tables, for the function that the build generates for each prime with the prime a constant (init_sieve.h); the tables of the prime and the reference to its entry (Ratpoints.Sieve.EntryRef) as arguments, for the sieve entry se from which the C code reads them and into which it stores the row, and the store of the tables of the rows of the run passed and returned, for the arrays sieve of the entries; the row stored plainly, for the release store of RP_PUBLISH in a build with threads, which the model does not have; no copy pattern of help0, which the C code shifts for help1.)

  • init.c:126-129: modelled by Ratpoints.Sieve.sieve1Rows (deviation of Ratpoints.Sieve.sieve1Rows: ldp, p1, diff_shift and diff computed here, for the variables at the head of the function; the mask p1 & LONG_MASK as the remainder by 64; a fresh vector of (p + chunk - 1) rbaPack words, for the space that the builder takes from the buffer of the tables (ba_next); natural numbers for the longs.)

  • init.c:130-130: modelled by Ratpoints.Sieve.sieveInit1 (deviation of Ratpoints.Sieve.sieveInit1: one function for every prime below 64, the prime that of its tables, for the function that the build generates for each prime with the prime a constant (init_sieve.h); the tables of the prime and the reference to its entry (Ratpoints.Sieve.EntryRef) as arguments, for the sieve entry se from which the C code reads them and into which it stores the row, and the store of the tables of the rows of the run passed and returned, for the arrays sieve of the entries; the row stored plainly, for the release store of RP_PUBLISH in a build with threads, which the model does not have; no copy pattern of help0, which the C code shifts for help1.)

  • init.c:131-143: modelled by Ratpoints.Sieve.sieve1Pattern (deviation of Ratpoints.Sieve.sieve1Pattern: the steps ab += d; if (ab >= p) ab -= p; as conditional values; the results of the loop of four bits read as the components of its tuple; natural numbers for the longs.)

  • init.c:144-159: modelled by Ratpoints.Sieve.sieveInit1 (deviation of Ratpoints.Sieve.sieveInit1: one function for every prime below 64, the prime that of its tables, for the function that the build generates for each prime with the prime a constant (init_sieve.h); the tables of the prime and the reference to its entry (Ratpoints.Sieve.EntryRef) as arguments, for the sieve entry se from which the C code reads them and into which it stores the row, and the store of the tables of the rows of the run passed and returned, for the arrays sieve of the entries; the row stored plainly, for the release store of RP_PUBLISH in a build with threads, which the model does not have; no copy pattern of help0, which the C code shifts for help1.)

  • init.c:160-177: modelled by Ratpoints.Sieve.sieve1Rows (deviation of Ratpoints.Sieve.sieve1Rows: ldp, p1, diff_shift and diff computed here, for the variables at the head of the function; the mask p1 & LONG_MASK as the remainder by 64; a fresh vector of (p + chunk - 1) rbaPack words, for the space that the builder takes from the buffer of the tables (ba_next); natural numbers for the longs.)

  • init.c:178-183: modelled by Ratpoints.Sieve.sieveInit1 (deviation of Ratpoints.Sieve.sieveInit1: one function for every prime below 64, the prime that of its tables, for the function that the build generates for each prime with the prime a constant (init_sieve.h); the tables of the prime and the reference to its entry (Ratpoints.Sieve.EntryRef) as arguments, for the sieve entry se from which the C code reads them and into which it stores the row, and the store of the tables of the rows of the run passed and returned, for the arrays sieve of the entries; the row stored plainly, for the release store of RP_PUBLISH in a build with threads, which the model does not have; no copy pattern of help0, which the C code shifts for help1.)

  • init.c:186-194: modelled by Ratpoints.Sieve.sieveInit2 (deviation of Ratpoints.Sieve.sieveInit2: one function for every prime above 64, the prime that of its tables, for the function that the build generates for each prime with the prime a constant (init_sieve.h); the tables of the prime and the reference to its entry (Ratpoints.Sieve.EntryRef) as arguments, for the sieve entry se from which the C code reads them and into which it stores the row, and the store of the tables of the rows of the run passed and returned, for the arrays sieve of the entries; the words help a fresh vector, which the loop clears from the last, for the array whose words the function leaves unset until it clears them; the row stored plainly, for the release store of RP_PUBLISH in a build with threads, which the model does not have.)

  • init.c:195-196: modelled by Ratpoints.Sieve.sieve2Rows (deviation of Ratpoints.Sieve.sieve2Rows: the words help passed, for the array of the function; diff_shift and diff computed here, for the variables at the head of the function, and wp where it is used, for the variable of the function; a fresh vector of (p + chunk - 1) rbaPack words, for the space that the builder takes from the buffer of the tables (ba_next); the shift by LONG_SHIFT and the mask by LONG_MASK as the division and the remainder by 64.)

  • init.c:197-203: modelled by Ratpoints.Sieve.sieveInit2 (deviation of Ratpoints.Sieve.sieveInit2: one function for every prime above 64, the prime that of its tables, for the function that the build generates for each prime with the prime a constant (init_sieve.h); the tables of the prime and the reference to its entry (Ratpoints.Sieve.EntryRef) as arguments, for the sieve entry se from which the C code reads them and into which it stores the row, and the store of the tables of the rows of the run passed and returned, for the arrays sieve of the entries; the words help a fresh vector, which the loop clears from the last, for the array whose words the function leaves unset until it clears them; the row stored plainly, for the release store of RP_PUBLISH in a build with threads, which the model does not have.)

  • init.c:204-208: modelled by Ratpoints.Sieve.sieve2Pattern (deviation of Ratpoints.Sieve.sieve2Pattern: the words help passed and returned, for the array of the function; ⌊p / 64⌋ computed where it is used, for the variable wp; natural numbers for the longs.)

  • init.c:209-216: modelled by Ratpoints.Sieve.sieve2Word (deviation of Ratpoints.Sieve.sieve2Word: the residues of the lanes passed and returned, for the variables of the function; the steps ab += d; if (ab >= p) ab -= p; as conditional values; the results of the loop of four bits read as the components of its tuple; natural numbers for the longs.)

  • init.c:217-219: modelled by Ratpoints.Sieve.sieve2Pattern (deviation of Ratpoints.Sieve.sieve2Pattern: the words help passed and returned, for the array of the function; ⌊p / 64⌋ computed where it is used, for the variable wp; natural numbers for the longs.)

  • init.c:220-238: modelled by Ratpoints.Sieve.sieve2Rows (deviation of Ratpoints.Sieve.sieve2Rows: the words help passed, for the array of the function; diff_shift and diff computed here, for the variables at the head of the function, and wp where it is used, for the variable of the function; a fresh vector of (p + chunk - 1) rbaPack words, for the space that the builder takes from the buffer of the tables (ba_next); the shift by LONG_SHIFT and the mask by LONG_MASK as the division and the remainder by 64.)

  • init.c:239-244: modelled by Ratpoints.Sieve.sieveInit2 (deviation of Ratpoints.Sieve.sieveInit2: one function for every prime above 64, the prime that of its tables, for the function that the build generates for each prime with the prime a constant (init_sieve.h); the tables of the prime and the reference to its entry (Ratpoints.Sieve.EntryRef) as arguments, for the sieve entry se from which the C code reads them and into which it stores the row, and the store of the tables of the rows of the run passed and returned, for the arrays sieve of the entries; the words help a fresh vector, which the loop clears from the last, for the array whose words the function leaves unset until it clears them; the row stored plainly, for the release store of RP_PUBLISH in a build with threads, which the model does not have.)

  • init.c:246-246: modelled by Ratpoints.Sieve.sieveInit (deviation of Ratpoints.Sieve.sieveInit: a function of p, for the entry of p in the table of the pointers to the functions that the build generates, one for each prime, and that init.c includes; the kind of the function, for the pointer to it.)

  • init.c:259-267: modelled by Ratpoints.Sieve.layOutPattern (deviation of Ratpoints.Sieve.layOutPattern: the words rep a fresh vector of RP_MODWORDS + 2 zeros, for the array whose first words words lay_out_pattern clears and whose other words it leaves unset and never reads; a fresh vector of (m + chunk - 1) rbaPack words for the row, for the space that it takes from the buffer of the tables (ba_next); the step of the offset as a conditional value; the shifts by LONG_SHIFT and the masks by LONG_MASK as divisions and remainders by 64.)

  • init.c:268-279: modelled by Ratpoints.Sieve.repeatPattern (deviation of Ratpoints.Sieve.repeatPattern: the words rep passed and returned, for the array of lay_out_pattern; the two loops as while loops, for the for loops that step o by m and test i against two bounds; the or-ing into the next word as a conditional value; the shifts by LONG_SHIFT and the masks by LONG_MASK as divisions and remainders by 64.)

  • init.c:280-297: modelled by Ratpoints.Sieve.layOutPattern (deviation of Ratpoints.Sieve.layOutPattern: the words rep a fresh vector of RP_MODWORDS + 2 zeros, for the array whose first words words lay_out_pattern clears and whose other words it leaves unset and never reads; a fresh vector of (m + chunk - 1) rbaPack words for the row, for the space that it takes from the buffer of the tables (ba_next); the step of the offset as a conditional value; the shifts by LONG_SHIFT and the masks by LONG_MASK as divisions and remainders by 64.)

  • init.c:299-353: excluded (instrumentation): RP_VERIFY_MODULI, a debugging check, compiled only with -DRP_VERIFY_MODULI: verify_row, which compares a row of a prime power or a product with F(N, b), factor by factor, and aborts on a mismatch

  • init.c:359-368: modelled by Ratpoints.Sieve.sieveInitPower (deviation of Ratpoints.Sieve.sieveInitPower: the tables of the prime power and the reference to its entry (Ratpoints.Sieve.EntryRef) as arguments, for the sieve entry se whose field pw points to the tables and into which the C code stores the row, and the store of the tables of rows of the run passed and returned, for the arrays sieve of the entries; the pattern a fresh array, which the loop clears, for the array whose words the function leaves unset until it clears them; the row stored plainly, for the release store of RP_PUBLISH in a build with threads, which the model does not have.)

  • init.c:369-375: modelled by Ratpoints.Sieve.powerPatternUnit (deviation of Ratpoints.Sieve.powerPatternUnit: the pattern passed and returned, for the array of the function; the step r += binv; if (r >= m) r -= m; as a conditional value; natural numbers for the longs.)

  • init.c:376-377: modelled by Ratpoints.Sieve.sieveInitPower (deviation of Ratpoints.Sieve.sieveInitPower: the tables of the prime power and the reference to its entry (Ratpoints.Sieve.EntryRef) as arguments, for the sieve entry se whose field pw points to the tables and into which the C code stores the row, and the store of the tables of rows of the run passed and returned, for the arrays sieve of the entries; the pattern a fresh array, which the loop clears, for the array whose words the function leaves unset until it clears them; the row stored plainly, for the release store of RP_PUBLISH in a build with threads, which the model does not have.)

  • init.c:378-385: modelled by Ratpoints.Sieve.powerPatternNonunit (deviation of Ratpoints.Sieve.powerPatternNonunit: the pattern passed and returned, for the array of the function; natural numbers for the longs and unsigned longs, the product b inv[x] below m ^ 2.)

  • init.c:386-387: modelled by Ratpoints.Sieve.sieveInitPower (deviation of Ratpoints.Sieve.sieveInitPower: the tables of the prime power and the reference to its entry (Ratpoints.Sieve.EntryRef) as arguments, for the sieve entry se whose field pw points to the tables and into which the C code stores the row, and the store of the tables of rows of the run passed and returned, for the arrays sieve of the entries; the pattern a fresh array, which the loop clears, for the array whose words the function leaves unset until it clears them; the row stored plainly, for the release store of RP_PUBLISH in a build with threads, which the model does not have.)

  • init.c:388-390: excluded (instrumentation): RP_VERIFY_MODULI, a debugging check, compiled only with -DRP_VERIFY_MODULI, that compares every row of a prime power with F(N, b) (verify_row) and aborts on a mismatch

  • init.c:391-393: modelled by Ratpoints.Sieve.sieveInitPower (deviation of Ratpoints.Sieve.sieveInitPower: the tables of the prime power and the reference to its entry (Ratpoints.Sieve.EntryRef) as arguments, for the sieve entry se whose field pw points to the tables and into which the C code stores the row, and the store of the tables of rows of the run passed and returned, for the arrays sieve of the entries; the pattern a fresh array, which the loop clears, for the array whose words the function leaves unset until it clears them; the row stored plainly, for the release store of RP_PUBLISH in a build with threads, which the model does not have.)

  • init.c:399-406: modelled by Ratpoints.Sieve.sieveInitProduct (deviation of Ratpoints.Sieve.sieveInitProduct: the store of the tables of rows passed and returned, for the entries of the factors that the C code reaches through the pointers factor and for the entry se into which it stores the row; a fresh vector of (m + chunk - 1) rbaPack words, for the space that the builder takes from the buffer of the tables (ba_next) after the rows of the factors; the row stored plainly, for the release store of RP_PUBLISH in a build with threads, which the model does not have; the number of the factors the length of their list, for the count nf.)

  • init.c:407-414: modelled by Ratpoints.Sieve.factorRows (deviation of Ratpoints.Sieve.factorRows: the rows of the factors an array returned with the store, for the array frow of the function and the tables of rows in the entries of the factors; the row read plainly, for the acquire load RP_ACQUIRE of a build with threads, which the model does not have; the number of the factors the length of their list, for the count nf.)

  • init.c:415-418: modelled by Ratpoints.Sieve.sieveInitProduct (deviation of Ratpoints.Sieve.sieveInitProduct: the store of the tables of rows passed and returned, for the entries of the factors that the C code reaches through the pointers factor and for the entry se into which it stores the row; a fresh vector of (m + chunk - 1) rbaPack words, for the space that the builder takes from the buffer of the tables (ba_next) after the rows of the factors; the row stored plainly, for the release store of RP_PUBLISH in a build with threads, which the model does not have; the number of the factors the length of their list, for the count nf.)

  • init.c:419-423: modelled by Ratpoints.Sieve.productCopy (deviation of Ratpoints.Sieve.productCopy: the row passed and returned, for the pointer of the function; the loop over x as a while loop, for the for loop that steps x by q; the row of the factor as the vector of its words, which the store of a bit array reads.)

  • init.c:424-429: modelled by Ratpoints.Sieve.productAnd (deviation of Ratpoints.Sieve.productAnd: the row passed and returned, for the pointer of the function; the loop over x as a while loop, for the for loop that steps x by q; the number of the factors the length of their list, for the count nf.)

  • init.c:430-430: modelled by Ratpoints.Sieve.sieveInitProduct (deviation of Ratpoints.Sieve.sieveInitProduct: the store of the tables of rows passed and returned, for the entries of the factors that the C code reaches through the pointers factor and for the entry se into which it stores the row; a fresh vector of (m + chunk - 1) rbaPack words, for the space that the builder takes from the buffer of the tables (ba_next) after the rows of the factors; the row stored plainly, for the release store of RP_PUBLISH in a build with threads, which the model does not have; the number of the factors the length of their list, for the count nf.)

  • init.c:431-442: excluded (instrumentation): RP_VERIFY_MODULI, a debugging check, compiled only with -DRP_VERIFY_MODULI, that compares every row of a product with F(N, b), factor by factor (verify_row), and aborts on a mismatch

  • init.c:443-445: modelled by Ratpoints.Sieve.sieveInitProduct (deviation of Ratpoints.Sieve.sieveInitProduct: the store of the tables of rows passed and returned, for the entries of the factors that the C code reaches through the pointers factor and for the entry se into which it stores the row; a fresh vector of (m + chunk - 1) rbaPack words, for the space that the builder takes from the buffer of the tables (ba_next) after the rows of the factors; the row stored plainly, for the release store of RP_PUBLISH in a build with threads, which the model does not have; the number of the factors the length of their list, for the count nf.)

sturm.c

  • sturm.c:29-32: excluded (other): the includes of math.h, stdlib.h and the header of the library; the model has no headers

  • sturm.c:67-84: modelled by Ratpoints.Sturm.evalSign (deviation of Ratpoints.Sturm.evalSign: the row as an array of integers, for the GMP integers cofs and the long degree, which is the size of the array less one; integers for the GMP integers work[0] and work[1], the multiplication by a power of 2 for mpz_mul_2exp, and Int.sign for mpz_sgn; Int64 for the longs num, denexp and e; the steps counted up from 0 to deg - 1, for the index n that counts down; no scratch integers of the arguments.)

  • sturm.c:86-97: modelled by Ratpoints.Sturm.computeSturm (deviation of Ratpoints.Sturm.computeSturm: the coefficients, the degree, the depth and the search intervals as arguments, for the fields cof, degree, sturm, domain and num_inter of the arguments; natural numbers for the longs degree and iter, which is from 0 to 55 (the search clamps it, find_points.c:4682); the result as an option of an array, for the long that the C code returns and the intervals it writes into domain with their number num_inter: none for -1, the empty array for 0, with num_inter = 0, and else the intervals, their number the return value; the table of the chain made by Ratpoints.Sturm.chain, whose rows the step reads, for the table on the stack with the degrees, which _ratpoints_compute_sturm fills itself, the index of the last row the size of the chain less one, for the k of line 163; the array of the intervals kept made by Ratpoints.Sturm.iterate, for the array ivlocal on the stack of 1 + ⌊degree / 2⌋ intervals, which suffice assuming Sturm’s theorem (Ratpoints.Sturm.size_run_iterate_le_of_chain_eq_some); integers for the GMP integers and Int.sign for mpz_sgn; no mpz_init and mpz_clear, no copy of the caller’s intervals on the heap and no failure for lack of memory (RATPOINTS_NO_MEMORY), which the model cannot meet.)

  • sturm.c:99-163: modelled by Ratpoints.Sturm.chain (deviation of Ratpoints.Sturm.chain: the rows as arrays of their coefficients up to their degree, for the table of (d + 1)^2 GMP integers and the array of degrees, with no mpz_init and mpz_clear (a chain has at most d + 1 rows, Ratpoints.Sturm.IsChain.size_le, and its row k + 1 at most d - k entries, Ratpoints.Sturm.IsChain.size_getElem!_add_one_add_le): an array has one entry more than the degree of its row, and a remainder that becomes zero is the empty array, where the degree in the C code reaches -1; a reduction step drops the leading coefficient, which it makes 0, where the C code lowers the degree; the rows are handed back, and none for the return of -1, where _ratpoints_compute_sturm keeps them in its table for the rest of the Sturm step (Ratpoints.Sturm.computeSturm), and the index of the last row, which the C code leaves in k and sets to d after the loop for d = 1, is the size of the array less one; a list of integers for the array of GMP integers of the coefficients, local values for the scratch integers work[0], work[1] and work[2], and Lean’s / for mpz_fdiv_q, which agree on the divisions of the chain, all exact.)

  • sturm.c:165-175: modelled by Ratpoints.Sturm.countsAtInfinity (deviation of Ratpoints.Sturm.countsAtInfinity: natural numbers for the long counts, which stay at most k; the rows as arrays, their degrees the sizes less one, for the arrays sturm and sturm_degs, and Int.sign for mpz_sgn; the counts returned, for the locals of _ratpoints_compute_sturm.)

  • sturm.c:177-190: modelled by Ratpoints.Sturm.computeSturm (deviation of Ratpoints.Sturm.computeSturm: the coefficients, the degree, the depth and the search intervals as arguments, for the fields cof, degree, sturm, domain and num_inter of the arguments; natural numbers for the longs degree and iter, which is from 0 to 55 (the search clamps it, find_points.c:4682); the result as an option of an array, for the long that the C code returns and the intervals it writes into domain with their number num_inter: none for -1, the empty array for 0, with num_inter = 0, and else the intervals, their number the return value; the table of the chain made by Ratpoints.Sturm.chain, whose rows the step reads, for the table on the stack with the degrees, which _ratpoints_compute_sturm fills itself, the index of the last row the size of the chain less one, for the k of line 163; the array of the intervals kept made by Ratpoints.Sturm.iterate, for the array ivlocal on the stack of 1 + ⌊degree / 2⌋ intervals, which suffice assuming Sturm’s theorem (Ratpoints.Sturm.size_run_iterate_le_of_chain_eq_some); integers for the GMP integers and Int.sign for mpz_sgn; no mpz_init and mpz_clear, no copy of the caller’s intervals on the heap and no failure for lack of memory (RATPOINTS_NO_MEMORY), which the model cannot meet.)

  • sturm.c:191-192: modelled by Ratpoints.Sturm.longMax (deviation of Ratpoints.Sturm.longMax: one constant for the two locals max and min = -max.)

  • sturm.c:193-194: modelled by Ratpoints.Sturm.computeSturm (deviation of Ratpoints.Sturm.computeSturm: the coefficients, the degree, the depth and the search intervals as arguments, for the fields cof, degree, sturm, domain and num_inter of the arguments; natural numbers for the longs degree and iter, which is from 0 to 55 (the search clamps it, find_points.c:4682); the result as an option of an array, for the long that the C code returns and the intervals it writes into domain with their number num_inter: none for -1, the empty array for 0, with num_inter = 0, and else the intervals, their number the return value; the table of the chain made by Ratpoints.Sturm.chain, whose rows the step reads, for the table on the stack with the degrees, which _ratpoints_compute_sturm fills itself, the index of the last row the size of the chain less one, for the k of line 163; the array of the intervals kept made by Ratpoints.Sturm.iterate, for the array ivlocal on the stack of 1 + ⌊degree / 2⌋ intervals, which suffice assuming Sturm’s theorem (Ratpoints.Sturm.size_run_iterate_le_of_chain_eq_some); integers for the GMP integers and Int.sign for mpz_sgn; no mpz_init and mpz_clear, no copy of the caller’s intervals on the heap and no failure for lack of memory (RATPOINTS_NO_MEMORY), which the model cannot meet.)

  • sturm.c:197-208: modelled by Ratpoints.Sturm.iterate (deviation of Ratpoints.Sturm.iterate: a recursive function of its own, for the nested function of gcc, with the intervals kept passed and returned (Ratpoints.Sturm.addInterval), for the array ivlocal and the pointer iptr that it reaches, and the chain, the index of its last row and the depth of the step as arguments, for the arrays sturm and sturm_degs, k and iter that it reaches; natural numbers for the long counts, depths and the long iter, which is from 0 to 55 (the search clamps it, find_points.c:4682), integers for the long signs, and Int64 for the other longs; the recursion ends since the depth grows towards iter.)

  • sturm.c:209-227: modelled by Ratpoints.Sturm.addInterval (deviation of Ratpoints.Sturm.addInterval: a function of its own for the branch of iterate that keeps an interval; the intervals kept as an array, passed and returned, for the array ivlocal on the stack and the pointer iptr of _ratpoints_compute_sturm, which iterate reaches as a nested function of gcc, with no bound 1 + ⌊degree / 2⌋ on their number, the size of ivlocal, which the C code relies on and which holds assuming Sturm’s theorem (Ratpoints.Sturm.size_run_iterate_le_of_chain_eq_some); the doubles as their bits (Ratpoints.Double); Int64 for the longs, converted to integers for the int casts of the exponents.)

  • sturm.c:228-233: modelled by Ratpoints.Sturm.iterate (deviation of Ratpoints.Sturm.iterate: a recursive function of its own, for the nested function of gcc, with the intervals kept passed and returned (Ratpoints.Sturm.addInterval), for the array ivlocal and the pointer iptr that it reaches, and the chain, the index of its last row and the depth of the step as arguments, for the arrays sturm and sturm_degs, k and iter that it reaches; natural numbers for the long counts, depths and the long iter, which is from 0 to 55 (the search clamps it, find_points.c:4682), integers for the long signs, and Int64 for the other longs; the recursion ends since the depth grows towards iter.)

  • sturm.c:234-251: modelled by Ratpoints.Sturm.midpoint (deviation of Ratpoints.Sturm.midpoint: the point returned as a pair, for the locals nm and dem of iterate; Int64 for the longs, >>> on Int64 the arithmetic shift of the C code; the arithmetic of Int64 wrapping where that of the longs overflows, which it does not up to the depth 55 at which the search clamps the step, where every finite end is n / 2 ^ e with |n| ≤ 2 ^ 53.)

  • sturm.c:252-260: modelled by Ratpoints.Sturm.signsAt (deviation of Ratpoints.Sturm.signsAt: a function of its own for the evaluation of the chain at the midpoint in iterate, the signs and the count returned, for its locals s0, s1 and cmid; integers for the long signs and a natural number for the long count; the rows as arrays, for the arrays sturm and sturm_degs.)

  • sturm.c:261-267: modelled by Ratpoints.Sturm.iterate (deviation of Ratpoints.Sturm.iterate: a recursive function of its own, for the nested function of gcc, with the intervals kept passed and returned (Ratpoints.Sturm.addInterval), for the array ivlocal and the pointer iptr that it reaches, and the chain, the index of its last row and the depth of the step as arguments, for the arrays sturm and sturm_degs, k and iter that it reaches; natural numbers for the long counts, depths and the long iter, which is from 0 to 55 (the search clamps it, find_points.c:4682), integers for the long signs, and Int64 for the other longs; the recursion ends since the depth grows towards iter.)

  • sturm.c:269-273: modelled by Ratpoints.Sturm.computeSturm (deviation of Ratpoints.Sturm.computeSturm: the coefficients, the degree, the depth and the search intervals as arguments, for the fields cof, degree, sturm, domain and num_inter of the arguments; natural numbers for the longs degree and iter, which is from 0 to 55 (the search clamps it, find_points.c:4682); the result as an option of an array, for the long that the C code returns and the intervals it writes into domain with their number num_inter: none for -1, the empty array for 0, with num_inter = 0, and else the intervals, their number the return value; the table of the chain made by Ratpoints.Sturm.chain, whose rows the step reads, for the table on the stack with the degrees, which _ratpoints_compute_sturm fills itself, the index of the last row the size of the chain less one, for the k of line 163; the array of the intervals kept made by Ratpoints.Sturm.iterate, for the array ivlocal on the stack of 1 + ⌊degree / 2⌋ intervals, which suffice assuming Sturm’s theorem (Ratpoints.Sturm.size_run_iterate_le_of_chain_eq_some); integers for the GMP integers and Int.sign for mpz_sgn; no mpz_init and mpz_clear, no copy of the caller’s intervals on the heap and no failure for lack of memory (RATPOINTS_NO_MEMORY), which the model cannot meet.)

  • sturm.c:274-275: excluded (memory): the copy of the caller’s search intervals on the heap, from which the intersection is made; the model reads the caller’s intervals and makes a new array (Ratpoints.Sturm.intersect)

  • sturm.c:276-276: modelled by Ratpoints.Sturm.intersect (deviation of Ratpoints.Sturm.intersect: the intervals of the caller read from the array it gives, where the C code reads them from a copy on the heap (lines 274-275, 286) and writes the intersection over them; the intersection returned as a new array, with no bound on its length, for the writes into ivlist, the caller’s array, which must have room for 1 + ⌊degree / 2⌋ intervals more than it holds (lines 52-53), as the C code relies on and as suffices assuming Sturm’s theorem (Ratpoints.Sturm.size_run_computeSturm_le), and for the number num_inter of the arguments that it sets; natural numbers for the long indices.)

  • sturm.c:278-284: excluded (memory): the failure for lack of memory for the copy of the caller’s search intervals (RATPOINTS_NO_MEMORY), with the clears of the table of the chain before the return, which the model cannot meet

  • sturm.c:285-288: modelled by Ratpoints.Sturm.intersect (deviation of Ratpoints.Sturm.intersect: the intervals of the caller read from the array it gives, where the C code reads them from a copy on the heap (lines 274-275, 286) and writes the intersection over them; the intersection returned as a new array, with no bound on its length, for the writes into ivlist, the caller’s array, which must have room for 1 + ⌊degree / 2⌋ intervals more than it holds (lines 52-53), as the C code relies on and as suffices assuming Sturm’s theorem (Ratpoints.Sturm.size_run_computeSturm_le), and for the number num_inter of the arguments that it sets; natural numbers for the long indices.)

  • sturm.c:289-322: modelled by Ratpoints.Sturm.meet (deviation of Ratpoints.Sturm.meet: a function of its own for the body of the loop, the interval noted and the cursor to move returned, for the write into ivlist[n] and the increments of n, n1 and n2.)

  • sturm.c:323-323: modelled by Ratpoints.Sturm.intersect (deviation of Ratpoints.Sturm.intersect: the intervals of the caller read from the array it gives, where the C code reads them from a copy on the heap (lines 274-275, 286) and writes the intersection over them; the intersection returned as a new array, with no bound on its length, for the writes into ivlist, the caller’s array, which must have room for 1 + ⌊degree / 2⌋ intervals more than it holds (lines 52-53), as the C code relies on and as suffices assuming Sturm’s theorem (Ratpoints.Sturm.size_run_computeSturm_le), and for the number num_inter of the arguments that it sets; natural numbers for the long indices.)

  • sturm.c:324-324: excluded (memory): the release of the copy of the caller’s search intervals

  • sturm.c:325-325: modelled by Ratpoints.Sturm.intersect (deviation of Ratpoints.Sturm.intersect: the intervals of the caller read from the array it gives, where the C code reads them from a copy on the heap (lines 274-275, 286) and writes the intersection over them; the intersection returned as a new array, with no bound on its length, for the writes into ivlist, the caller’s array, which must have room for 1 + ⌊degree / 2⌋ intervals more than it holds (lines 52-53), as the C code relies on and as suffices assuming Sturm’s theorem (Ratpoints.Sturm.size_run_computeSturm_le), and for the number num_inter of the arguments that it sets; natural numbers for the long indices.)

  • sturm.c:326-332: modelled by Ratpoints.Sturm.computeSturm (deviation of Ratpoints.Sturm.computeSturm: the coefficients, the degree, the depth and the search intervals as arguments, for the fields cof, degree, sturm, domain and num_inter of the arguments; natural numbers for the longs degree and iter, which is from 0 to 55 (the search clamps it, find_points.c:4682); the result as an option of an array, for the long that the C code returns and the intervals it writes into domain with their number num_inter: none for -1, the empty array for 0, with num_inter = 0, and else the intervals, their number the return value; the table of the chain made by Ratpoints.Sturm.chain, whose rows the step reads, for the table on the stack with the degrees, which _ratpoints_compute_sturm fills itself, the index of the last row the size of the chain less one, for the k of line 163; the array of the intervals kept made by Ratpoints.Sturm.iterate, for the array ivlocal on the stack of 1 + ⌊degree / 2⌋ intervals, which suffice assuming Sturm’s theorem (Ratpoints.Sturm.size_run_iterate_le_of_chain_eq_some); integers for the GMP integers and Int.sign for mpz_sgn; no mpz_init and mpz_clear, no copy of the caller’s intervals on the heap and no failure for lack of memory (RATPOINTS_NO_MEMORY), which the model cannot meet.)

rp-private.h

  • rp-private.h:30-35: excluded (other): the includes of the headers of the C library, among them float.h and math.h of the doubles of the search intervals; the model has no headers

  • rp-private.h:41-43: modelled by Ratpoints.fitsLong (deviation of Ratpoints.fitsLong: the bounds of a long of 64 bits, fixed, where the C code does not compile unless an unsigned long has exactly 64 bits.)

  • rp-private.h:47-47: modelled by Ratpoints.fitsLong (deviation of Ratpoints.fitsLong: the bounds of a long of 64 bits, fixed, where the C code does not compile unless an unsigned long has exactly 64 bits.)

  • rp-private.h:49-51: modelled by Ratpoints.rbaLength (deviation of Ratpoints.rbaLength: computed from Ratpoints.rbaPack, where each build sets RBA_LENGTH by a literal, and the build with 64-bit bit arrays by LONG_LENGTH, and its logarithm RBA_SHIFT likewise (Ratpoints.rbaShift); the shifts by RBA_SHIFT and by LONG_SHIFT are divisions by rbaLength and by 64, which round down also for a negative value, as the arithmetic shifts of gcc do, and the masks by RBA_LENGTH - 1 and by LONG_MASK Euclidean remainders.)

  • rp-private.h:55-58: modelled by Ratpoints.rbaPack (deviation of Ratpoints.rbaPack: the value of the default build, set here, where the C code chooses the build by the macros that the compiler is given; the vector type of a bit array becomes rbaPack consecutive words of an array of UInt64.)

  • rp-private.h:60-60: excluded (other): the include of the header of the library; the model has no headers

  • rp-private.h:76-84: excluded (threads): the atomic loads and stores of the fields that the threads of a pool share (RP_ACQUIRE, RP_RELAXED, RP_PUBLISH), and their plain forms for a build without threads; on one thread an atomic load or store is a plain read or write, which the model makes

  • rp-private.h:86-86: excluded (other): FLOOR, which the C code uses nowhere: find_points.c names it only in a comment

  • rp-private.h:87-87: modelled by Ratpoints.Setup.slope, Ratpoints.arraySizeAt (deviation of Ratpoints.Setup.slope: integers for the ints, and the slope as a natural number; no output under DEBUG.) (deviation of Ratpoints.arraySizeAt: a Nat for the long field, so that only 0 stands for the default, which the library takes for every value ≤ 0; 64 for LONG_LENGTH; and the macro CEIL of a natural number x by d as (x + d - 1) / d, which is its value for every x ≥ 0.)

  • rp-private.h:113-113: modelled by Ratpoints.rbaPack (deviation of Ratpoints.rbaPack: the value of the default build, set here, where the C code chooses the build by the macros that the compiler is given; the vector type of a bit array becomes rbaPack consecutive words of an array of UInt64.)

  • rp-private.h:123-123: excluded (other): the include of the vector intrinsics in the build USE_AVX512, with 512-bit bit arrays; the word operations of the model need none

  • rp-private.h:125-125: modelled by Ratpoints.rbaLength (deviation of Ratpoints.rbaLength: computed from Ratpoints.rbaPack, where each build sets RBA_LENGTH by a literal, and the build with 64-bit bit arrays by LONG_LENGTH, and its logarithm RBA_SHIFT likewise (Ratpoints.rbaShift); the shifts by RBA_SHIFT and by LONG_SHIFT are divisions by rbaLength and by 64, which round down also for a negative value, as the arithmetic shifts of gcc do, and the masks by RBA_LENGTH - 1 and by LONG_MASK Euclidean remainders.)

  • rp-private.h:126-126: modelled by Ratpoints.rbaShift (deviation of Ratpoints.rbaShift: the value of the default build, set here, where each build sets it by a literal, and the build with 64-bit bit arrays by LONG_SHIFT; the model shifts by none of them: the shifts by RBA_SHIFT are divisions by Ratpoints.rbaLength.)

  • rp-private.h:127-128: modelled by Ratpoints.rbaPack (deviation of Ratpoints.rbaPack: the value of the default build, set here, where the C code chooses the build by the macros that the compiler is given; the vector type of a bit array becomes rbaPack consecutive words of an array of UInt64.)

  • rp-private.h:129-132: modelled by Ratpoints.Sieve.andRows, Ratpoints.Sieve.andRowsChunked (deviation of Ratpoints.Sieve.andRows: the bit arrays set to the class word by a loop that counts up, bit array n - 1 - i at the step i, for the loop that counts down from the last; the class word written into each word of a bit array, for the vector RBA(packed) that get_2adic_info makes once per class (find_points.c:1098) and _ratpoints_sift0 copies into each bit array (bits64, sift.c:519, sift.c:954); the moduli of the stage with their rows and their reciprocals as two lists, for the first sp1 sieve specs and the array magics from position 0 on; the value -w_low - offset written out in both reductions, for the long a, which stays a long where the helper mod reduces it outside small (Ratpoints.Sieve.fitsLong_neg_sub); indices for the pointers into the rows and into the survivors, and the number of whole periods and the rest computed before their loops; natural numbers and integers for the longs; a Boolean for the int small; no output under DEBUG.) (deviation of Ratpoints.Sieve.andRowsChunked: no moduli tested by the size of the local array of the sieve specs, for sp1 == 0; the bit arrays set to the class word by a loop that counts up, bit array n - 1 - i at the step i, for the loop that counts down from the last; the class word written into each word of a bit array, for the vector RBA(packed) that get_2adic_info makes once per class (find_points.c:1098) and _ratpoints_sift0 copies into each bit array (bits64, sift.c:519); the end of the whole chunks the index full, for the word number w_high_full, which is also the index of the first bit array of the tail, for the pointer surv after the chunks; natural numbers and integers for the longs.)

  • rp-private.h:133-133: modelled by Ratpoints.Sieve.scanPiece (deviation of Ratpoints.Sieve.scanPiece: indices for the pointers into the survivors, and a scan that holds its position as an index, where ratpoints recovers the word number from a pointer difference; the copy nums of the bit array a vector of Ratpoints.rbaPack words; the sentinel ~zero of every build as Ratpoints.rbaPack words ~~~0, written one at a time; natural numbers and integers for the longs; the counters cnt passed and returned, for the field n_arrays of the sieving thread, which counts one up for each bit array that is not zero (line 1092); the delivery r passed and returned, for the pointers info and wk->quit and the count total of _ratpoints_sift0, and the flag quit tested after each bit array, where the C code returns from _ratpoints_sift0 within the walk through the set bits of a word (Ratpoints.Sieve.walkWord).)

  • rp-private.h:134-134: modelled by Ratpoints.Sieve.andBitArray (deviation of Ratpoints.Sieve.andBitArray: one definition for every build, on bit arrays given by their indices in arrays of words, each bit array rbaPack consecutive words, for the & on the vector type of the build.)

  • rp-private.h:135-136: modelled by Ratpoints.Sieve.siftBitArrayWhole (deviation of Ratpoints.Sieve.siftBitArrayWhole: the stride, the first numerator and the steps as natural numbers and integers, the powers 2 ^ k for the shifts 1L << k, RBA_LENGTH << k and LONG_LENGTH << k, the last two of which stay ints, while the first numerators of the words, the numerators of bits of the bit arrays of a height bound below 2 ^ 63, stay longs (Ratpoints.Sieve.NumClass.fitsLong_numerator); the words of the bit array read as entries of the vector, for EXT0 and EXT; natural numbers and integers for the longs; the delivery r passed and returned, for the pointers info and wk->quit and the count total of _ratpoints_sift0, and the flag quit tested after each walk through the set bits of a word and the rest of the bit array left at a stop, where the C code returns from _ratpoints_sift0 within the walk (Ratpoints.Sieve.walkWord); no counts under RP_PHASE_COUNTS and no stop after a phase (RP_STOP_AFTER).)

  • rp-private.h:137-152: modelled by Ratpoints.Sieve.isZeroAt (deviation of Ratpoints.Sieve.isZeroAt: one definition for every build, on a bit array given by its index in an array of words, rbaPack consecutive words that it compares with 0 one at a time, for the tests of the builds on the vector type, with vector instructions or by or-ing its words; the test for zero TESTZ also stands for its negation TEST.)

  • rp-private.h:153-155: modelled by Ratpoints.Sieve.clearLowBits (deviation of Ratpoints.Sieve.clearLowBits: one definition for every build, the loop of the build with 512-bit bit arrays, of which the macros of the builds with 256-bit and 128-bit bit arrays are unrolled cases and that of the build with 64-bit bit arrays the case of one word; the bit array is the first Ratpoints.rbaPack words of an array, for the vector type of the build.)

  • rp-private.h:156-159: modelled by Ratpoints.Sieve.clearHighBits (deviation of Ratpoints.Sieve.clearHighBits: one definition for every build, the loop of the build with 512-bit bit arrays, of which the macros of the builds with 256-bit and 128-bit bit arrays are unrolled cases and that of the build with 64-bit bit arrays the case of one word; the bit array is given by its index in an array of words, rbaPack consecutive words, for a pointer to a value of the vector type of the build.)

  • rp-private.h:160-165: modelled by Ratpoints.chunk (deviation of Ratpoints.chunk: 16, the value of the default build (USE_AVX), set here, where the C code chooses the value by the macros that the compiler is given, each build with vector registers taking 16 and the build with 64-bit bit arrays 1 unless RATPOINTS_CHUNK is given.)

  • rp-private.h:167-167: modelled by Ratpoints.rbaPack (deviation of Ratpoints.rbaPack: the value of the default build, set here, where the C code chooses the build by the macros that the compiler is given; the vector type of a bit array becomes rbaPack consecutive words of an array of UInt64.)

  • rp-private.h:170-170: excluded (other): the include of the vector intrinsics in the build USE_AVX, with 256-bit bit arrays; the word operations of the model need none

  • rp-private.h:172-172: modelled by Ratpoints.rbaLength (deviation of Ratpoints.rbaLength: computed from Ratpoints.rbaPack, where each build sets RBA_LENGTH by a literal, and the build with 64-bit bit arrays by LONG_LENGTH, and its logarithm RBA_SHIFT likewise (Ratpoints.rbaShift); the shifts by RBA_SHIFT and by LONG_SHIFT are divisions by rbaLength and by 64, which round down also for a negative value, as the arithmetic shifts of gcc do, and the masks by RBA_LENGTH - 1 and by LONG_MASK Euclidean remainders.)

  • rp-private.h:173-173: modelled by Ratpoints.rbaShift (deviation of Ratpoints.rbaShift: the value of the default build, set here, where each build sets it by a literal, and the build with 64-bit bit arrays by LONG_SHIFT; the model shifts by none of them: the shifts by RBA_SHIFT are divisions by Ratpoints.rbaLength.)

  • rp-private.h:174-175: modelled by Ratpoints.rbaPack (deviation of Ratpoints.rbaPack: the value of the default build, set here, where the C code chooses the build by the macros that the compiler is given; the vector type of a bit array becomes rbaPack consecutive words of an array of UInt64.)

  • rp-private.h:176-176: modelled by Ratpoints.Sieve.andBitArray (deviation of Ratpoints.Sieve.andBitArray: one definition for every build, on bit arrays given by their indices in arrays of words, each bit array rbaPack consecutive words, for the & on the vector type of the build.)

  • rp-private.h:177-178: modelled by Ratpoints.Sieve.siftBitArrayWhole (deviation of Ratpoints.Sieve.siftBitArrayWhole: the stride, the first numerator and the steps as natural numbers and integers, the powers 2 ^ k for the shifts 1L << k, RBA_LENGTH << k and LONG_LENGTH << k, the last two of which stay ints, while the first numerators of the words, the numerators of bits of the bit arrays of a height bound below 2 ^ 63, stay longs (Ratpoints.Sieve.NumClass.fitsLong_numerator); the words of the bit array read as entries of the vector, for EXT0 and EXT; natural numbers and integers for the longs; the delivery r passed and returned, for the pointers info and wk->quit and the count total of _ratpoints_sift0, and the flag quit tested after each walk through the set bits of a word and the rest of the bit array left at a stop, where the C code returns from _ratpoints_sift0 within the walk (Ratpoints.Sieve.walkWord); no counts under RP_PHASE_COUNTS and no stop after a phase (RP_STOP_AFTER).)

  • rp-private.h:179-202: modelled by Ratpoints.Sieve.isZeroAt (deviation of Ratpoints.Sieve.isZeroAt: one definition for every build, on a bit array given by its index in an array of words, rbaPack consecutive words that it compares with 0 one at a time, for the tests of the builds on the vector type, with vector instructions or by or-ing its words; the test for zero TESTZ also stands for its negation TEST.)

  • rp-private.h:203-204: modelled by Ratpoints.Sieve.andRows, Ratpoints.Sieve.andRowsChunked (deviation of Ratpoints.Sieve.andRows: the bit arrays set to the class word by a loop that counts up, bit array n - 1 - i at the step i, for the loop that counts down from the last; the class word written into each word of a bit array, for the vector RBA(packed) that get_2adic_info makes once per class (find_points.c:1098) and _ratpoints_sift0 copies into each bit array (bits64, sift.c:519, sift.c:954); the moduli of the stage with their rows and their reciprocals as two lists, for the first sp1 sieve specs and the array magics from position 0 on; the value -w_low - offset written out in both reductions, for the long a, which stays a long where the helper mod reduces it outside small (Ratpoints.Sieve.fitsLong_neg_sub); indices for the pointers into the rows and into the survivors, and the number of whole periods and the rest computed before their loops; natural numbers and integers for the longs; a Boolean for the int small; no output under DEBUG.) (deviation of Ratpoints.Sieve.andRowsChunked: no moduli tested by the size of the local array of the sieve specs, for sp1 == 0; the bit arrays set to the class word by a loop that counts up, bit array n - 1 - i at the step i, for the loop that counts down from the last; the class word written into each word of a bit array, for the vector RBA(packed) that get_2adic_info makes once per class (find_points.c:1098) and _ratpoints_sift0 copies into each bit array (bits64, sift.c:519); the end of the whole chunks the index full, for the word number w_high_full, which is also the index of the first bit array of the tail, for the pointer surv after the chunks; natural numbers and integers for the longs.)

  • rp-private.h:205-205: modelled by Ratpoints.Sieve.scanPiece (deviation of Ratpoints.Sieve.scanPiece: indices for the pointers into the survivors, and a scan that holds its position as an index, where ratpoints recovers the word number from a pointer difference; the copy nums of the bit array a vector of Ratpoints.rbaPack words; the sentinel ~zero of every build as Ratpoints.rbaPack words ~~~0, written one at a time; natural numbers and integers for the longs; the counters cnt passed and returned, for the field n_arrays of the sieving thread, which counts one up for each bit array that is not zero (line 1092); the delivery r passed and returned, for the pointers info and wk->quit and the count total of _ratpoints_sift0, and the flag quit tested after each bit array, where the C code returns from _ratpoints_sift0 within the walk through the set bits of a word (Ratpoints.Sieve.walkWord).)

  • rp-private.h:206-213: modelled by Ratpoints.Sieve.clearLowBits (deviation of Ratpoints.Sieve.clearLowBits: one definition for every build, the loop of the build with 512-bit bit arrays, of which the macros of the builds with 256-bit and 128-bit bit arrays are unrolled cases and that of the build with 64-bit bit arrays the case of one word; the bit array is the first Ratpoints.rbaPack words of an array, for the vector type of the build.)

  • rp-private.h:214-221: modelled by Ratpoints.Sieve.clearHighBits (deviation of Ratpoints.Sieve.clearHighBits: one definition for every build, the loop of the build with 512-bit bit arrays, of which the macros of the builds with 256-bit and 128-bit bit arrays are unrolled cases and that of the build with 64-bit bit arrays the case of one word; the bit array is given by its index in an array of words, rbaPack consecutive words, for a pointer to a value of the vector type of the build.)

  • rp-private.h:222-224: modelled by Ratpoints.chunk (deviation of Ratpoints.chunk: 16, the value of the default build (USE_AVX), set here, where the C code chooses the value by the macros that the compiler is given, each build with vector registers taking 16 and the build with 64-bit bit arrays 1 unless RATPOINTS_CHUNK is given.)

  • rp-private.h:226-226: modelled by Ratpoints.rbaPack (deviation of Ratpoints.rbaPack: the value of the default build, set here, where the C code chooses the build by the macros that the compiler is given; the vector type of a bit array becomes rbaPack consecutive words of an array of UInt64.)

  • rp-private.h:229-229: excluded (other): the include of the vector intrinsics in the build USE_AVX128, with 128-bit bit arrays; the word operations of the model need none

  • rp-private.h:231-231: modelled by Ratpoints.rbaLength (deviation of Ratpoints.rbaLength: computed from Ratpoints.rbaPack, where each build sets RBA_LENGTH by a literal, and the build with 64-bit bit arrays by LONG_LENGTH, and its logarithm RBA_SHIFT likewise (Ratpoints.rbaShift); the shifts by RBA_SHIFT and by LONG_SHIFT are divisions by rbaLength and by 64, which round down also for a negative value, as the arithmetic shifts of gcc do, and the masks by RBA_LENGTH - 1 and by LONG_MASK Euclidean remainders.)

  • rp-private.h:232-232: modelled by Ratpoints.rbaShift (deviation of Ratpoints.rbaShift: the value of the default build, set here, where each build sets it by a literal, and the build with 64-bit bit arrays by LONG_SHIFT; the model shifts by none of them: the shifts by RBA_SHIFT are divisions by Ratpoints.rbaLength.)

  • rp-private.h:233-234: modelled by Ratpoints.rbaPack (deviation of Ratpoints.rbaPack: the value of the default build, set here, where the C code chooses the build by the macros that the compiler is given; the vector type of a bit array becomes rbaPack consecutive words of an array of UInt64.)

  • rp-private.h:235-235: modelled by Ratpoints.Sieve.andRows, Ratpoints.Sieve.andRowsChunked (deviation of Ratpoints.Sieve.andRows: the bit arrays set to the class word by a loop that counts up, bit array n - 1 - i at the step i, for the loop that counts down from the last; the class word written into each word of a bit array, for the vector RBA(packed) that get_2adic_info makes once per class (find_points.c:1098) and _ratpoints_sift0 copies into each bit array (bits64, sift.c:519, sift.c:954); the moduli of the stage with their rows and their reciprocals as two lists, for the first sp1 sieve specs and the array magics from position 0 on; the value -w_low - offset written out in both reductions, for the long a, which stays a long where the helper mod reduces it outside small (Ratpoints.Sieve.fitsLong_neg_sub); indices for the pointers into the rows and into the survivors, and the number of whole periods and the rest computed before their loops; natural numbers and integers for the longs; a Boolean for the int small; no output under DEBUG.) (deviation of Ratpoints.Sieve.andRowsChunked: no moduli tested by the size of the local array of the sieve specs, for sp1 == 0; the bit arrays set to the class word by a loop that counts up, bit array n - 1 - i at the step i, for the loop that counts down from the last; the class word written into each word of a bit array, for the vector RBA(packed) that get_2adic_info makes once per class (find_points.c:1098) and _ratpoints_sift0 copies into each bit array (bits64, sift.c:519); the end of the whole chunks the index full, for the word number w_high_full, which is also the index of the first bit array of the tail, for the pointer surv after the chunks; natural numbers and integers for the longs.)

  • rp-private.h:236-236: modelled by Ratpoints.Sieve.scanPiece (deviation of Ratpoints.Sieve.scanPiece: indices for the pointers into the survivors, and a scan that holds its position as an index, where ratpoints recovers the word number from a pointer difference; the copy nums of the bit array a vector of Ratpoints.rbaPack words; the sentinel ~zero of every build as Ratpoints.rbaPack words ~~~0, written one at a time; natural numbers and integers for the longs; the counters cnt passed and returned, for the field n_arrays of the sieving thread, which counts one up for each bit array that is not zero (line 1092); the delivery r passed and returned, for the pointers info and wk->quit and the count total of _ratpoints_sift0, and the flag quit tested after each bit array, where the C code returns from _ratpoints_sift0 within the walk through the set bits of a word (Ratpoints.Sieve.walkWord).)

  • rp-private.h:237-237: modelled by Ratpoints.Sieve.andBitArray (deviation of Ratpoints.Sieve.andBitArray: one definition for every build, on bit arrays given by their indices in arrays of words, each bit array rbaPack consecutive words, for the & on the vector type of the build.)

  • rp-private.h:238-239: modelled by Ratpoints.Sieve.siftBitArrayWhole (deviation of Ratpoints.Sieve.siftBitArrayWhole: the stride, the first numerator and the steps as natural numbers and integers, the powers 2 ^ k for the shifts 1L << k, RBA_LENGTH << k and LONG_LENGTH << k, the last two of which stay ints, while the first numerators of the words, the numerators of bits of the bit arrays of a height bound below 2 ^ 63, stay longs (Ratpoints.Sieve.NumClass.fitsLong_numerator); the words of the bit array read as entries of the vector, for EXT0 and EXT; natural numbers and integers for the longs; the delivery r passed and returned, for the pointers info and wk->quit and the count total of _ratpoints_sift0, and the flag quit tested after each walk through the set bits of a word and the rest of the bit array left at a stop, where the C code returns from _ratpoints_sift0 within the walk (Ratpoints.Sieve.walkWord); no counts under RP_PHASE_COUNTS and no stop after a phase (RP_STOP_AFTER).)

  • rp-private.h:241-241: modelled by Ratpoints.Sieve.isZeroAt (deviation of Ratpoints.Sieve.isZeroAt: one definition for every build, on a bit array given by its index in an array of words, rbaPack consecutive words that it compares with 0 one at a time, for the tests of the builds on the vector type, with vector instructions or by or-ing its words; the test for zero TESTZ also stands for its negation TEST.)

  • rp-private.h:242-244: modelled by Ratpoints.Sieve.clearLowBits (deviation of Ratpoints.Sieve.clearLowBits: one definition for every build, the loop of the build with 512-bit bit arrays, of which the macros of the builds with 256-bit and 128-bit bit arrays are unrolled cases and that of the build with 64-bit bit arrays the case of one word; the bit array is the first Ratpoints.rbaPack words of an array, for the vector type of the build.)

  • rp-private.h:245-247: modelled by Ratpoints.Sieve.clearHighBits (deviation of Ratpoints.Sieve.clearHighBits: one definition for every build, the loop of the build with 512-bit bit arrays, of which the macros of the builds with 256-bit and 128-bit bit arrays are unrolled cases and that of the build with 64-bit bit arrays the case of one word; the bit array is given by its index in an array of words, rbaPack consecutive words, for a pointer to a value of the vector type of the build.)

  • rp-private.h:248-250: modelled by Ratpoints.chunk (deviation of Ratpoints.chunk: 16, the value of the default build (USE_AVX), set here, where the C code chooses the value by the macros that the compiler is given, each build with vector registers taking 16 and the build with 64-bit bit arrays 1 unless RATPOINTS_CHUNK is given.)

  • rp-private.h:252-252: modelled by Ratpoints.rbaPack (deviation of Ratpoints.rbaPack: the value of the default build, set here, where the C code chooses the build by the macros that the compiler is given; the vector type of a bit array becomes rbaPack consecutive words of an array of UInt64.)

  • rp-private.h:255-255: excluded (other): the include of the SSE2 intrinsics in the build USE_SSE, with 128-bit bit arrays; the word operations of the model need none

  • rp-private.h:257-257: modelled by Ratpoints.rbaLength (deviation of Ratpoints.rbaLength: computed from Ratpoints.rbaPack, where each build sets RBA_LENGTH by a literal, and the build with 64-bit bit arrays by LONG_LENGTH, and its logarithm RBA_SHIFT likewise (Ratpoints.rbaShift); the shifts by RBA_SHIFT and by LONG_SHIFT are divisions by rbaLength and by 64, which round down also for a negative value, as the arithmetic shifts of gcc do, and the masks by RBA_LENGTH - 1 and by LONG_MASK Euclidean remainders.)

  • rp-private.h:258-258: modelled by Ratpoints.rbaShift (deviation of Ratpoints.rbaShift: the value of the default build, set here, where each build sets it by a literal, and the build with 64-bit bit arrays by LONG_SHIFT; the model shifts by none of them: the shifts by RBA_SHIFT are divisions by Ratpoints.rbaLength.)

  • rp-private.h:259-260: modelled by Ratpoints.rbaPack (deviation of Ratpoints.rbaPack: the value of the default build, set here, where the C code chooses the build by the macros that the compiler is given; the vector type of a bit array becomes rbaPack consecutive words of an array of UInt64.)

  • rp-private.h:261-261: modelled by Ratpoints.Sieve.andRows, Ratpoints.Sieve.andRowsChunked (deviation of Ratpoints.Sieve.andRows: the bit arrays set to the class word by a loop that counts up, bit array n - 1 - i at the step i, for the loop that counts down from the last; the class word written into each word of a bit array, for the vector RBA(packed) that get_2adic_info makes once per class (find_points.c:1098) and _ratpoints_sift0 copies into each bit array (bits64, sift.c:519, sift.c:954); the moduli of the stage with their rows and their reciprocals as two lists, for the first sp1 sieve specs and the array magics from position 0 on; the value -w_low - offset written out in both reductions, for the long a, which stays a long where the helper mod reduces it outside small (Ratpoints.Sieve.fitsLong_neg_sub); indices for the pointers into the rows and into the survivors, and the number of whole periods and the rest computed before their loops; natural numbers and integers for the longs; a Boolean for the int small; no output under DEBUG.) (deviation of Ratpoints.Sieve.andRowsChunked: no moduli tested by the size of the local array of the sieve specs, for sp1 == 0; the bit arrays set to the class word by a loop that counts up, bit array n - 1 - i at the step i, for the loop that counts down from the last; the class word written into each word of a bit array, for the vector RBA(packed) that get_2adic_info makes once per class (find_points.c:1098) and _ratpoints_sift0 copies into each bit array (bits64, sift.c:519); the end of the whole chunks the index full, for the word number w_high_full, which is also the index of the first bit array of the tail, for the pointer surv after the chunks; natural numbers and integers for the longs.)

  • rp-private.h:262-262: modelled by Ratpoints.Sieve.scanPiece (deviation of Ratpoints.Sieve.scanPiece: indices for the pointers into the survivors, and a scan that holds its position as an index, where ratpoints recovers the word number from a pointer difference; the copy nums of the bit array a vector of Ratpoints.rbaPack words; the sentinel ~zero of every build as Ratpoints.rbaPack words ~~~0, written one at a time; natural numbers and integers for the longs; the counters cnt passed and returned, for the field n_arrays of the sieving thread, which counts one up for each bit array that is not zero (line 1092); the delivery r passed and returned, for the pointers info and wk->quit and the count total of _ratpoints_sift0, and the flag quit tested after each bit array, where the C code returns from _ratpoints_sift0 within the walk through the set bits of a word (Ratpoints.Sieve.walkWord).)

  • rp-private.h:263-263: modelled by Ratpoints.Sieve.andBitArray (deviation of Ratpoints.Sieve.andBitArray: one definition for every build, on bit arrays given by their indices in arrays of words, each bit array rbaPack consecutive words, for the & on the vector type of the build.)

  • rp-private.h:264-266: modelled by Ratpoints.Sieve.siftBitArrayWhole (deviation of Ratpoints.Sieve.siftBitArrayWhole: the stride, the first numerator and the steps as natural numbers and integers, the powers 2 ^ k for the shifts 1L << k, RBA_LENGTH << k and LONG_LENGTH << k, the last two of which stay ints, while the first numerators of the words, the numerators of bits of the bit arrays of a height bound below 2 ^ 63, stay longs (Ratpoints.Sieve.NumClass.fitsLong_numerator); the words of the bit array read as entries of the vector, for EXT0 and EXT; natural numbers and integers for the longs; the delivery r passed and returned, for the pointers info and wk->quit and the count total of _ratpoints_sift0, and the flag quit tested after each walk through the set bits of a word and the rest of the bit array left at a stop, where the C code returns from _ratpoints_sift0 within the walk (Ratpoints.Sieve.walkWord); no counts under RP_PHASE_COUNTS and no stop after a phase (RP_STOP_AFTER).)

  • rp-private.h:267-267: modelled by Ratpoints.Sieve.isZeroAt (deviation of Ratpoints.Sieve.isZeroAt: one definition for every build, on a bit array given by its index in an array of words, rbaPack consecutive words that it compares with 0 one at a time, for the tests of the builds on the vector type, with vector instructions or by or-ing its words; the test for zero TESTZ also stands for its negation TEST.)

  • rp-private.h:268-270: modelled by Ratpoints.Sieve.clearLowBits (deviation of Ratpoints.Sieve.clearLowBits: one definition for every build, the loop of the build with 512-bit bit arrays, of which the macros of the builds with 256-bit and 128-bit bit arrays are unrolled cases and that of the build with 64-bit bit arrays the case of one word; the bit array is the first Ratpoints.rbaPack words of an array, for the vector type of the build.)

  • rp-private.h:271-273: modelled by Ratpoints.Sieve.clearHighBits (deviation of Ratpoints.Sieve.clearHighBits: one definition for every build, the loop of the build with 512-bit bit arrays, of which the macros of the builds with 256-bit and 128-bit bit arrays are unrolled cases and that of the build with 64-bit bit arrays the case of one word; the bit array is given by its index in an array of words, rbaPack consecutive words, for a pointer to a value of the vector type of the build.)

  • rp-private.h:274-276: modelled by Ratpoints.chunk (deviation of Ratpoints.chunk: 16, the value of the default build (USE_AVX), set here, where the C code chooses the value by the macros that the compiler is given, each build with vector registers taking 16 and the build with 64-bit bit arrays 1 unless RATPOINTS_CHUNK is given.)

  • rp-private.h:278-278: modelled by Ratpoints.rbaPack (deviation of Ratpoints.rbaPack: the value of the default build, set here, where the C code chooses the build by the macros that the compiler is given; the vector type of a bit array becomes rbaPack consecutive words of an array of UInt64.)

  • rp-private.h:281-281: modelled by Ratpoints.rbaLength (deviation of Ratpoints.rbaLength: computed from Ratpoints.rbaPack, where each build sets RBA_LENGTH by a literal, and the build with 64-bit bit arrays by LONG_LENGTH, and its logarithm RBA_SHIFT likewise (Ratpoints.rbaShift); the shifts by RBA_SHIFT and by LONG_SHIFT are divisions by rbaLength and by 64, which round down also for a negative value, as the arithmetic shifts of gcc do, and the masks by RBA_LENGTH - 1 and by LONG_MASK Euclidean remainders.)

  • rp-private.h:282-282: modelled by Ratpoints.rbaShift (deviation of Ratpoints.rbaShift: the value of the default build, set here, where each build sets it by a literal, and the build with 64-bit bit arrays by LONG_SHIFT; the model shifts by none of them: the shifts by RBA_SHIFT are divisions by Ratpoints.rbaLength.)

  • rp-private.h:283-284: modelled by Ratpoints.rbaPack (deviation of Ratpoints.rbaPack: the value of the default build, set here, where the C code chooses the build by the macros that the compiler is given; the vector type of a bit array becomes rbaPack consecutive words of an array of UInt64.)

  • rp-private.h:285-285: modelled by Ratpoints.Sieve.andRows, Ratpoints.Sieve.andRowsChunked (deviation of Ratpoints.Sieve.andRows: the bit arrays set to the class word by a loop that counts up, bit array n - 1 - i at the step i, for the loop that counts down from the last; the class word written into each word of a bit array, for the vector RBA(packed) that get_2adic_info makes once per class (find_points.c:1098) and _ratpoints_sift0 copies into each bit array (bits64, sift.c:519, sift.c:954); the moduli of the stage with their rows and their reciprocals as two lists, for the first sp1 sieve specs and the array magics from position 0 on; the value -w_low - offset written out in both reductions, for the long a, which stays a long where the helper mod reduces it outside small (Ratpoints.Sieve.fitsLong_neg_sub); indices for the pointers into the rows and into the survivors, and the number of whole periods and the rest computed before their loops; natural numbers and integers for the longs; a Boolean for the int small; no output under DEBUG.) (deviation of Ratpoints.Sieve.andRowsChunked: no moduli tested by the size of the local array of the sieve specs, for sp1 == 0; the bit arrays set to the class word by a loop that counts up, bit array n - 1 - i at the step i, for the loop that counts down from the last; the class word written into each word of a bit array, for the vector RBA(packed) that get_2adic_info makes once per class (find_points.c:1098) and _ratpoints_sift0 copies into each bit array (bits64, sift.c:519); the end of the whole chunks the index full, for the word number w_high_full, which is also the index of the first bit array of the tail, for the pointer surv after the chunks; natural numbers and integers for the longs.)

  • rp-private.h:286-286: modelled by Ratpoints.Sieve.scanPiece (deviation of Ratpoints.Sieve.scanPiece: indices for the pointers into the survivors, and a scan that holds its position as an index, where ratpoints recovers the word number from a pointer difference; the copy nums of the bit array a vector of Ratpoints.rbaPack words; the sentinel ~zero of every build as Ratpoints.rbaPack words ~~~0, written one at a time; natural numbers and integers for the longs; the counters cnt passed and returned, for the field n_arrays of the sieving thread, which counts one up for each bit array that is not zero (line 1092); the delivery r passed and returned, for the pointers info and wk->quit and the count total of _ratpoints_sift0, and the flag quit tested after each bit array, where the C code returns from _ratpoints_sift0 within the walk through the set bits of a word (Ratpoints.Sieve.walkWord).)

  • rp-private.h:287-287: modelled by Ratpoints.Sieve.andBitArray (deviation of Ratpoints.Sieve.andBitArray: one definition for every build, on bit arrays given by their indices in arrays of words, each bit array rbaPack consecutive words, for the & on the vector type of the build.)

  • rp-private.h:288-289: modelled by Ratpoints.Sieve.siftBitArrayWhole (deviation of Ratpoints.Sieve.siftBitArrayWhole: the stride, the first numerator and the steps as natural numbers and integers, the powers 2 ^ k for the shifts 1L << k, RBA_LENGTH << k and LONG_LENGTH << k, the last two of which stay ints, while the first numerators of the words, the numerators of bits of the bit arrays of a height bound below 2 ^ 63, stay longs (Ratpoints.Sieve.NumClass.fitsLong_numerator); the words of the bit array read as entries of the vector, for EXT0 and EXT; natural numbers and integers for the longs; the delivery r passed and returned, for the pointers info and wk->quit and the count total of _ratpoints_sift0, and the flag quit tested after each walk through the set bits of a word and the rest of the bit array left at a stop, where the C code returns from _ratpoints_sift0 within the walk (Ratpoints.Sieve.walkWord); no counts under RP_PHASE_COUNTS and no stop after a phase (RP_STOP_AFTER).)

  • rp-private.h:290-290: modelled by Ratpoints.Sieve.isZeroAt (deviation of Ratpoints.Sieve.isZeroAt: one definition for every build, on a bit array given by its index in an array of words, rbaPack consecutive words that it compares with 0 one at a time, for the tests of the builds on the vector type, with vector instructions or by or-ing its words; the test for zero TESTZ also stands for its negation TEST.)

  • rp-private.h:291-291: modelled by Ratpoints.Sieve.clearLowBits (deviation of Ratpoints.Sieve.clearLowBits: one definition for every build, the loop of the build with 512-bit bit arrays, of which the macros of the builds with 256-bit and 128-bit bit arrays are unrolled cases and that of the build with 64-bit bit arrays the case of one word; the bit array is the first Ratpoints.rbaPack words of an array, for the vector type of the build.)

  • rp-private.h:292-292: modelled by Ratpoints.Sieve.clearHighBits (deviation of Ratpoints.Sieve.clearHighBits: one definition for every build, the loop of the build with 512-bit bit arrays, of which the macros of the builds with 256-bit and 128-bit bit arrays are unrolled cases and that of the build with 64-bit bit arrays the case of one word; the bit array is given by its index in an array of words, rbaPack consecutive words, for a pointer to a value of the vector type of the build.)

  • rp-private.h:293-295: modelled by Ratpoints.chunk (deviation of Ratpoints.chunk: 16, the value of the default build (USE_AVX), set here, where the C code chooses the value by the macros that the compiler is given, each build with vector registers taking 16 and the build with 64-bit bit arrays 1 unless RATPOINTS_CHUNK is given.)

  • rp-private.h:300-300: modelled by Ratpoints.rbaPack (deviation of Ratpoints.rbaPack: the value of the default build, set here, where the C code chooses the build by the macros that the compiler is given; the vector type of a bit array becomes rbaPack consecutive words of an array of UInt64.)

  • rp-private.h:306-308: modelled by Ratpoints.Sieve.isZeroAt (deviation of Ratpoints.Sieve.isZeroAt: one definition for every build, on a bit array given by its index in an array of words, rbaPack consecutive words that it compares with 0 one at a time, for the tests of the builds on the vector type, with vector instructions or by or-ing its words; the test for zero TESTZ also stands for its negation TEST.)

  • rp-private.h:311-318: excluded (instrumentation): WIDTH and PRINT_RBA, which print words and bit arrays in hexadecimal in the output for debugging (under DEBUG)

  • rp-private.h:321-323: modelled by Ratpoints.maxBitsInPrime (deviation of Ratpoints.maxBitsInPrime: 8, the value of the default build, which the Makefile of ratpoints passes to the compiler (its variable PRIME_SIZE), for the value 7 that the header takes when it is given none.)

  • rp-private.h:325-361: modelled by Ratpoints.maxPrimeEven, Ratpoints.numPrimes (deviation of Ratpoints.maxPrimeEven: computed from Ratpoints.maxBitsInPrime, where the header lists the values for 5 to 10 bits, the powers of 2 that the computation gives, and takes 7 bits for any other value.) (deviation of Ratpoints.numPrimes: computed from Ratpoints.maxBitsInPrime, where the header lists the values for 5 to 10 bits, the numbers that the computation gives, and takes 7 bits for any other value; the largest such prime, RATPOINTS_MAX_PRIME, has no counterpart; the power of 2 above it is Ratpoints.maxPrimeEven.)

  • rp-private.h:378-379: modelled by Ratpoints.Sieve.SieveSpec (deviation of Ratpoints.Sieve.SieveSpec: the row for the pointer ptr to it, the empty array for the null pointer of a row not built yet (Ratpoints.Sieve.setRows, Ratpoints.Sieve.buildRows), and indices into the row for the pointers start and end into it, the end named stop (end is a keyword of Lean); natural numbers for the longs p and offset, the offset below 2 ^ 32 (Ratpoints.Sieve.SieveEntry.PackedFor.lt_two_pow_32).)

  • rp-private.h:387-387: modelled by Ratpoints.rowBias (deviation of Ratpoints.rowBias: the check at compile time that 2 RP_ROW_BIAS - 1 ≤ RP_MULMOD_LIMIT, an array of negative size otherwise, a theorem checked by decide (Ratpoints.two_mul_rowBias_sub_one_le_mulModLimit).)

  • rp-private.h:404-408: modelled by Ratpoints.Sieve.mulHi, Ratpoints.Sieve.mulMod (deviation of Ratpoints.Sieve.mulHi: the high half of the product from the products of the 32-bit halves, for the product of type __uint128_t that gcc provides and Lean core does not.) (deviation of Ratpoints.Sieve.mulMod: natural numbers for the unsigned long reciprocal, the longs u and p, and the long result, which is below p; the arguments converted to UInt64, as the macro converts u and p to unsigned longs, so that the product m u wraps as the product of unsigned longs does; the argument u a natural number, for the long that the C code passes non-negative; the high half of the 128-bit product by Ratpoints.Sieve.mulHi; the form with the 128-bit product, which the modelled builds compile (the compiler defines __SIZEOF_INT128__, and neither RP_MULMOD_DIVIDE nor RP_NO_INT128 is set), for the division u % p of the other builds, which gives the same remainder where the multiplication is exact.)

  • rp-private.h:409-410: modelled by Ratpoints.Sieve.mulDiv, Ratpoints.Sieve.mulHi (deviation of Ratpoints.Sieve.mulDiv: natural numbers for the unsigned long reciprocal, the long u and the long result, the arguments converted to UInt64, as the macro converts u to an unsigned long; the high half of the 128-bit product by Ratpoints.Sieve.mulHi; no argument p, which that form does not read; the form with the 128-bit product, which the modelled builds compile, for the division u / p of the other builds, which gives the same quotient where the multiplication is exact.) (deviation of Ratpoints.Sieve.mulHi: the high half of the product from the products of the 32-bit halves, for the product of type __uint128_t that gcc provides and Lean core does not.)

  • rp-private.h:411-411: modelled by Ratpoints.Sieve.mulMod (deviation of Ratpoints.Sieve.mulMod: natural numbers for the unsigned long reciprocal, the longs u and p, and the long result, which is below p; the arguments converted to UInt64, as the macro converts u and p to unsigned longs, so that the product m u wraps as the product of unsigned longs does; the argument u a natural number, for the long that the C code passes non-negative; the high half of the 128-bit product by Ratpoints.Sieve.mulHi; the form with the 128-bit product, which the modelled builds compile (the compiler defines __SIZEOF_INT128__, and neither RP_MULMOD_DIVIDE nor RP_NO_INT128 is set), for the division u % p of the other builds, which gives the same remainder where the multiplication is exact.)

  • rp-private.h:413-414: modelled by Ratpoints.Sieve.mulMod (deviation of Ratpoints.Sieve.mulMod: natural numbers for the unsigned long reciprocal, the longs u and p, and the long result, which is below p; the arguments converted to UInt64, as the macro converts u and p to unsigned longs, so that the product m u wraps as the product of unsigned longs does; the argument u a natural number, for the long that the C code passes non-negative; the high half of the 128-bit product by Ratpoints.Sieve.mulHi; the form with the 128-bit product, which the modelled builds compile (the compiler defines __SIZEOF_INT128__, and neither RP_MULMOD_DIVIDE nor RP_NO_INT128 is set), for the division u % p of the other builds, which gives the same remainder where the multiplication is exact.)

  • rp-private.h:415-416: modelled by Ratpoints.Sieve.mulDiv (deviation of Ratpoints.Sieve.mulDiv: natural numbers for the unsigned long reciprocal, the long u and the long result, the arguments converted to UInt64, as the macro converts u to an unsigned long; the high half of the 128-bit product by Ratpoints.Sieve.mulHi; no argument p, which that form does not read; the form with the 128-bit product, which the modelled builds compile, for the division u / p of the other builds, which gives the same quotient where the multiplication is exact.)

  • rp-private.h:417-417: modelled by Ratpoints.Sieve.mulMod (deviation of Ratpoints.Sieve.mulMod: natural numbers for the unsigned long reciprocal, the longs u and p, and the long result, which is below p; the arguments converted to UInt64, as the macro converts u and p to unsigned longs, so that the product m u wraps as the product of unsigned longs does; the argument u a natural number, for the long that the C code passes non-negative; the high half of the 128-bit product by Ratpoints.Sieve.mulHi; the form with the 128-bit product, which the modelled builds compile (the compiler defines __SIZEOF_INT128__, and neither RP_MULMOD_DIVIDE nor RP_NO_INT128 is set), for the division u % p of the other builds, which gives the same remainder where the multiplication is exact.)

  • rp-private.h:421-421: modelled by Ratpoints.mulModLimit

  • rp-private.h:426-427: modelled by Ratpoints.rowBias (deviation of Ratpoints.rowBias: the check at compile time that 2 RP_ROW_BIAS - 1 ≤ RP_MULMOD_LIMIT, an array of negative size otherwise, a theorem checked by decide (Ratpoints.two_mul_rowBias_sub_one_le_mulModLimit).)

  • rp-private.h:429-444: modelled by Ratpoints.Sieve.ctz (deviation of Ratpoints.Sieve.ctz: the loop for a compiler without the builtin, where gcc and clang take __builtin_ctzl.)

  • rp-private.h:450-456: excluded (other): RP_ALWAYS_INLINE and RP_NOINLINE, the inlining attributes that sift.c and find_points.c rely on for speed, empty on a compiler without them; they carry no meaning

  • rp-private.h:465-466: modelled by Ratpoints.Sieve.CheckSpec (deviation of Ratpoints.Sieve.CheckSpec: natural numbers for the longs and the unsigned long; the table an array of Booleans, for the pointer to the integers is_f_square of the sieve entry of the prime.)

  • rp-private.h:472-472: modelled by Ratpoints.stage3Limit (deviation of Ratpoints.stage3Limit: a natural number for the double 4294967296.0, which the C code compares with the double product 2 p H.)

  • rp-private.h:476-476: modelled by Ratpoints.numStrides

  • rp-private.h:494-495: modelled by Ratpoints.Sieve.NumClass (deviation of Ratpoints.Sieve.NumClass: one word for the bit array bits, the vector RBA(packed) of RBA_PACK copies of the word, which the first stage writes into every word of a bit array; natural numbers for the longs k and a0; the position of the row of offsets in the array of the offsets as an option, for the pointer offset into that array, none for NULL.)

  • rp-private.h:497-498: modelled by Ratpoints.Sieve.RowInit (deviation of Ratpoints.Sieve.RowInit: the kind of the builder, for the pointer to the function of the type ratpoints_init_fun, which for a prime points to the function that the build generates for it; the call through the pointer a match on the kind (Ratpoints.Sieve.SieveEntry.initRow, Ratpoints.Sieve.initFactorRow).)

  • rp-private.h:520-520: modelled by Ratpoints.maxFactors

  • rp-private.h:523-523: modelled by Ratpoints.modWords (deviation of Ratpoints.modWords: 64 for LONG_LENGTH.)

  • rp-private.h:531-534: modelled by Ratpoints.Sieve.Power (deviation of Ratpoints.Sieve.Power: an array of m natural numbers for the unsigned short inverses, for an array sized by RATPOINTS_MAX_PRIME_EVEN; no count np, which examine_power stores (find_points.c:2304) and nothing reads.)

  • rp-private.h:542-555: modelled by Ratpoints.Sieve.Entry, Ratpoints.Sieve.SieveEntry (deviation of Ratpoints.Sieve.Entry: only the fields that the rows of a prime read; the rows of the residues, which ratpoints keeps in the field sieve, that of 0 from the build and the others made by init when a denominator first needs them, are kept in the table of rows of the prime in the store of the run (Ratpoints.Sieve.EntryRef.prime, Ratpoints.Sieve.primeRows), from which the run reads them and into which it builds them (Ratpoints.Sieve.setRows, Ratpoints.Sieve.buildRows); the fields init, magic, nf, factor and pw are those of the sieve entry Ratpoints.Sieve.SieveEntry, of which the prime is the single factor, and so are bias, rbainv, dinv and the density r.) (deviation of Ratpoints.Sieve.SieveEntry: the kinds of modulus as the list of the factors: one prime factor for a prime, whose entry has nf = 0 and the tables is_f_square and inverses of its own; one prime-power factor for a prime power, whose entry has nf = 1 and its tables pw; and two or more for a product, whose entry has nf ≥ 2 and points to the entries factor of its factors; no bound RP_MAX_FACTORS on the number of factors, which the choice of the moduli keeps when it offers a composite modulus (Ratpoints.takeFactor); the rows of the residues, which ratpoints keeps in the array sieve of the entry, kept in the store of the run (Ratpoints.Sieve.RowStore) in the table of rows of the reference ref; the reference ref to the entry whose table of rows holds its rows (Ratpoints.Sieve.EntryRef), for the pointer to the entry: a prime or a prime power that of its one factor, so that the modulus and the products with it as a factor read one table of rows, as they read one entry in the C code, and a product its own; the kind of its builder init (Ratpoints.Sieve.RowInit), for the pointer to the function; a natural number for the unsigned long reciprocal magic, and natural numbers for the longs bias and rbainv; the inverses dinv an array, for the array of RP_NUM_STRIDES longs, which the row offsets of the packing fill (Ratpoints.Sieve.classOffsets) with an entry for each stride up to the largest in use, where the entries of the C code beyond it stay unset and unread; the density r, which the correction of the moduli during the run reads (Ratpoints.Sieve.adaptPrimes), a Float for the double, and the count nf of the factors, an integer for the long, 0 for a prime, 1 for a prime power and the number of factors for a product, kept with the list of the factors.)

  • rp-private.h:574-574: modelled by Ratpoints.Sieve.sift (deviation of Ratpoints.Sieve.sift: the height bound converted to Int64, which is exact for H < 2 ^ 63, and the denominator too, and the bits back to integers; the bounds of the search intervals an array, for the struct rp_intervals with its pointers bd and end, which sift reaches through the field iv of the sieving thread, which worker_init clears (line 3130) and run_block sets for each block (line 3913; here Ratpoints.Sieve.runBlock, which passes the array of the run on); one call of Ratpoints.Sieve.setRows, for the two calls with the flag shared a constant, between which the pool of threads chooses, which the model does not have; the store of the tables of rows passed and returned, for the arrays sieve of the entries of the arguments, which sift reaches through sieve_list and which keep the rows built for the rest of the run; the end sp1 of the first stage, the entries es and the reciprocals mgs of the first two stages, the entries es3 of the third stage and their reciprocals mgs3 as arguments, for the numbers sp1, sp2 and sp3 that the sieving thread keeps (worker_init), the entries sieve_list[0], …, sieve_list[sp2 - 1], the array magics of the arguments, which _ratpoints_sift0 reads, and the entries sieve_list[sp2], …, sieve_list[sp3 - 1] and the reciprocals magics[sp2], …, magics[sp3 - 1], which fill_checks reads, the cut points of the decision of the block (Ratpoints.Sieve.runBlock); the residues bp and the class cl as values, for the pointers bp_list and cls, and the array offsets of the row offsets of the run as an argument, which the C code reaches through the pointer offset of the class; the thunk of Ratpoints.Sieve.fillChecks, for the table checks of the sieving thread, which fill_checks fills, and its flag stage3_filled, which sift clears; the thunk of the products w, for the flag compute_bc, which sift sets and _ratpoints_check_point clears when it computes the products; the counters cnt passed and returned, for those of the sieving thread, the count sifts one up at the start (line 3461); the delivery r passed and returned, for the pointers info and wk->quit, which worker_init clears, and the count total that sift keeps from zero and returns; the arguments of the run passed explicitly, for the pointer args of the sieving thread (rp-private.h:574), which worker_init sets and through which sift reads them; no pool, slot and stop flag of a thread of the pool, the flag by which the pool of threads tells it to abandon its block (pool, slot, stop, rp-private.h:584, excluded with the threads); natural numbers and integers for the longs; no measurements of the phases (RP_SIFT_TIC, RP_SETUP_TIC and their TOC) and no output under DEBUG.)

  • rp-private.h:575-575: modelled by Ratpoints.Sieve.siftPiece (deviation of Ratpoints.Sieve.siftPiece: the arm of the first stage chosen by a test on the constant Ratpoints.chunk, for the conditional compilation #if (RATPOINTS_CHUNK > 1) && (RATPOINTS_CHUNK <= 16) (sift.c:452, sift.c:575, sift.c:943), which compiles one arm only, and tail_leg with the chunked one; a fresh array of zeros for each piece, for the survivors array of the sieving thread, which every piece reuses, with one bit array more for the alignment, and whose words malloc leaves uninitialized; the piece by its first word number w0 and its number n of bit arrays, for w_low and w_high, and an index for the pointer to its last bit array; the moduli of the first two stages with their rows and offsets as the list specs and the end sp1 of the first stage, for the sieve specs sieves and the number sp1 that the sieving thread keeps, the reciprocals of their moduli as the list mgs, for the array magics of the arguments, and the thunk checks, for the table checks of the third stage and its length nchecks = sp3 - sp2; the class cl as a value, for the pointer cls; integers for the longs of the test small, which stay longs, and a Boolean for its int; the counters cnt passed and returned, for the field n_words of the sieving thread, which counts the n Ratpoints.rbaPack words of the piece (line 548), the product of UInt64s as the C code multiplies the unsigned long by RBA_PACK; the thunk w of the products of the check as an argument, where _ratpoints_check_point computes the products when the first survivor of b reaches it; the delivery r passed and returned, for the pointers info and wk->quit and the count total that _ratpoints_sift0 keeps from zero and returns, and its returns at a stop within the walk through the set bits of a word passed on by the scan (Ratpoints.Sieve.scanPiece); natural numbers and integers for the longs; no measurements of the phases (RP_TIC, RP_TOC, RP_PHASE_TIMING) and no stop after one of them (RP_STOP_AFTER).)

  • rp-private.h:576-576: modelled by Ratpoints.Sieve.checkPoint (deviation of Ratpoints.Sieve.checkPoint: the products w as a thunk, which the sieve of one denominator makes for each denominator (Ratpoints.Sieve.sift) and which is forced when the first numerator of b reaches the check, for the array work of the sieving thread, which worker_init gives it, and its flag compute_bc, which sift sets and _ratpoints_check_point clears when it computes the products; the degree d and the flags fl as arguments, handed down from Ratpoints.Sieve.sieveRun through the components that call the check, for the degree and the bits RATPOINTS_REVERSED, RATPOINTS_NO_CHECK and RATPOINTS_NO_Y of the flags of the search, which _ratpoints_check_point reads through its worker (args->degree, args->flags); the delivery r passed and returned, for the pointers info and wk->quit and the count total that _ratpoints_check_point keeps from zero and returns, and the three branches of the map of the reversal at each call one definition (Ratpoints.Delivery.callMapped); the square root and the test of the remainder by Nat.sqrt on v, for mpz_sqrtrem; integers for the longs a and b (the negations of the map stay longs by Ratpoints.fitsLong_neg); no measurements of the time of the check and of its products (RP_CHECK, RP_BC_TIC, RP_BC_TOC under RP_PHASE_TIMING), and no output under DEBUG.)

  • rp-private.h:577-578: modelled by Ratpoints.Sieve.sift (deviation of Ratpoints.Sieve.sift: the height bound converted to Int64, which is exact for H < 2 ^ 63, and the denominator too, and the bits back to integers; the bounds of the search intervals an array, for the struct rp_intervals with its pointers bd and end, which sift reaches through the field iv of the sieving thread, which worker_init clears (line 3130) and run_block sets for each block (line 3913; here Ratpoints.Sieve.runBlock, which passes the array of the run on); one call of Ratpoints.Sieve.setRows, for the two calls with the flag shared a constant, between which the pool of threads chooses, which the model does not have; the store of the tables of rows passed and returned, for the arrays sieve of the entries of the arguments, which sift reaches through sieve_list and which keep the rows built for the rest of the run; the end sp1 of the first stage, the entries es and the reciprocals mgs of the first two stages, the entries es3 of the third stage and their reciprocals mgs3 as arguments, for the numbers sp1, sp2 and sp3 that the sieving thread keeps (worker_init), the entries sieve_list[0], …, sieve_list[sp2 - 1], the array magics of the arguments, which _ratpoints_sift0 reads, and the entries sieve_list[sp2], …, sieve_list[sp3 - 1] and the reciprocals magics[sp2], …, magics[sp3 - 1], which fill_checks reads, the cut points of the decision of the block (Ratpoints.Sieve.runBlock); the residues bp and the class cl as values, for the pointers bp_list and cls, and the array offsets of the row offsets of the run as an argument, which the C code reaches through the pointer offset of the class; the thunk of Ratpoints.Sieve.fillChecks, for the table checks of the sieving thread, which fill_checks fills, and its flag stage3_filled, which sift clears; the thunk of the products w, for the flag compute_bc, which sift sets and _ratpoints_check_point clears when it computes the products; the counters cnt passed and returned, for those of the sieving thread, the count sifts one up at the start (line 3461); the delivery r passed and returned, for the pointers info and wk->quit, which worker_init clears, and the count total that sift keeps from zero and returns; the arguments of the run passed explicitly, for the pointer args of the sieving thread (rp-private.h:574), which worker_init sets and through which sift reads them; no pool, slot and stop flag of a thread of the pool, the flag by which the pool of threads tells it to abandon its block (pool, slot, stop, rp-private.h:584, excluded with the threads); natural numbers and integers for the longs; no measurements of the phases (RP_SIFT_TIC, RP_SETUP_TIC and their TOC) and no output under DEBUG.)

  • rp-private.h:579-581: modelled by Ratpoints.Sieve.Counters (deviation of Ratpoints.Sieve.Counters: a structure of its own, which the components of the sieve that count pass and return beside the delivery, for the fields of the sieving thread rp_worker, which run_block clears for each block (find_points.c:3914-3915, Ratpoints.Sieve.runBlock); UInt64 for the unsigned longs, wrapping as they wrap.)

  • rp-private.h:582-582: modelled by Ratpoints.Sieve.runBlock (deviation of Ratpoints.Sieve.runBlock: the decision’s entries and reciprocals cut as lists for each block, for the numbers sp2 and sp3 that the sieving thread keeps and through which sift and fill_bp_list read the arrays sieve_list and magics; the report returned with the delivery and the store, for the fields of the sieving thread that worker_stat copies into it after the block; the counters and the index of the decision, which worker_init clears before the run (lines 3127-3128), set only here, for each block (lines 3911 and 3914-3915), before they are read; the arguments of the run passed explicitly, for the fields of the run and of the arguments that run_block reads; the delivery r passed and returned, for the pointers info and wk->quit and the count total that run_block keeps from zero and returns; the array bp_list of sp3_max entries on the stack, of which fill_bp_list fills the first sp2, a list made by Ratpoints.Sieve.siftDen; natural numbers for the longs.)

  • rp-private.h:583-583: modelled by Ratpoints.Sieve.sift (deviation of Ratpoints.Sieve.sift: the height bound converted to Int64, which is exact for H < 2 ^ 63, and the denominator too, and the bits back to integers; the bounds of the search intervals an array, for the struct rp_intervals with its pointers bd and end, which sift reaches through the field iv of the sieving thread, which worker_init clears (line 3130) and run_block sets for each block (line 3913; here Ratpoints.Sieve.runBlock, which passes the array of the run on); one call of Ratpoints.Sieve.setRows, for the two calls with the flag shared a constant, between which the pool of threads chooses, which the model does not have; the store of the tables of rows passed and returned, for the arrays sieve of the entries of the arguments, which sift reaches through sieve_list and which keep the rows built for the rest of the run; the end sp1 of the first stage, the entries es and the reciprocals mgs of the first two stages, the entries es3 of the third stage and their reciprocals mgs3 as arguments, for the numbers sp1, sp2 and sp3 that the sieving thread keeps (worker_init), the entries sieve_list[0], …, sieve_list[sp2 - 1], the array magics of the arguments, which _ratpoints_sift0 reads, and the entries sieve_list[sp2], …, sieve_list[sp3 - 1] and the reciprocals magics[sp2], …, magics[sp3 - 1], which fill_checks reads, the cut points of the decision of the block (Ratpoints.Sieve.runBlock); the residues bp and the class cl as values, for the pointers bp_list and cls, and the array offsets of the row offsets of the run as an argument, which the C code reaches through the pointer offset of the class; the thunk of Ratpoints.Sieve.fillChecks, for the table checks of the sieving thread, which fill_checks fills, and its flag stage3_filled, which sift clears; the thunk of the products w, for the flag compute_bc, which sift sets and _ratpoints_check_point clears when it computes the products; the counters cnt passed and returned, for those of the sieving thread, the count sifts one up at the start (line 3461); the delivery r passed and returned, for the pointers info and wk->quit, which worker_init clears, and the count total that sift keeps from zero and returns; the arguments of the run passed explicitly, for the pointer args of the sieving thread (rp-private.h:574), which worker_init sets and through which sift reads them; no pool, slot and stop flag of a thread of the pool, the flag by which the pool of threads tells it to abandon its block (pool, slot, stop, rp-private.h:584, excluded with the threads); natural numbers and integers for the longs; no measurements of the phases (RP_SIFT_TIC, RP_SETUP_TIC and their TOC) and no output under DEBUG.)

  • rp-private.h:584-584: excluded (threads): the pool, the slot of its block and the flag to abandon it of a thread of the pool; the calling thread, which the model is, has none

  • rp-private.h:585-585: modelled by Ratpoints.Sieve.sift (deviation of Ratpoints.Sieve.sift: the height bound converted to Int64, which is exact for H < 2 ^ 63, and the denominator too, and the bits back to integers; the bounds of the search intervals an array, for the struct rp_intervals with its pointers bd and end, which sift reaches through the field iv of the sieving thread, which worker_init clears (line 3130) and run_block sets for each block (line 3913; here Ratpoints.Sieve.runBlock, which passes the array of the run on); one call of Ratpoints.Sieve.setRows, for the two calls with the flag shared a constant, between which the pool of threads chooses, which the model does not have; the store of the tables of rows passed and returned, for the arrays sieve of the entries of the arguments, which sift reaches through sieve_list and which keep the rows built for the rest of the run; the end sp1 of the first stage, the entries es and the reciprocals mgs of the first two stages, the entries es3 of the third stage and their reciprocals mgs3 as arguments, for the numbers sp1, sp2 and sp3 that the sieving thread keeps (worker_init), the entries sieve_list[0], …, sieve_list[sp2 - 1], the array magics of the arguments, which _ratpoints_sift0 reads, and the entries sieve_list[sp2], …, sieve_list[sp3 - 1] and the reciprocals magics[sp2], …, magics[sp3 - 1], which fill_checks reads, the cut points of the decision of the block (Ratpoints.Sieve.runBlock); the residues bp and the class cl as values, for the pointers bp_list and cls, and the array offsets of the row offsets of the run as an argument, which the C code reaches through the pointer offset of the class; the thunk of Ratpoints.Sieve.fillChecks, for the table checks of the sieving thread, which fill_checks fills, and its flag stage3_filled, which sift clears; the thunk of the products w, for the flag compute_bc, which sift sets and _ratpoints_check_point clears when it computes the products; the counters cnt passed and returned, for those of the sieving thread, the count sifts one up at the start (line 3461); the delivery r passed and returned, for the pointers info and wk->quit, which worker_init clears, and the count total that sift keeps from zero and returns; the arguments of the run passed explicitly, for the pointer args of the sieving thread (rp-private.h:574), which worker_init sets and through which sift reads them; no pool, slot and stop flag of a thread of the pool, the flag by which the pool of threads tells it to abandon its block (pool, slot, stop, rp-private.h:584, excluded with the threads); natural numbers and integers for the longs; no measurements of the phases (RP_SIFT_TIC, RP_SETUP_TIC and their TOC) and no output under DEBUG.)

  • rp-private.h:592-592: modelled by Ratpoints.Sieve.sieveInitPower (deviation of Ratpoints.Sieve.sieveInitPower: the tables of the prime power and the reference to its entry (Ratpoints.Sieve.EntryRef) as arguments, for the sieve entry se whose field pw points to the tables and into which the C code stores the row, and the store of the tables of rows of the run passed and returned, for the arrays sieve of the entries; the pattern a fresh array, which the loop clears, for the array whose words the function leaves unset until it clears them; the row stored plainly, for the release store of RP_PUBLISH in a build with threads, which the model does not have.)

  • rp-private.h:593-593: modelled by Ratpoints.Sieve.sieveInitProduct (deviation of Ratpoints.Sieve.sieveInitProduct: the store of the tables of rows passed and returned, for the entries of the factors that the C code reaches through the pointers factor and for the entry se into which it stores the row; a fresh vector of (m + chunk - 1) rbaPack words, for the space that the builder takes from the buffer of the tables (ba_next) after the rows of the factors; the row stored plainly, for the release store of RP_PUBLISH in a build with threads, which the model does not have; the number of the factors the length of their list, for the count nf.)

  • rp-private.h:596-597: modelled by Ratpoints.Sieve.checkPoint (deviation of Ratpoints.Sieve.checkPoint: the products w as a thunk, which the sieve of one denominator makes for each denominator (Ratpoints.Sieve.sift) and which is forced when the first numerator of b reaches the check, for the array work of the sieving thread, which worker_init gives it, and its flag compute_bc, which sift sets and _ratpoints_check_point clears when it computes the products; the degree d and the flags fl as arguments, handed down from Ratpoints.Sieve.sieveRun through the components that call the check, for the degree and the bits RATPOINTS_REVERSED, RATPOINTS_NO_CHECK and RATPOINTS_NO_Y of the flags of the search, which _ratpoints_check_point reads through its worker (args->degree, args->flags); the delivery r passed and returned, for the pointers info and wk->quit and the count total that _ratpoints_check_point keeps from zero and returns, and the three branches of the map of the reversal at each call one definition (Ratpoints.Delivery.callMapped); the square root and the test of the remainder by Nat.sqrt on v, for mpz_sqrtrem; integers for the longs a and b (the negations of the map stay longs by Ratpoints.fitsLong_neg); no measurements of the time of the check and of its products (RP_CHECK, RP_BC_TIC, RP_BC_TOC under RP_PHASE_TIMING), and no output under DEBUG.)

  • rp-private.h:610-614: modelled by Ratpoints.Sieve.siftPiece (deviation of Ratpoints.Sieve.siftPiece: the arm of the first stage chosen by a test on the constant Ratpoints.chunk, for the conditional compilation #if (RATPOINTS_CHUNK > 1) && (RATPOINTS_CHUNK <= 16) (sift.c:452, sift.c:575, sift.c:943), which compiles one arm only, and tail_leg with the chunked one; a fresh array of zeros for each piece, for the survivors array of the sieving thread, which every piece reuses, with one bit array more for the alignment, and whose words malloc leaves uninitialized; the piece by its first word number w0 and its number n of bit arrays, for w_low and w_high, and an index for the pointer to its last bit array; the moduli of the first two stages with their rows and offsets as the list specs and the end sp1 of the first stage, for the sieve specs sieves and the number sp1 that the sieving thread keeps, the reciprocals of their moduli as the list mgs, for the array magics of the arguments, and the thunk checks, for the table checks of the third stage and its length nchecks = sp3 - sp2; the class cl as a value, for the pointer cls; integers for the longs of the test small, which stay longs, and a Boolean for its int; the counters cnt passed and returned, for the field n_words of the sieving thread, which counts the n Ratpoints.rbaPack words of the piece (line 548), the product of UInt64s as the C code multiplies the unsigned long by RBA_PACK; the thunk w of the products of the check as an argument, where _ratpoints_check_point computes the products when the first survivor of b reaches it; the delivery r passed and returned, for the pointers info and wk->quit and the count total that _ratpoints_sift0 keeps from zero and returns, and its returns at a stop within the walk through the set bits of a word passed on by the scan (Ratpoints.Sieve.scanPiece); natural numbers and integers for the longs; no measurements of the phases (RP_TIC, RP_TOC, RP_PHASE_TIMING) and no stop after one of them (RP_STOP_AFTER).)

  • rp-private.h:617-617: excluded (interface): the prototype of _ratpoints_compute_sturm, which find_points.c calls; the model has no headers (Ratpoints.Sturm.computeSturm)

ratpoints.h

  • ratpoints.h:31-31: excluded (other): the include of gmp.h, the header of GMP; the model has no headers

  • ratpoints.h:33-33: modelled by Ratpoints.maxDegree

  • ratpoints.h:42-42: excluded (other): RATPOINTS_DEFAULT_SP1, the fixed end of the first stage of the versions 2.x, which the C code reads nowhere: the library chooses the end of the first stage from the curve (sieving_info)

  • ratpoints.h:43-43: excluded (other): RATPOINTS_DEFAULT_SP2, the fixed end of the second stage of the versions 2.x, which the C code reads nowhere

  • ratpoints.h:92-94: modelled by Ratpoints.survivorsPerWord

  • ratpoints.h:95-97: modelled by Ratpoints.sp2Extra

  • ratpoints.h:120-122: modelled by Ratpoints.sp2U0

  • ratpoints.h:150-152: modelled by Ratpoints.sp3PerSurvivor

  • ratpoints.h:153-155: modelled by Ratpoints.sp3PerDenom

  • ratpoints.h:164-166: modelled by Ratpoints.sp3Coprime

  • ratpoints.h:192-194: modelled by Ratpoints.costTable

  • ratpoints.h:210-212: modelled by Ratpoints.compositeMax

  • ratpoints.h:213-218: modelled by Ratpoints.costBp

  • ratpoints.h:224-226: modelled by Ratpoints.costSetup

  • ratpoints.h:241-243: modelled by Ratpoints.costCall

  • ratpoints.h:258-260: modelled by Ratpoints.costLine

  • ratpoints.h:261-263: modelled by Ratpoints.costPhase2

  • ratpoints.h:270-272: modelled by Ratpoints.costSurvivor

  • ratpoints.h:280-282: modelled by Ratpoints.costCheck

  • ratpoints.h:312-314: modelled by Ratpoints.checkStep

  • ratpoints.h:315-317: modelled by Ratpoints.checkLimb

  • ratpoints.h:318-320: modelled by Ratpoints.checkCall

  • ratpoints.h:321-323: modelled by Ratpoints.checkRoot

  • ratpoints.h:329-331: modelled by Ratpoints.checkReference

  • ratpoints.h:333-340: modelled by Ratpoints.defaultNumPrimes

  • ratpoints.h:341-343: modelled by Ratpoints.defaultSturm

  • ratpoints.h:345-352: modelled by Ratpoints.defaultMaxForbidden

  • ratpoints.h:354-356: modelled by Ratpoints.defaultArraySize

  • ratpoints.h:359-359: modelled by Ratpoints.Options (deviation of Ratpoints.Options: a structure for the fields of ratpoints_args that hold these options: Booleans for the bits RATPOINTS_NO_CHECK, RATPOINTS_NO_Y and RATPOINTS_NO_REVERSE of the flags, noCheck and noY true when their bits are set, reverse true when RATPOINTS_NO_REVERSE is clear, so that all three defaults are those of the cleared flags (main.c, line 352); of the other bits of the flags, which main.c clears with these, the Jacobi switch is that of the options of the sieve (Ratpoints.SieveOptions.jacobi), and RATPOINTS_VERBOSE is the print channel of the search (Ratpoints.findPointsVerbose), which the program makes from Ratpoints.Cli.Output.verbose; an integer for args->sturm; a list of pairs of doubles (Ratpoints.Double) for the array domain of the type ratpoints_interval with the number num_inter of its intervals, the empty list for num_inter = 0, so that no number of intervals is negative and the room in the array for the intervals of the Sturm step is no concern of the caller; integers for the longs b_low and b_high; of the fields that share their lines in ratpoints.h, sp1, sp2, num_primes and max_forbidden are read by the options of the sieve (Ratpoints.SieveOptions), and sp3 is the end of the third stage of the choice (Ratpoints.Params.sp3), corrected during the run (Ratpoints.Sieve.Correction).)

  • ratpoints.h:362-362: modelled by Ratpoints.findPointsVerbose (deviation of Ratpoints.findPointsVerbose: one function for find_points, find_points_work and the start of find_points_work_1, which the library calls in turn, and the rest of which is Ratpoints.findPointsWork. The refusals of the program, in its order and with its errors (Ratpoints.Refusal), returned apart from the outcome with the data of the callback, for the negative codes of the library (RATPOINTS_NON_SQUAREFREE and RATPOINTS_BAD_ARGS; RATPOINTS_WORK_LENGTH_TOO_SMALL and RATPOINTS_NO_MEMORY cannot arise), which share the long that find_points returns with the count, the caller keeping its data behind the pointer info: fewer than two coefficients are refused on the length of c, as the program refuses them, where the library refuses an empty list as a negative degree and one coefficient as the degree 0 (a longer list of degree 0 fails the test of the leading zeros first); and the height bound, which the program checks before it calls the library, comes before the test of the leading zeros, which the library makes first, so that 5 0 with H = 0 is error 4, as the program gives it. The degree with the leading zeros dropped is Ratpoints.BruteForce.degree c. A natural number H for the long height of the arguments (ratpoints.h:362), so that H = 0 stands for the heights below 1 that line 4658 refuses; a height that is not a long, 2 ^ 63 or more, is refused with error 4, as the program refuses it when it reads the height (Ratpoints.Cli.heightBound), where the library cannot be given one, its height being a long. The end of the type ratpoints_args (ratpoints.h:399-400) with its first fields, whose other fields are those of the options, the parameters, the result of the choice of the moduli and the outcome (Ratpoints.Options, Ratpoints.SieveOptions, Ratpoints.Params, Ratpoints.SievingInfo, Ratpoints.Outcome), of the divisor set-up (Ratpoints.Setup.setupUs1), or excluded. A list for the array of GMP integers and its scratch integers work, with nothing written back to the caller but the data of the callback, the count, three bits of the flags, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), which are 0 unless the search sets them, as find_points_work zeroes them on entry with the working field sp3, so that there is no state between calls and the reset of the flags clears nothing; the callback a function that returns what the call gives (Ratpoints.Answer), and its data a value, for the pointer info; the bit RATPOINTS_VERBOSE of the flags as the print channel print, a function that prints a text into the data of the callback, which holds the standard output of the caller, so that the text comes between the points as on the standard output of the C program, and which prints nothing when the bit is clear; the options of the output as fields of the options (Ratpoints.Options), copied into the flags of the check (Ratpoints.CheckFlags) with the flag of the reversal, for the bits of args->flags that the mask of line 4606 keeps; the points at infinity and the square test of the leading coefficient are decided where they are used (Ratpoints.Sieve.pointsAtInfinity, Ratpoints.Setup.reversal, Ratpoints.sturmRegion, Ratpoints.searchPoints); no failure for lack of memory, which the model cannot meet.)

  • ratpoints.h:363-364: modelled by Ratpoints.Options (deviation of Ratpoints.Options: a structure for the fields of ratpoints_args that hold these options: Booleans for the bits RATPOINTS_NO_CHECK, RATPOINTS_NO_Y and RATPOINTS_NO_REVERSE of the flags, noCheck and noY true when their bits are set, reverse true when RATPOINTS_NO_REVERSE is clear, so that all three defaults are those of the cleared flags (main.c, line 352); of the other bits of the flags, which main.c clears with these, the Jacobi switch is that of the options of the sieve (Ratpoints.SieveOptions.jacobi), and RATPOINTS_VERBOSE is the print channel of the search (Ratpoints.findPointsVerbose), which the program makes from Ratpoints.Cli.Output.verbose; an integer for args->sturm; a list of pairs of doubles (Ratpoints.Double) for the array domain of the type ratpoints_interval with the number num_inter of its intervals, the empty list for num_inter = 0, so that no number of intervals is negative and the room in the array for the intervals of the Sturm step is no concern of the caller; integers for the longs b_low and b_high; of the fields that share their lines in ratpoints.h, sp1, sp2, num_primes and max_forbidden are read by the options of the sieve (Ratpoints.SieveOptions), and sp3 is the end of the third stage of the choice (Ratpoints.Params.sp3), corrected during the run (Ratpoints.Sieve.Correction).)

  • ratpoints.h:365-367: modelled by Ratpoints.SieveOptions (deviation of Ratpoints.SieveOptions: integers for the longs of the fields, doubles by their bits (Ratpoints.Double) for the doubles, as the program reads doubles (Ratpoints.Cli.scanDouble?), and a Boolean for the bit RATPOINTS_NO_JACOBI of the flags, which main.c clears with the others; the bit of the reversal is in Ratpoints.Options.)

  • ratpoints.h:368-368: modelled by Ratpoints.Params (deviation of Ratpoints.Params: the parameters as a structure of their own, for the fields of the arguments that find_points_work normalizes and sieving_info sets (sp1, sp2, sp3, max_forbidden, array_size, run_words, run_denoms, adapt_at, check_rel; sp3_max as the length of Ratpoints.SievingInfo.entries) and the local pn_lim of sieving_info at the end (lookedAt); the Jacobi switch a Boolean (Ratpoints.Params.jacobi), true when the bit RATPOINTS_NO_JACOBI of the flags is clear, for that bit of args->flags, which main.c clears with the others; a natural number for the long field array_size (Ratpoints.Params.arraySize), 0 for the default, which the library takes for every value ≤ 0 (Ratpoints.Params.arraySizeAt); Floats for the doubles and a UInt64 for the unsigned long.)

  • ratpoints.h:369-369: modelled by Ratpoints.Options (deviation of Ratpoints.Options: a structure for the fields of ratpoints_args that hold these options: Booleans for the bits RATPOINTS_NO_CHECK, RATPOINTS_NO_Y and RATPOINTS_NO_REVERSE of the flags, noCheck and noY true when their bits are set, reverse true when RATPOINTS_NO_REVERSE is clear, so that all three defaults are those of the cleared flags (main.c, line 352); of the other bits of the flags, which main.c clears with these, the Jacobi switch is that of the options of the sieve (Ratpoints.SieveOptions.jacobi), and RATPOINTS_VERBOSE is the print channel of the search (Ratpoints.findPointsVerbose), which the program makes from Ratpoints.Cli.Output.verbose; an integer for args->sturm; a list of pairs of doubles (Ratpoints.Double) for the array domain of the type ratpoints_interval with the number num_inter of its intervals, the empty list for num_inter = 0, so that no number of intervals is negative and the room in the array for the intervals of the Sturm step is no concern of the caller; integers for the longs b_low and b_high; of the fields that share their lines in ratpoints.h, sp1, sp2, num_primes and max_forbidden are read by the options of the sieve (Ratpoints.SieveOptions), and sp3 is the end of the third stage of the choice (Ratpoints.Params.sp3), corrected during the run (Ratpoints.Sieve.Correction).)

  • ratpoints.h:370-376: excluded (threads): the number of threads that sieve; the model sieves on the calling thread, with the same output for every number of threads

  • ratpoints.h:377-383: modelled by Ratpoints.Outcome (deviation of Ratpoints.Outcome: a structure for what the C code returns and writes back into the arguments: the data of the callback, which the caller has behind its pointer info, the count, which find_points returns as a long that also carries its error codes (Ratpoints.findPointsWith returns the refusals apart), Booleans for three bits of args->flags, and the search intervals as a list, for the array args->domain and the number args->num_inter that the search writes back and the program reads after it; nothing else written back: neither the reversed coefficients and the degree (args->cof, args->degree), which nothing reads after the search; nor the other internal bits of the flags, RATPOINTS_CHECK_DENOM, RATPOINTS_USE_JACOBI and RATPOINTS_NO_REVERSE_AUTO, which the program does not read either, the bits of the input coming back as the caller set them (find_points.c:4606), which the program takes from its own options and settings (Ratpoints.Options, Ratpoints.SieveOptions.jacobi, Ratpoints.Cli.Output.verbose); nor args->sp3, which find_points_work zeroes on entry (line 4551) and leaves as the search leaves it, unlike sp2, which it restores (line 4561): the end of the third stage of the last block sifted (line 5163), that of the choice after the returns between the choice and the sieve, where sp3_used stays 0, and 0 after the returns before the choice and after the exits of the choice when the curve has no points modulo a prime (find_points.c:2614, find_points.c:2998), which come before line 3017 sets it; nor the private fields that sieving_info and adapt_primes write, adapt_at, run_words, run_denoms, sp3_max and check_rel, which nothing reads before sieving_info sets them again in the next search; natural numbers for the longs sp1_used, sp2_used and sp3_used.)

  • ratpoints.h:385-388: excluded (memory): the private fields of the arguments that hold memory: the scratch integers of the search with their number (work, work_length), and the buffers of the sieve entries, of the bit arrays of the rows and of the integers of the tables of the primes, each with the pointer to its free space (se_buffer, se_next, ba_buffer, ba_next, int_buffer, int_next), which find_points_init allocates (find_points.c:272-375, excluded as interface); the model computes with Lean’s integers and makes the entries, the rows and the tables as fresh values

  • ratpoints.h:389-389: modelled by Ratpoints.SievingInfo (deviation of Ratpoints.SievingInfo: a structure for what sieving_info writes into the arguments, the arrays sieve_list and magics (line 389) and forb_ba and forbidden (line 391) as lists, for the arrays with their counts, the bit RATPOINTS_CHECK_DENOM of the flags as a Boolean and the fields of the result (Ratpoints.Params), and into the entries, the arrays sieve as the store of the tables of rows; no field for the array stage3_list (line 389), the buffer of the table of the third stage that the sieving thread fills for each denominator (find_points.c:5127), which the model replaces by the thunk of the checks (Ratpoints.Sieve.fillChecks, Ratpoints.Sieve.sift).)

  • ratpoints.h:390-390: modelled by Ratpoints.Setup.setupUs1 (deviation of Ratpoints.Setup.setupUs1: the leading coefficient read from the list, for the integer work[0] that the caller sets to |c_d| (lines 4911-4912); lists, for the arrays den_info and divisors of the arguments (ratpoints.h:390) with their terminating zeros; none for a factorization that is not complete or too many divisors, where setup_us1 leaves the flag RATPOINTS_USE_SQUARES1 clear, and the lists returned, where it sets the flag; no output under DEBUG.)

  • ratpoints.h:391-391: modelled by Ratpoints.SievingInfo (deviation of Ratpoints.SievingInfo: a structure for what sieving_info writes into the arguments, the arrays sieve_list and magics (line 389) and forb_ba and forbidden (line 391) as lists, for the arrays with their counts, the bit RATPOINTS_CHECK_DENOM of the flags as a Boolean and the fields of the result (Ratpoints.Params), and into the entries, the arrays sieve as the store of the tables of rows; no field for the array stage3_list (line 389), the buffer of the table of the third stage that the sieving thread fills for each denominator (find_points.c:5127), which the model replaces by the thunk of the checks (Ratpoints.Sieve.fillChecks, Ratpoints.Sieve.sift).)

  • ratpoints.h:392-394: excluded (memory): the private fields of the arguments that hold memory: the buffer of the words of the forbidden divisors beyond the table with its length (forb_words, forb_words_len), the buffer of the rows as allocated, with the primes and the bit arrays it has room for (ba_buffer_na, ba_buffer_primes, ba_buffer_arrays), and the buffer of the prime powers (pw_buffer); the model makes the words, the rows and the records of the prime powers as fresh values (Ratpoints.Sieve.forbiddenRow, Ratpoints.Sieve.examinePower)

  • ratpoints.h:395-397: modelled by Ratpoints.Params (deviation of Ratpoints.Params: the parameters as a structure of their own, for the fields of the arguments that find_points_work normalizes and sieving_info sets (sp1, sp2, sp3, max_forbidden, array_size, run_words, run_denoms, adapt_at, check_rel; sp3_max as the length of Ratpoints.SievingInfo.entries) and the local pn_lim of sieving_info at the end (lookedAt); the Jacobi switch a Boolean (Ratpoints.Params.jacobi), true when the bit RATPOINTS_NO_JACOBI of the flags is clear, for that bit of args->flags, which main.c clears with the others; a natural number for the long field array_size (Ratpoints.Params.arraySize), 0 for the default, which the library takes for every value ≤ 0 (Ratpoints.Params.arraySizeAt); Floats for the doubles and a UInt64 for the unsigned long.)

  • ratpoints.h:398-398: excluded (threads): the pool of threads of the arguments; the model has no threads

  • ratpoints.h:399-400: modelled by Ratpoints.findPointsVerbose (deviation of Ratpoints.findPointsVerbose: one function for find_points, find_points_work and the start of find_points_work_1, which the library calls in turn, and the rest of which is Ratpoints.findPointsWork. The refusals of the program, in its order and with its errors (Ratpoints.Refusal), returned apart from the outcome with the data of the callback, for the negative codes of the library (RATPOINTS_NON_SQUAREFREE and RATPOINTS_BAD_ARGS; RATPOINTS_WORK_LENGTH_TOO_SMALL and RATPOINTS_NO_MEMORY cannot arise), which share the long that find_points returns with the count, the caller keeping its data behind the pointer info: fewer than two coefficients are refused on the length of c, as the program refuses them, where the library refuses an empty list as a negative degree and one coefficient as the degree 0 (a longer list of degree 0 fails the test of the leading zeros first); and the height bound, which the program checks before it calls the library, comes before the test of the leading zeros, which the library makes first, so that 5 0 with H = 0 is error 4, as the program gives it. The degree with the leading zeros dropped is Ratpoints.BruteForce.degree c. A natural number H for the long height of the arguments (ratpoints.h:362), so that H = 0 stands for the heights below 1 that line 4658 refuses; a height that is not a long, 2 ^ 63 or more, is refused with error 4, as the program refuses it when it reads the height (Ratpoints.Cli.heightBound), where the library cannot be given one, its height being a long. The end of the type ratpoints_args (ratpoints.h:399-400) with its first fields, whose other fields are those of the options, the parameters, the result of the choice of the moduli and the outcome (Ratpoints.Options, Ratpoints.SieveOptions, Ratpoints.Params, Ratpoints.SievingInfo, Ratpoints.Outcome), of the divisor set-up (Ratpoints.Setup.setupUs1), or excluded. A list for the array of GMP integers and its scratch integers work, with nothing written back to the caller but the data of the callback, the count, three bits of the flags, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), which are 0 unless the search sets them, as find_points_work zeroes them on entry with the working field sp3, so that there is no state between calls and the reset of the flags clears nothing; the callback a function that returns what the call gives (Ratpoints.Answer), and its data a value, for the pointer info; the bit RATPOINTS_VERBOSE of the flags as the print channel print, a function that prints a text into the data of the callback, which holds the standard output of the caller, so that the text comes between the points as on the standard output of the C program, and which prints nothing when the bit is clear; the options of the output as fields of the options (Ratpoints.Options), copied into the flags of the check (Ratpoints.CheckFlags) with the flag of the reversal, for the bits of args->flags that the mask of line 4606 keeps; the points at infinity and the square test of the leading coefficient are decided where they are used (Ratpoints.Sieve.pointsAtInfinity, Ratpoints.Setup.reversal, Ratpoints.sturmRegion, Ratpoints.searchPoints); no failure for lack of memory, which the model cannot meet.)

  • ratpoints.h:403-405: modelled by Ratpoints.Options (deviation of Ratpoints.Options: a structure for the fields of ratpoints_args that hold these options: Booleans for the bits RATPOINTS_NO_CHECK, RATPOINTS_NO_Y and RATPOINTS_NO_REVERSE of the flags, noCheck and noY true when their bits are set, reverse true when RATPOINTS_NO_REVERSE is clear, so that all three defaults are those of the cleared flags (main.c, line 352); of the other bits of the flags, which main.c clears with these, the Jacobi switch is that of the options of the sieve (Ratpoints.SieveOptions.jacobi), and RATPOINTS_VERBOSE is the print channel of the search (Ratpoints.findPointsVerbose), which the program makes from Ratpoints.Cli.Output.verbose; an integer for args->sturm; a list of pairs of doubles (Ratpoints.Double) for the array domain of the type ratpoints_interval with the number num_inter of its intervals, the empty list for num_inter = 0, so that no number of intervals is negative and the room in the array for the intervals of the Sturm step is no concern of the caller; integers for the longs b_low and b_high; of the fields that share their lines in ratpoints.h, sp1, sp2, num_primes and max_forbidden are read by the options of the sieve (Ratpoints.SieveOptions), and sp3 is the end of the third stage of the choice (Ratpoints.Params.sp3), corrected during the run (Ratpoints.Sieve.Correction).)

  • ratpoints.h:406-406: modelled by Ratpoints.Params (deviation of Ratpoints.Params: the parameters as a structure of their own, for the fields of the arguments that find_points_work normalizes and sieving_info sets (sp1, sp2, sp3, max_forbidden, array_size, run_words, run_denoms, adapt_at, check_rel; sp3_max as the length of Ratpoints.SievingInfo.entries) and the local pn_lim of sieving_info at the end (lookedAt); the Jacobi switch a Boolean (Ratpoints.Params.jacobi), true when the bit RATPOINTS_NO_JACOBI of the flags is clear, for that bit of args->flags, which main.c clears with the others; a natural number for the long field array_size (Ratpoints.Params.arraySize), 0 for the default, which the library takes for every value ≤ 0 (Ratpoints.Params.arraySizeAt); Floats for the doubles and a UInt64 for the unsigned long.)

  • ratpoints.h:407-407: modelled by Ratpoints.Cli.Output (deviation of Ratpoints.Cli.Output: a structure for the global variables; Option String for the strings and the format, none for the null pointer, and Lean strings for the C strings of the command line, which the Lean runtime decodes as UTF-8 (bytes that do not form UTF-8 are read as U+FFFD, one for each malformed sequence as the Lean runtime cuts them, where main.c copies the bytes); the bit RATPOINTS_VERBOSE of args->flags a field here, from which the program makes the print channel of the library (Ratpoints.Cli.run).)

  • ratpoints.h:409-411: modelled by Ratpoints.findPointsVerbose (deviation of Ratpoints.findPointsVerbose: one function for find_points, find_points_work and the start of find_points_work_1, which the library calls in turn, and the rest of which is Ratpoints.findPointsWork. The refusals of the program, in its order and with its errors (Ratpoints.Refusal), returned apart from the outcome with the data of the callback, for the negative codes of the library (RATPOINTS_NON_SQUAREFREE and RATPOINTS_BAD_ARGS; RATPOINTS_WORK_LENGTH_TOO_SMALL and RATPOINTS_NO_MEMORY cannot arise), which share the long that find_points returns with the count, the caller keeping its data behind the pointer info: fewer than two coefficients are refused on the length of c, as the program refuses them, where the library refuses an empty list as a negative degree and one coefficient as the degree 0 (a longer list of degree 0 fails the test of the leading zeros first); and the height bound, which the program checks before it calls the library, comes before the test of the leading zeros, which the library makes first, so that 5 0 with H = 0 is error 4, as the program gives it. The degree with the leading zeros dropped is Ratpoints.BruteForce.degree c. A natural number H for the long height of the arguments (ratpoints.h:362), so that H = 0 stands for the heights below 1 that line 4658 refuses; a height that is not a long, 2 ^ 63 or more, is refused with error 4, as the program refuses it when it reads the height (Ratpoints.Cli.heightBound), where the library cannot be given one, its height being a long. The end of the type ratpoints_args (ratpoints.h:399-400) with its first fields, whose other fields are those of the options, the parameters, the result of the choice of the moduli and the outcome (Ratpoints.Options, Ratpoints.SieveOptions, Ratpoints.Params, Ratpoints.SievingInfo, Ratpoints.Outcome), of the divisor set-up (Ratpoints.Setup.setupUs1), or excluded. A list for the array of GMP integers and its scratch integers work, with nothing written back to the caller but the data of the callback, the count, three bits of the flags, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), which are 0 unless the search sets them, as find_points_work zeroes them on entry with the working field sp3, so that there is no state between calls and the reset of the flags clears nothing; the callback a function that returns what the call gives (Ratpoints.Answer), and its data a value, for the pointer info; the bit RATPOINTS_VERBOSE of the flags as the print channel print, a function that prints a text into the data of the callback, which holds the standard output of the caller, so that the text comes between the points as on the standard output of the C program, and which prints nothing when the bit is clear; the options of the output as fields of the options (Ratpoints.Options), copied into the flags of the check (Ratpoints.CheckFlags) with the flag of the reversal, for the bits of args->flags that the mask of line 4606 keeps; the points at infinity and the square test of the leading coefficient are decided where they are used (Ratpoints.Sieve.pointsAtInfinity, Ratpoints.Setup.reversal, Ratpoints.sturmRegion, Ratpoints.searchPoints); no failure for lack of memory, which the model cannot meet.)

  • ratpoints.h:414-414: modelled by Ratpoints.CheckFlags, Ratpoints.Outcome (deviation of Ratpoints.CheckFlags: a structure with a Boolean for each of the three bits, for the bits of the word flags of the arguments, which _ratpoints_check_point reads through its worker and find_points_work_1 directly; the bits RATPOINTS_NO_CHECK and RATPOINTS_NO_Y copied from the options of the search (Ratpoints.Options), and RATPOINTS_REVERSED from the reversal check (Ratpoints.Setup.reversal).) (deviation of Ratpoints.Outcome: a structure for what the C code returns and writes back into the arguments: the data of the callback, which the caller has behind its pointer info, the count, which find_points returns as a long that also carries its error codes (Ratpoints.findPointsWith returns the refusals apart), Booleans for three bits of args->flags, and the search intervals as a list, for the array args->domain and the number args->num_inter that the search writes back and the program reads after it; nothing else written back: neither the reversed coefficients and the degree (args->cof, args->degree), which nothing reads after the search; nor the other internal bits of the flags, RATPOINTS_CHECK_DENOM, RATPOINTS_USE_JACOBI and RATPOINTS_NO_REVERSE_AUTO, which the program does not read either, the bits of the input coming back as the caller set them (find_points.c:4606), which the program takes from its own options and settings (Ratpoints.Options, Ratpoints.SieveOptions.jacobi, Ratpoints.Cli.Output.verbose); nor args->sp3, which find_points_work zeroes on entry (line 4551) and leaves as the search leaves it, unlike sp2, which it restores (line 4561): the end of the third stage of the last block sifted (line 5163), that of the choice after the returns between the choice and the sieve, where sp3_used stays 0, and 0 after the returns before the choice and after the exits of the choice when the curve has no points modulo a prime (find_points.c:2614, find_points.c:2998), which come before line 3017 sets it; nor the private fields that sieving_info and adapt_primes write, adapt_at, run_words, run_denoms, sp3_max and check_rel, which nothing reads before sieving_info sets them again in the next search; natural numbers for the longs sp1_used, sp2_used and sp3_used.)

  • ratpoints.h:415-415: modelled by Ratpoints.searchPoints (deviation of Ratpoints.searchPoints: the range of the denominators, the search intervals and the flag sturm_empty as arguments, for the fields b_low, b_high, domain and num_inter of the arguments and the local flag of find_points_work_1; the flags of the denominators as Booleans, for the bits of args->flags; the divisors of the leading coefficient with their records as lists, for the arrays args->den_info and args->divisors of the arguments; the square test lcfsq of line 4906 made on the polynomial searched (Ratpoints.Setup.isSquare), where the C code computes it before the reversal check (line 4634) and clears it in case 2 (line 4770): the same value for an even degree, the only one that reads it; the array size normalized for the height bound where the estimate of the run reads it (Ratpoints.arraySizeAt); the test on point_at_infty of the 2-adic exit recomputed, as Ratpoints.Sieve.pointsAtInfinity decides it; the 2-adic exit returns the delivery with the message, nothing delivered, where find_points_work_1 returns the count 0; the delivery passed, for the pointer info, the local flag quit of find_points_work_1 and the count total, and the result with the bits of the flags written back, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), for the bits that find_points_work_1 sets in args->flags, the intervals that it leaves in args->domain and the fields sp1_used, sp2_used and sp3_used that the part after the choice sets (Ratpoints.chooseAndSearch); the report under RATPOINTS_VERBOSE printed through the print channel, the lines of the tests on the denominators together after the divisor set-up, which prints nothing; no output under DEBUG.)

  • ratpoints.h:416-417: modelled by Ratpoints.Outcome (deviation of Ratpoints.Outcome: a structure for what the C code returns and writes back into the arguments: the data of the callback, which the caller has behind its pointer info, the count, which find_points returns as a long that also carries its error codes (Ratpoints.findPointsWith returns the refusals apart), Booleans for three bits of args->flags, and the search intervals as a list, for the array args->domain and the number args->num_inter that the search writes back and the program reads after it; nothing else written back: neither the reversed coefficients and the degree (args->cof, args->degree), which nothing reads after the search; nor the other internal bits of the flags, RATPOINTS_CHECK_DENOM, RATPOINTS_USE_JACOBI and RATPOINTS_NO_REVERSE_AUTO, which the program does not read either, the bits of the input coming back as the caller set them (find_points.c:4606), which the program takes from its own options and settings (Ratpoints.Options, Ratpoints.SieveOptions.jacobi, Ratpoints.Cli.Output.verbose); nor args->sp3, which find_points_work zeroes on entry (line 4551) and leaves as the search leaves it, unlike sp2, which it restores (line 4561): the end of the third stage of the last block sifted (line 5163), that of the choice after the returns between the choice and the sieve, where sp3_used stays 0, and 0 after the returns before the choice and after the exits of the choice when the curve has no points modulo a prime (find_points.c:2614, find_points.c:2998), which come before line 3017 sets it; nor the private fields that sieving_info and adapt_primes write, adapt_at, run_words, run_denoms, sp3_max and check_rel, which nothing reads before sieving_info sets them again in the next search; natural numbers for the longs sp1_used, sp2_used and sp3_used.)

  • ratpoints.h:418-418: modelled by Ratpoints.searchPoints (deviation of Ratpoints.searchPoints: the range of the denominators, the search intervals and the flag sturm_empty as arguments, for the fields b_low, b_high, domain and num_inter of the arguments and the local flag of find_points_work_1; the flags of the denominators as Booleans, for the bits of args->flags; the divisors of the leading coefficient with their records as lists, for the arrays args->den_info and args->divisors of the arguments; the square test lcfsq of line 4906 made on the polynomial searched (Ratpoints.Setup.isSquare), where the C code computes it before the reversal check (line 4634) and clears it in case 2 (line 4770): the same value for an even degree, the only one that reads it; the array size normalized for the height bound where the estimate of the run reads it (Ratpoints.arraySizeAt); the test on point_at_infty of the 2-adic exit recomputed, as Ratpoints.Sieve.pointsAtInfinity decides it; the 2-adic exit returns the delivery with the message, nothing delivered, where find_points_work_1 returns the count 0; the delivery passed, for the pointer info, the local flag quit of find_points_work_1 and the count total, and the result with the bits of the flags written back, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), for the bits that find_points_work_1 sets in args->flags, the intervals that it leaves in args->domain and the fields sp1_used, sp2_used and sp3_used that the part after the choice sets (Ratpoints.chooseAndSearch); the report under RATPOINTS_VERBOSE printed through the print channel, the lines of the tests on the denominators together after the divisor set-up, which prints nothing; no output under DEBUG.)

  • ratpoints.h:421-424: modelled by Ratpoints.Options.normalize (deviation of Ratpoints.Options.normalize: the normalized options returned, for the fields of the arguments that the C code normalizes in place and restores in find_points_work (lines 4542-4545 and 4560-4563), which the caller does not see either; no clamp of the number of the search intervals, which a list cannot make negative; the bit RATPOINTS_NO_REVERSE_AUTO, which the C code sets in the flags and the reversal check tests with RATPOINTS_NO_REVERSE (line 4739), as the switch reverse cleared; integers for the longs.)

  • ratpoints.h:427-430: modelled by Ratpoints.findPointsVerbose (deviation of Ratpoints.findPointsVerbose: one function for find_points, find_points_work and the start of find_points_work_1, which the library calls in turn, and the rest of which is Ratpoints.findPointsWork. The refusals of the program, in its order and with its errors (Ratpoints.Refusal), returned apart from the outcome with the data of the callback, for the negative codes of the library (RATPOINTS_NON_SQUAREFREE and RATPOINTS_BAD_ARGS; RATPOINTS_WORK_LENGTH_TOO_SMALL and RATPOINTS_NO_MEMORY cannot arise), which share the long that find_points returns with the count, the caller keeping its data behind the pointer info: fewer than two coefficients are refused on the length of c, as the program refuses them, where the library refuses an empty list as a negative degree and one coefficient as the degree 0 (a longer list of degree 0 fails the test of the leading zeros first); and the height bound, which the program checks before it calls the library, comes before the test of the leading zeros, which the library makes first, so that 5 0 with H = 0 is error 4, as the program gives it. The degree with the leading zeros dropped is Ratpoints.BruteForce.degree c. A natural number H for the long height of the arguments (ratpoints.h:362), so that H = 0 stands for the heights below 1 that line 4658 refuses; a height that is not a long, 2 ^ 63 or more, is refused with error 4, as the program refuses it when it reads the height (Ratpoints.Cli.heightBound), where the library cannot be given one, its height being a long. The end of the type ratpoints_args (ratpoints.h:399-400) with its first fields, whose other fields are those of the options, the parameters, the result of the choice of the moduli and the outcome (Ratpoints.Options, Ratpoints.SieveOptions, Ratpoints.Params, Ratpoints.SievingInfo, Ratpoints.Outcome), of the divisor set-up (Ratpoints.Setup.setupUs1), or excluded. A list for the array of GMP integers and its scratch integers work, with nothing written back to the caller but the data of the callback, the count, three bits of the flags, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), which are 0 unless the search sets them, as find_points_work zeroes them on entry with the working field sp3, so that there is no state between calls and the reset of the flags clears nothing; the callback a function that returns what the call gives (Ratpoints.Answer), and its data a value, for the pointer info; the bit RATPOINTS_VERBOSE of the flags as the print channel print, a function that prints a text into the data of the callback, which holds the standard output of the caller, so that the text comes between the points as on the standard output of the C program, and which prints nothing when the bit is clear; the options of the output as fields of the options (Ratpoints.Options), copied into the flags of the check (Ratpoints.CheckFlags) with the flag of the reversal, for the bits of args->flags that the mask of line 4606 keeps; the points at infinity and the square test of the leading coefficient are decided where they are used (Ratpoints.Sieve.pointsAtInfinity, Ratpoints.Setup.reversal, Ratpoints.sturmRegion, Ratpoints.searchPoints); no failure for lack of memory, which the model cannot meet.)

  • ratpoints.h:436-437: modelled by Ratpoints.Answer, Ratpoints.findPointsVerbose (deviation of Ratpoints.Answer: the result of the call returned as a value, for the int that process returns, the int that it writes through the pointer quit, which the library clears before the search and tests after each call, so that it is clear at every call and the callback takes no argument for it, and the data that it may change through the pointer info; an integer for the int, with no bound, so that the count of a search has no range obligation (Ratpoints.Delivery); a Boolean for the int *quit.) (deviation of Ratpoints.findPointsVerbose: one function for find_points, find_points_work and the start of find_points_work_1, which the library calls in turn, and the rest of which is Ratpoints.findPointsWork. The refusals of the program, in its order and with its errors (Ratpoints.Refusal), returned apart from the outcome with the data of the callback, for the negative codes of the library (RATPOINTS_NON_SQUAREFREE and RATPOINTS_BAD_ARGS; RATPOINTS_WORK_LENGTH_TOO_SMALL and RATPOINTS_NO_MEMORY cannot arise), which share the long that find_points returns with the count, the caller keeping its data behind the pointer info: fewer than two coefficients are refused on the length of c, as the program refuses them, where the library refuses an empty list as a negative degree and one coefficient as the degree 0 (a longer list of degree 0 fails the test of the leading zeros first); and the height bound, which the program checks before it calls the library, comes before the test of the leading zeros, which the library makes first, so that 5 0 with H = 0 is error 4, as the program gives it. The degree with the leading zeros dropped is Ratpoints.BruteForce.degree c. A natural number H for the long height of the arguments (ratpoints.h:362), so that H = 0 stands for the heights below 1 that line 4658 refuses; a height that is not a long, 2 ^ 63 or more, is refused with error 4, as the program refuses it when it reads the height (Ratpoints.Cli.heightBound), where the library cannot be given one, its height being a long. The end of the type ratpoints_args (ratpoints.h:399-400) with its first fields, whose other fields are those of the options, the parameters, the result of the choice of the moduli and the outcome (Ratpoints.Options, Ratpoints.SieveOptions, Ratpoints.Params, Ratpoints.SievingInfo, Ratpoints.Outcome), of the divisor set-up (Ratpoints.Setup.setupUs1), or excluded. A list for the array of GMP integers and its scratch integers work, with nothing written back to the caller but the data of the callback, the count, three bits of the flags, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), which are 0 unless the search sets them, as find_points_work zeroes them on entry with the working field sp3, so that there is no state between calls and the reset of the flags clears nothing; the callback a function that returns what the call gives (Ratpoints.Answer), and its data a value, for the pointer info; the bit RATPOINTS_VERBOSE of the flags as the print channel print, a function that prints a text into the data of the callback, which holds the standard output of the caller, so that the text comes between the points as on the standard output of the C program, and which prints nothing when the bit is clear; the options of the output as fields of the options (Ratpoints.Options), copied into the flags of the check (Ratpoints.CheckFlags) with the flag of the reversal, for the bits of args->flags that the mask of line 4606 keeps; the points at infinity and the square test of the leading coefficient are decided where they are used (Ratpoints.Sieve.pointsAtInfinity, Ratpoints.Setup.reversal, Ratpoints.sturmRegion, Ratpoints.searchPoints); no failure for lack of memory, which the model cannot meet.)

  • ratpoints.h:439-439: excluded (interface): the prototype of find_points_init, which a caller of the library calls before find_points_work and whose definition (find_points.c:272-375) is excluded as interface: the model allocates nothing

  • ratpoints.h:441-442: modelled by Ratpoints.Answer, Ratpoints.findPointsVerbose (deviation of Ratpoints.Answer: the result of the call returned as a value, for the int that process returns, the int that it writes through the pointer quit, which the library clears before the search and tests after each call, so that it is clear at every call and the callback takes no argument for it, and the data that it may change through the pointer info; an integer for the int, with no bound, so that the count of a search has no range obligation (Ratpoints.Delivery); a Boolean for the int *quit.) (deviation of Ratpoints.findPointsVerbose: one function for find_points, find_points_work and the start of find_points_work_1, which the library calls in turn, and the rest of which is Ratpoints.findPointsWork. The refusals of the program, in its order and with its errors (Ratpoints.Refusal), returned apart from the outcome with the data of the callback, for the negative codes of the library (RATPOINTS_NON_SQUAREFREE and RATPOINTS_BAD_ARGS; RATPOINTS_WORK_LENGTH_TOO_SMALL and RATPOINTS_NO_MEMORY cannot arise), which share the long that find_points returns with the count, the caller keeping its data behind the pointer info: fewer than two coefficients are refused on the length of c, as the program refuses them, where the library refuses an empty list as a negative degree and one coefficient as the degree 0 (a longer list of degree 0 fails the test of the leading zeros first); and the height bound, which the program checks before it calls the library, comes before the test of the leading zeros, which the library makes first, so that 5 0 with H = 0 is error 4, as the program gives it. The degree with the leading zeros dropped is Ratpoints.BruteForce.degree c. A natural number H for the long height of the arguments (ratpoints.h:362), so that H = 0 stands for the heights below 1 that line 4658 refuses; a height that is not a long, 2 ^ 63 or more, is refused with error 4, as the program refuses it when it reads the height (Ratpoints.Cli.heightBound), where the library cannot be given one, its height being a long. The end of the type ratpoints_args (ratpoints.h:399-400) with its first fields, whose other fields are those of the options, the parameters, the result of the choice of the moduli and the outcome (Ratpoints.Options, Ratpoints.SieveOptions, Ratpoints.Params, Ratpoints.SievingInfo, Ratpoints.Outcome), of the divisor set-up (Ratpoints.Setup.setupUs1), or excluded. A list for the array of GMP integers and its scratch integers work, with nothing written back to the caller but the data of the callback, the count, three bits of the flags, the search intervals and the numbers of the moduli used (Ratpoints.Outcome), which are 0 unless the search sets them, as find_points_work zeroes them on entry with the working field sp3, so that there is no state between calls and the reset of the flags clears nothing; the callback a function that returns what the call gives (Ratpoints.Answer), and its data a value, for the pointer info; the bit RATPOINTS_VERBOSE of the flags as the print channel print, a function that prints a text into the data of the callback, which holds the standard output of the caller, so that the text comes between the points as on the standard output of the C program, and which prints nothing when the bit is clear; the options of the output as fields of the options (Ratpoints.Options), copied into the flags of the check (Ratpoints.CheckFlags) with the flag of the reversal, for the bits of args->flags that the mask of line 4606 keeps; the points at infinity and the square test of the leading coefficient are decided where they are used (Ratpoints.Sieve.pointsAtInfinity, Ratpoints.Setup.reversal, Ratpoints.sturmRegion, Ratpoints.searchPoints); no failure for lack of memory, which the model cannot meet.)

  • ratpoints.h:444-444: excluded (memory): the prototype of find_points_clear, which frees what find_points_init allocated and whose definition (find_points.c:377-416) is excluded as memory: the model allocates nothing

primes.h

gen_find_points_h.c

  • gen_find_points_h.c:30-31: excluded (other): the includes of the generator of find_points.h

  • gen_find_points_h.c:33-44: modelled by Ratpoints.Sieve.inversesMod (deviation of Ratpoints.Sieve.inversesMod: a function of p, computed when it is called, for the row of p in the table inverses that the build generates and that find_points.c includes; the trial stops before p and gives 0 when it finds nothing, where inv_mod_p would not stop, which never happens for a prime p and a residue other than 0.)

  • gen_find_points_h.c:46-67: excluded (other): the head of main of the generator of find_points.h and the guard it writes into the header against a header generated for other values of RBA_PACK, RATPOINTS_CHUNK and RATPOINTS_NUM_PRIMES; the model computes its tables from its constants

  • gen_find_points_h.c:69-88: modelled by Ratpoints.Sieve.squaresMod (deviation of Ratpoints.Sieve.squaresMod: a function of p, computed when it is called, for the row of p in the table squares that the build generates and that find_points.c includes.)

  • gen_find_points_h.c:90-100: modelled by Ratpoints.Sieve.inversesMod (deviation of Ratpoints.Sieve.inversesMod: a function of p, computed when it is called, for the row of p in the table inverses that the build generates and that find_points.c includes; the trial stops before p and gives 0 when it finds nothing, where inv_mod_p would not stop, which never happens for a prime p and a residue other than 0.)

  • gen_find_points_h.c:102-116: modelled by Ratpoints.Sieve.sieves0 (deviation of Ratpoints.Sieve.sieves0: a function of p, computed when it is called, for the row of p in the table sieves0 that the build generates and that find_points.c includes; its first (p + chunk - 1) rbaPack words, for the row of RBA_PACK (RATPOINTS_MAX_PRIME_EVEN + RATPOINTS_CHUNK - 1) words whose other words are 0 and never read.)

  • gen_find_points_h.c:118-120: modelled by Ratpoints.Sieve.forbiddenRow (deviation of Ratpoints.Sieve.forbiddenRow: one function for the two codes that make these words, the array work of the generator of find_points.h, for the primes of the table, and the words that sieving_info makes in the buffer forb_words for the forbidden divisors beyond the table (Ratpoints.Sieve.forbidden), with the positions p i for i < 64, for the positions m = 0, p, 2 p, … below 64 p there; a fresh array of p words, for the array work of RATPOINTS_MAX_PRIME words and for the space in the buffer; divisions and remainders for the shifts and masks by LONG_SHIFT and LONG_MASK.)

  • gen_find_points_h.c:122-134: modelled by Ratpoints.Sieve.sieves0 (deviation of Ratpoints.Sieve.sieves0: a function of p, computed when it is called, for the row of p in the table sieves0 that the build generates and that find_points.c includes; its first (p + chunk - 1) rbaPack words, for the row of RBA_PACK (RATPOINTS_MAX_PRIME_EVEN + RATPOINTS_CHUNK - 1) words whose other words are 0 and never read.)

  • gen_find_points_h.c:136-137: excluded (other): the end of main of the generator of find_points.h

gen_init_sieve_h.c

  • gen_init_sieve_h.c:29-46: excluded (other): the includes and the head of main of the generator of init_sieve.h, a global array work that it never uses, and the guard it writes into the header against a header generated for another RATPOINTS_NUM_PRIMES; the model makes the rows from its constants

  • gen_init_sieve_h.c:48-62: modelled by Ratpoints.Sieve.sieveInit (deviation of Ratpoints.Sieve.sieveInit: a function of p, for the entry of p in the table of the pointers to the functions that the build generates, one for each prime, and that init.c includes; the kind of the function, for the pointer to it.)

  • gen_init_sieve_h.c:64-65: excluded (other): the end of main of the generator of init_sieve.h

main.c

  • main.c:29-37: excluded (other): the includes of the program; the model has no headers

  • main.c:43-48: modelled by Ratpoints.Cli.banner (deviation of Ratpoints.Cli.banner: the text is that of ratpoints-lean.)

  • main.c:54-54: modelled by Ratpoints.Cli.coefficients (deviation of Ratpoints.Cli.coefficients: a list of Ints for the global array c of RATPOINTS_MAX_DEGREE + 1 GMP integers; the integers beyond these, which main.c reads into the variable fff only to check them, are read like the others.)

  • main.c:55-55: excluded (memory): the GMP integers tmp and tmp2 for intermediate results, which the program initializes and releases and the model does not need

  • main.c:57-64: modelled by Ratpoints.Cli.Output (deviation of Ratpoints.Cli.Output: a structure for the global variables; Option String for the strings and the format, none for the null pointer, and Lean strings for the C strings of the command line, which the Lean runtime decodes as UTF-8 (bytes that do not form UTF-8 are read as U+FFFD, one for each malformed sequence as the Lean runtime cuts them, where main.c copies the bytes); the bit RATPOINTS_VERBOSE of args->flags a field here, from which the program makes the print channel of the library (Ratpoints.Cli.run).)

  • main.c:66-66: modelled by Ratpoints.Cli.Intervals (deviation of Ratpoints.Cli.Intervals: a structure for the two locals of read_input and the two global arrays, whose entries are zero (the doubles) and 0 (the exact ends, as mpq_init sets them, main.c:205) at the start; pairs of doubles for the entries of the type ratpoints_interval; a natural number for the long num_inter.)

  • main.c:71-71: modelled by Ratpoints.Cli.ExactEnd (deviation of Ratpoints.Cli.ExactEnd: an Int for the int inf, and a rational number of core for the mpq_t q, 0 by default as mpq_init sets it.)

  • main.c:73-73: modelled by Ratpoints.Cli.Intervals (deviation of Ratpoints.Cli.Intervals: a structure for the two locals of read_input and the two global arrays, whose entries are zero (the doubles) and 0 (the exact ends, as mpq_init sets them, main.c:205) at the start; pairs of doubles for the entries of the type ratpoints_interval; a natural number for the long num_inter.)

  • main.c:77-88: modelled by Ratpoints.Cli.usage (deviation of Ratpoints.Cli.usage: the program is called ratpoints-lean, and the lines below the first are indented to match.)

  • main.c:94-103: excluded (other): the prototypes of the functions of the program; the model has no forward declarations

  • main.c:110-113: modelled by Ratpoints.Cli.Data (deviation of Ratpoints.Cli.Data: the text printed so far, for the standard output, to which process prints; an array for the pointer ends and a natural number for the long num_inter.)

  • main.c:116-120: modelled by Ratpoints.Cli.cmpEndX (deviation of Ratpoints.Cli.cmpEndX: the sign as -1, 0 or 1, for the value of mpq_cmp_si, of which main.c reads only the sign; integers for the longs.)

  • main.c:126-137: modelled by Ratpoints.Cli.inRegion (deviation of Ratpoints.Cli.inRegion: natural numbers for the long indices, an array for the pointer e.)

  • main.c:139-142: modelled by Ratpoints.Cli.process (deviation of Ratpoints.Cli.process: the data a value, for the pointer info, and returned with the weight and the flag, for the int *quit that the library passes, which is clear at every call; the text appended to that of the data, for the standard output, and no fflush.)

  • main.c:150-156: modelled by Ratpoints.Cli.process (deviation of Ratpoints.Cli.process: the data a value, for the pointer info, and returned with the weight and the flag, for the int *quit that the library passes, which is clear at every call; the text appended to that of the data, for the standard output, and no fflush.)

  • main.c:157-177: modelled by Ratpoints.Cli.formatPoint (deviation of Ratpoints.Cli.formatPoint: a recursion over the characters, for the loop over the C string; an Int for the GMP integer y and for the longs x and z, which print alike.)

  • main.c:178-182: modelled by Ratpoints.Cli.escape (deviation of Ratpoints.Cli.escape: one function for the two switches of process and print_string, which agree.)

  • main.c:183-186: modelled by Ratpoints.Cli.formatPoint (deviation of Ratpoints.Cli.formatPoint: a recursion over the characters, for the loop over the C string; an Int for the GMP integer y and for the longs x and z, which print alike.)

  • main.c:187-189: modelled by Ratpoints.Cli.process (deviation of Ratpoints.Cli.process: the data a value, for the pointer info, and returned with the weight and the flag, for the int *quit that the library passes, which is clear at every call; the text appended to that of the data, for the standard output, and no fflush.)

  • main.c:195-198: modelled by Ratpoints.Cli.run (deviation of Ratpoints.Cli.run: the text written once at the end (Ratpoints.Cli.main), where main.c prints as it goes; the bit RATPOINTS_VERBOSE of the flags, which the program sets under -v and leaves clear under -q (Ratpoints.Cli.input), as the print channel that it passes the library, and one that prints nothing otherwise.)

  • main.c:199-199: excluded (interface): the declaration of the arguments of the library, ratpoints_args args, whose fields the model passes as the arguments of the search with a callback

  • main.c:201-207: excluded (memory): the initialization of the GMP integers of the coefficients, of the rational ends of the intervals and of tmp and tmp2 at the start of main

  • main.c:210-214: modelled by Ratpoints.Cli.input (deviation of Ratpoints.Cli.input: read_input never returns a value other than 0, so the usage that main.c prints then (lines 212 and 213) has no counterpart; the largest denominator -1 of line 336, which line 380 replaces by the height bound, not set; the search intervals a list of the intervals read, for the pointer args->domain to the array domain and the number args->num_inter.)

  • main.c:215-220: modelled by Ratpoints.Cli.preamble

  • main.c:221-222: modelled by Ratpoints.Cli.run (deviation of Ratpoints.Cli.run: the text written once at the end (Ratpoints.Cli.main), where main.c prints as it goes; the bit RATPOINTS_VERBOSE of the flags, which the program sets under -v and leaves clear under -q (Ratpoints.Cli.input), as the print channel that it passes the library, and one that prints nothing otherwise.)

  • main.c:224-224: modelled by Ratpoints.Cli.preamble

  • main.c:232-234: excluded (memory): the allocation of the data that the program passes to the callback process, and error 10 when it fails

  • main.c:235-242: modelled by Ratpoints.Cli.Data.ofOutput (deviation of Ratpoints.Cli.Data.ofOutput: the format the one that Ratpoints.Cli.input settled, "" if none.)

  • main.c:246-247: modelled by Ratpoints.Cli.Data.ofOutput (deviation of Ratpoints.Cli.Data.ofOutput: the format the one that Ratpoints.Cli.input settled, "" if none.)

  • main.c:248-248: modelled by Ratpoints.Cli.run (deviation of Ratpoints.Cli.run: the text written once at the end (Ratpoints.Cli.main), where main.c prints as it goes; the bit RATPOINTS_VERBOSE of the flags, which the program sets under -v and leaves clear under -q (Ratpoints.Cli.input), as the print channel that it passes the library, and one that prints nothing otherwise.)

  • main.c:251-252: modelled by Ratpoints.Cli.run (deviation of Ratpoints.Cli.run: the text written once at the end (Ratpoints.Cli.main), where main.c prints as it goes; the bit RATPOINTS_VERBOSE of the flags, which the program sets under -v and leaves clear under -q (Ratpoints.Cli.input), as the print channel that it passes the library, and one that prints nothing otherwise.)

  • main.c:254-255: excluded (memory): the release of the data that the program passed to the callback process, at the end of its block

  • main.c:256-261: modelled by Ratpoints.Cli.Failure.ofRefusal (deviation of Ratpoints.Cli.Failure.ofRefusal: no error 10, since the model has no failure for lack of memory; the refusals of the coefficients and of the height (Ratpoints.Refusal.tooManyCoefficients, Ratpoints.Refusal.tooFewCoefficients, Ratpoints.Refusal.incorrectHeight) mapped to the errors 3, 5 and 4 with which read_input refuses those inputs before the library is called, where line 260 gives error 9 for the code RATPOINTS_BAD_ARGS with which the library refuses those it can be given (lines 4557-4558, 4633 and 4658 of find_points.c); no command line reaches them; no mpz_clear.)

  • main.c:265-265: modelled by Ratpoints.Cli.run (deviation of Ratpoints.Cli.run: the text written once at the end (Ratpoints.Cli.main), where main.c prints as it goes; the bit RATPOINTS_VERBOSE of the flags, which the program sets under -v and leaves clear under -q (Ratpoints.Cli.input), as the print channel that it passes the library, and one that prints nothing otherwise.)

  • main.c:267-267: modelled by Ratpoints.Cli.run (deviation of Ratpoints.Cli.run: the text written once at the end (Ratpoints.Cli.main), where main.c prints as it goes; the bit RATPOINTS_VERBOSE of the flags, which the program sets under -v and leaves clear under -q (Ratpoints.Cli.input), as the print channel that it passes the library, and one that prints nothing otherwise.)

  • main.c:268-276: modelled by Ratpoints.Cli.report

  • main.c:279-283: excluded (memory): the release of tmp and tmp2, of the GMP integers of the coefficients and of the rational ends of the intervals at the end of main

  • main.c:284-285: modelled by Ratpoints.Cli.run (deviation of Ratpoints.Cli.run: the text written once at the end (Ratpoints.Cli.main), where main.c prints as it goes; the bit RATPOINTS_VERBOSE of the flags, which the program sets under -v and leaves clear under -q (Ratpoints.Cli.input), as the print channel that it passes the library, and one that prints nothing otherwise.)

  • main.c:299-305: modelled by Ratpoints.Cli.heightEnd (deviation of Ratpoints.Cli.heightEnd: a natural number for the long height, at most 2 ^ 63 - 1.)

  • main.c:309-313: modelled by Ratpoints.Cli.cmpEnd (deviation of Ratpoints.Cli.cmpEnd: the sign as -1, 0 or 1, for the value of mpq_cmp, of which main.c reads only the sign.)

  • main.c:315-316: modelled by Ratpoints.Cli.input (deviation of Ratpoints.Cli.input: read_input never returns a value other than 0, so the usage that main.c prints then (lines 212 and 213) has no counterpart; the largest denominator -1 of line 336, which line 380 replaces by the height bound, not set; the search intervals a list of the intervals read, for the pointer args->domain to the array domain and the number args->num_inter.)

  • main.c:317-317: modelled by Ratpoints.Cli.Intervals (deviation of Ratpoints.Cli.Intervals: a structure for the two locals of read_input and the two global arrays, whose entries are zero (the doubles) and 0 (the exact ends, as mpq_init sets them, main.c:205) at the start; pairs of doubles for the entries of the type ratpoints_interval; a natural number for the long num_inter.)

  • main.c:318-318: modelled by Ratpoints.Cli.coefficients (deviation of Ratpoints.Cli.coefficients: a list of Ints for the global array c of RATPOINTS_MAX_DEGREE + 1 GMP integers; the integers beyond these, which main.c reads into the variable fff only to check them, are read like the others.)

  • main.c:319-319: modelled by Ratpoints.Cli.Intervals (deviation of Ratpoints.Cli.Intervals: a structure for the two locals of read_input and the two global arrays, whose entries are zero (the doubles) and 0 (the exact ends, as mpq_init sets them, main.c:205) at the start; pairs of doubles for the entries of the type ratpoints_interval; a natural number for the long num_inter.)

  • main.c:330-332: excluded (interface): the initialization of the fields of the arguments of the library that the model has no counterpart for: the pointer to the global array c of the coefficients, whose entries read_input fills later (line 368), and the degree and the height, which it sets later (lines 374 and 378) and the model passes as values

  • main.c:333-336: modelled by Ratpoints.Cli.input (deviation of Ratpoints.Cli.input: read_input never returns a value other than 0, so the usage that main.c prints then (lines 212 and 213) has no counterpart; the largest denominator -1 of line 336, which line 380 replaces by the height bound, not set; the search intervals a list of the intervals read, for the pointer args->domain to the array domain and the number args->num_inter.)

  • main.c:337-347: modelled by Ratpoints.SieveOptions (deviation of Ratpoints.SieveOptions: integers for the longs of the fields, doubles by their bits (Ratpoints.Double) for the doubles, as the program reads doubles (Ratpoints.Cli.scanDouble?), and a Boolean for the bit RATPOINTS_NO_JACOBI of the flags, which main.c clears with the others; the bit of the reversal is in Ratpoints.Options.)

  • main.c:348-348: modelled by Ratpoints.Options (deviation of Ratpoints.Options: a structure for the fields of ratpoints_args that hold these options: Booleans for the bits RATPOINTS_NO_CHECK, RATPOINTS_NO_Y and RATPOINTS_NO_REVERSE of the flags, noCheck and noY true when their bits are set, reverse true when RATPOINTS_NO_REVERSE is clear, so that all three defaults are those of the cleared flags (main.c, line 352); of the other bits of the flags, which main.c clears with these, the Jacobi switch is that of the options of the sieve (Ratpoints.SieveOptions.jacobi), and RATPOINTS_VERBOSE is the print channel of the search (Ratpoints.findPointsVerbose), which the program makes from Ratpoints.Cli.Output.verbose; an integer for args->sturm; a list of pairs of doubles (Ratpoints.Double) for the array domain of the type ratpoints_interval with the number num_inter of its intervals, the empty list for num_inter = 0, so that no number of intervals is negative and the room in the array for the intervals of the Sturm step is no concern of the caller; integers for the longs b_low and b_high; of the fields that share their lines in ratpoints.h, sp1, sp2, num_primes and max_forbidden are read by the options of the sieve (Ratpoints.SieveOptions), and sp3 is the end of the third stage of the choice (Ratpoints.Params.sp3), corrected during the run (Ratpoints.Sieve.Correction).)

  • main.c:349-350: modelled by Ratpoints.SieveOptions (deviation of Ratpoints.SieveOptions: integers for the longs of the fields, doubles by their bits (Ratpoints.Double) for the doubles, as the program reads doubles (Ratpoints.Cli.scanDouble?), and a Boolean for the bit RATPOINTS_NO_JACOBI of the flags, which main.c clears with the others; the bit of the reversal is in Ratpoints.Options.)

  • main.c:351-351: excluded (threads): the default of the number of threads, one: the calling thread sieves; the model has no threads

  • main.c:352-352: modelled by Ratpoints.Options, Ratpoints.SieveOptions (deviation of Ratpoints.Options: a structure for the fields of ratpoints_args that hold these options: Booleans for the bits RATPOINTS_NO_CHECK, RATPOINTS_NO_Y and RATPOINTS_NO_REVERSE of the flags, noCheck and noY true when their bits are set, reverse true when RATPOINTS_NO_REVERSE is clear, so that all three defaults are those of the cleared flags (main.c, line 352); of the other bits of the flags, which main.c clears with these, the Jacobi switch is that of the options of the sieve (Ratpoints.SieveOptions.jacobi), and RATPOINTS_VERBOSE is the print channel of the search (Ratpoints.findPointsVerbose), which the program makes from Ratpoints.Cli.Output.verbose; an integer for args->sturm; a list of pairs of doubles (Ratpoints.Double) for the array domain of the type ratpoints_interval with the number num_inter of its intervals, the empty list for num_inter = 0, so that no number of intervals is negative and the room in the array for the intervals of the Sturm step is no concern of the caller; integers for the longs b_low and b_high; of the fields that share their lines in ratpoints.h, sp1, sp2, num_primes and max_forbidden are read by the options of the sieve (Ratpoints.SieveOptions), and sp3 is the end of the third stage of the choice (Ratpoints.Params.sp3), corrected during the run (Ratpoints.Sieve.Correction).) (deviation of Ratpoints.SieveOptions: integers for the longs of the fields, doubles by their bits (Ratpoints.Double) for the doubles, as the program reads doubles (Ratpoints.Cli.scanDouble?), and a Boolean for the bit RATPOINTS_NO_JACOBI of the flags, which main.c clears with the others; the bit of the reversal is in Ratpoints.Options.)

  • main.c:357-357: excluded (memory): the initialization of the GMP integer fff, into which the program reads the coefficients beyond the bound to check them

  • main.c:362-375: modelled by Ratpoints.Cli.coefficients (deviation of Ratpoints.Cli.coefficients: a list of Ints for the global array c of RATPOINTS_MAX_DEGREE + 1 GMP integers; the integers beyond these, which main.c reads into the variable fff only to check them, are read like the others.)

  • main.c:378-379: modelled by Ratpoints.Cli.heightBound

  • main.c:380-380: modelled by Ratpoints.Cli.input (deviation of Ratpoints.Cli.input: read_input never returns a value other than 0, so the usage that main.c prints then (lines 212 and 213) has no counterpart; the largest denominator -1 of line 336, which line 380 replaces by the height bound, not set; the search intervals a list of the intervals read, for the pointer args->domain to the array domain and the number args->num_inter.)

  • main.c:383-390: modelled by Ratpoints.Cli.Output (deviation of Ratpoints.Cli.Output: a structure for the global variables; Option String for the strings and the format, none for the null pointer, and Lean strings for the C strings of the command line, which the Lean runtime decodes as UTF-8 (bytes that do not form UTF-8 are read as U+FFFD, one for each malformed sequence as the Lean runtime cuts them, where main.c copies the bytes); the bit RATPOINTS_VERBOSE of args->flags a field here, from which the program makes the print channel of the library (Ratpoints.Cli.run).)

  • main.c:393-400: modelled by Ratpoints.Cli.checkOptions (deviation of Ratpoints.Cli.checkOptions: the argument of -t, the number of threads, checked and then ignored, since the model sieves the blocks of the run in turn on one thread, which gives the output of every number of threads; the strings of -f, -fs, -fm and -fe kept as values, for the copies that main.c allocates, with error 10 when the allocation fails, which the model cannot meet.)

  • main.c:401-413: modelled by Ratpoints.Cli.Intervals.lower

  • main.c:414-416: modelled by Ratpoints.Cli.checkOptions (deviation of Ratpoints.Cli.checkOptions: the argument of -t, the number of threads, checked and then ignored, since the model sieves the blocks of the run in turn on one thread, which gives the output of every number of threads; the strings of -f, -fs, -fm and -fe kept as values, for the copies that main.c allocates, with error 10 when the allocation fails, which the model cannot meet.)

  • main.c:417-436: modelled by Ratpoints.Cli.Intervals.upper

  • main.c:437-532: modelled by Ratpoints.Cli.checkOptions (deviation of Ratpoints.Cli.checkOptions: the argument of -t, the number of threads, checked and then ignored, since the model sieves the blocks of the run in turn on one thread, which gives the output of every number of threads; the strings of -f, -fs, -fm and -fe kept as values, for the copies that main.c allocates, with error 10 when the allocation fails, which the model cannot meet.)

  • main.c:533-577: modelled by Ratpoints.Cli.checkOptions (deviation of Ratpoints.Cli.checkOptions: the argument of -t, the number of threads, checked and then ignored, since the model sieves the blocks of the run in turn on one thread, which gives the output of every number of threads; the strings of -f, -fs, -fm and -fe kept as values, for the copies that main.c allocates, with error 10 when the allocation fails, which the model cannot meet.)

  • main.c:578-593: modelled by Ratpoints.Cli.checkOptions (deviation of Ratpoints.Cli.checkOptions: the argument of -t, the number of threads, checked and then ignored, since the model sieves the blocks of the run in turn on one thread, which gives the output of every number of threads; the strings of -f, -fs, -fm and -fe kept as values, for the copies that main.c allocates, with error 10 when the allocation fails, which the model cannot meet.)

  • main.c:594-601: modelled by Ratpoints.Cli.checkOptions (deviation of Ratpoints.Cli.checkOptions: the argument of -t, the number of threads, checked and then ignored, since the model sieves the blocks of the run in turn on one thread, which gives the output of every number of threads; the strings of -f, -fs, -fm and -fe kept as values, for the copies that main.c allocates, with error 10 when the allocation fails, which the model cannot meet.)

  • main.c:602-637: modelled by Ratpoints.Cli.checkOptions (deviation of Ratpoints.Cli.checkOptions: the argument of -t, the number of threads, checked and then ignored, since the model sieves the blocks of the run in turn on one thread, which gives the output of every number of threads; the strings of -f, -fs, -fm and -fe kept as values, for the copies that main.c allocates, with error 10 when the allocation fails, which the model cannot meet.)

  • main.c:638-649: modelled by Ratpoints.Cli.checkOptions (deviation of Ratpoints.Cli.checkOptions: the argument of -t, the number of threads, checked and then ignored, since the model sieves the blocks of the run in turn on one thread, which gives the output of every number of threads; the strings of -f, -fs, -fm and -fe kept as values, for the copies that main.c allocates, with error 10 when the allocation fails, which the model cannot meet.)

  • main.c:650-668: modelled by Ratpoints.Cli.checkOptions (deviation of Ratpoints.Cli.checkOptions: the argument of -t, the number of threads, checked and then ignored, since the model sieves the blocks of the run in turn on one thread, which gives the output of every number of threads; the strings of -f, -fs, -fm and -fe kept as values, for the copies that main.c allocates, with error 10 when the allocation fails, which the model cannot meet.)

  • main.c:669-669: modelled by Ratpoints.Cli.Intervals.complete

  • main.c:673-678: modelled by Ratpoints.Cli.Intervals.complete

  • main.c:679-679: modelled by Ratpoints.Cli.input (deviation of Ratpoints.Cli.input: read_input never returns a value other than 0, so the usage that main.c prints then (lines 212 and 213) has no counterpart; the largest denominator -1 of line 336, which line 380 replaces by the height bound, not set; the search intervals a list of the intervals read, for the pointer args->domain to the array domain and the number args->num_inter.)

  • main.c:681-685: modelled by Ratpoints.Cli.defaultFormat

  • main.c:688-688: modelled by Ratpoints.Cli.input (deviation of Ratpoints.Cli.input: read_input never returns a value other than 0, so the usage that main.c prints then (lines 212 and 213) has no counterpart; the largest denominator -1 of line 336, which line 380 replaces by the height bound, not set; the search intervals a list of the intervals read, for the pointer args->domain to the array domain and the number args->num_inter.)

  • main.c:690-690: excluded (memory): the release of the GMP integer fff at the end of read_input

  • main.c:691-692: modelled by Ratpoints.Cli.input (deviation of Ratpoints.Cli.input: read_input never returns a value other than 0, so the usage that main.c prints then (lines 212 and 213) has no counterpart; the largest denominator -1 of line 336, which line 380 replaces by the height bound, not set; the search intervals a list of the intervals read, for the pointer args->domain to the array domain and the number args->num_inter.)

  • main.c:700-717: modelled by Ratpoints.Cli.intOfWord?

  • main.c:724-728: modelled by Ratpoints.Cli.onlyWord?

  • main.c:733-740: modelled by Ratpoints.Cli.longOfString? (deviation of Ratpoints.Cli.longOfString?: an Int for a long.)

  • main.c:746-752: modelled by Ratpoints.Cli.scanDouble? (deviation of Ratpoints.Cli.scanDouble?: the NaN refused by its syntax, which Ratpoints.Cli.isDoubleWord does not accept, for the test isnan of the double that strtod reads.)

  • main.c:761-763: modelled by Ratpoints.Cli.outward (deviation of Ratpoints.Cli.outward: the exact value of x (Ratpoints.Double.toRat) compared with v as rational numbers of core, for the GMP rational t, mpq_set_d and mpq_cmp; no mpq_init and mpq_clear.)

  • main.c:765-765: excluded (memory): the initialization of the GMP rational t of outward

  • main.c:766-773: modelled by Ratpoints.Cli.outward (deviation of Ratpoints.Cli.outward: the exact value of x (Ratpoints.Double.toRat) compared with v as rational numbers of core, for the GMP rational t, mpq_set_d and mpq_cmp; no mpq_init and mpq_clear.)

  • main.c:774-774: excluded (memory): the release of the GMP rational t of outward

  • main.c:775-776: modelled by Ratpoints.Cli.outward (deviation of Ratpoints.Cli.outward: the exact value of x (Ratpoints.Double.toRat) compared with v as rational numbers of core, for the GMP rational t, mpq_set_d and mpq_cmp; no mpq_init and mpq_clear.)

  • main.c:798-806: modelled by Ratpoints.Cli.scanEnd (deviation of Ratpoints.Cli.scanEnd: the end and the double returned, or none, for the exact_end and the double that scan_end writes through pointers with its return value, the end of an infinity with q = 0, which scan_end leaves as it is (it is not read); the parts of the word read by Ratpoints.Cli.floatParts from the word of Ratpoints.Cli.onlyWord?, which is s without its white space; rational numbers of core for the GMP integers and rationals m, p and e->q, without mpz_init, mpz_clear, malloc and free (and the error 10 when malloc fails, which the model cannot meet).)

  • main.c:808-819: modelled by Ratpoints.Cli.scanEnd (deviation of Ratpoints.Cli.scanEnd: the end and the double returned, or none, for the exact_end and the double that scan_end writes through pointers with its return value, the end of an infinity with q = 0, which scan_end leaves as it is (it is not read); the parts of the word read by Ratpoints.Cli.floatParts from the word of Ratpoints.Cli.onlyWord?, which is s without its white space; rational numbers of core for the GMP integers and rationals m, p and e->q, without mpz_init, mpz_clear, malloc and free (and the error 10 when malloc fails, which the model cannot meet).)

  • main.c:820-821: excluded (memory): the allocation of the string of the digits of scan_end, and error 10 when it fails, which the model cannot meet

  • main.c:822-834: modelled by Ratpoints.Cli.mantissaDigits (deviation of Ratpoints.Cli.mantissaDigits: a recursion over the characters, for the loop over the C string and the array digits, whose length is the number n of the digits.)

  • main.c:835-847: modelled by Ratpoints.Cli.scanEnd (deviation of Ratpoints.Cli.scanEnd: the end and the double returned, or none, for the exact_end and the double that scan_end writes through pointers with its return value, the end of an infinity with q = 0, which scan_end leaves as it is (it is not read); the parts of the word read by Ratpoints.Cli.floatParts from the word of Ratpoints.Cli.onlyWord?, which is s without its white space; rational numbers of core for the GMP integers and rationals m, p and e->q, without mpz_init, mpz_clear, malloc and free (and the error 10 when malloc fails, which the model cannot meet).)

  • main.c:848-848: excluded (memory): the initialization of the GMP integer m of scan_end

  • main.c:849-849: modelled by Ratpoints.Cli.scanEnd (deviation of Ratpoints.Cli.scanEnd: the end and the double returned, or none, for the exact_end and the double that scan_end writes through pointers with its return value, the end of an infinity with q = 0, which scan_end leaves as it is (it is not read); the parts of the word read by Ratpoints.Cli.floatParts from the word of Ratpoints.Cli.onlyWord?, which is s without its white space; rational numbers of core for the GMP integers and rationals m, p and e->q, without mpz_init, mpz_clear, malloc and free (and the error 10 when malloc fails, which the model cannot meet).)

  • main.c:850-850: excluded (memory): the release of the string of the digits of scan_end

  • main.c:851-865: modelled by Ratpoints.Cli.scanEnd (deviation of Ratpoints.Cli.scanEnd: the end and the double returned, or none, for the exact_end and the double that scan_end writes through pointers with its return value, the end of an infinity with q = 0, which scan_end leaves as it is (it is not read); the parts of the word read by Ratpoints.Cli.floatParts from the word of Ratpoints.Cli.onlyWord?, which is s without its white space; rational numbers of core for the GMP integers and rationals m, p and e->q, without mpz_init, mpz_clear, malloc and free (and the error 10 when malloc fails, which the model cannot meet).)

  • main.c:867-867: excluded (memory): the initialization of the GMP integer p of scan_end

  • main.c:868-873: modelled by Ratpoints.Cli.scanEnd (deviation of Ratpoints.Cli.scanEnd: the end and the double returned, or none, for the exact_end and the double that scan_end writes through pointers with its return value, the end of an infinity with q = 0, which scan_end leaves as it is (it is not read); the parts of the word read by Ratpoints.Cli.floatParts from the word of Ratpoints.Cli.onlyWord?, which is s without its white space; rational numbers of core for the GMP integers and rationals m, p and e->q, without mpz_init, mpz_clear, malloc and free (and the error 10 when malloc fails, which the model cannot meet).)

  • main.c:874-874: excluded (memory): the release of the GMP integer p of scan_end

  • main.c:875-876: modelled by Ratpoints.Cli.scanEnd (deviation of Ratpoints.Cli.scanEnd: the end and the double returned, or none, for the exact_end and the double that scan_end writes through pointers with its return value, the end of an infinity with q = 0, which scan_end leaves as it is (it is not read); the parts of the word read by Ratpoints.Cli.floatParts from the word of Ratpoints.Cli.onlyWord?, which is s without its white space; rational numbers of core for the GMP integers and rationals m, p and e->q, without mpz_init, mpz_clear, malloc and free (and the error 10 when malloc fails, which the model cannot meet).)

  • main.c:877-877: excluded (memory): the release of the GMP integer m of scan_end

  • main.c:878-880: modelled by Ratpoints.Cli.scanEnd (deviation of Ratpoints.Cli.scanEnd: the end and the double returned, or none, for the exact_end and the double that scan_end writes through pointers with its return value, the end of an infinity with q = 0, which scan_end leaves as it is (it is not read); the parts of the word read by Ratpoints.Cli.floatParts from the word of Ratpoints.Cli.onlyWord?, which is s without its white space; rational numbers of core for the GMP integers and rationals m, p and e->q, without mpz_init, mpz_clear, malloc and free (and the error 10 when malloc fails, which the model cannot meet).)

  • main.c:891-905: modelled by Ratpoints.Cli.joinIntervals (deviation of Ratpoints.Cli.joinIntervals: a list for the array args->domain and the number args->num_inter of its intervals, written back in place by join_intervals, and natural numbers for the long indices.)

  • main.c:913-949: modelled by Ratpoints.Cli.printPoly (deviation of Ratpoints.Cli.printPoly: a fold over the coefficients, for the loop; no fflush.)

  • main.c:952-960: modelled by Ratpoints.Cli.printString (deviation of Ratpoints.Cli.printString: a recursion over the characters, for the loop over the C string.)

  • main.c:961-965: modelled by Ratpoints.Cli.escape (deviation of Ratpoints.Cli.escape: one function for the two switches of process and print_string, which agree.)

  • main.c:966-968: modelled by Ratpoints.Cli.printString (deviation of Ratpoints.Cli.printString: a recursion over the characters, for the loop over the C string.)

  • main.c:972-976: modelled by Ratpoints.Cli.Message.text (deviation of Ratpoints.Cli.Message.text: the banner of ratpoints-lean (Ratpoints.Cli.banner); a constructor for each message that ratpoints-lean prints, with its data, for the number n and the arguments of the library: message 1, which the program prints when read_input fails, which it never does, is left out; the loops over the intervals of messages 3 and 8 as Ratpoints.Cli.showIntervals, the conversion %lf of message 8 being %f; the difference sp3_used - sp2_used of message 4 an integer, for the long; no fflush.)

  • main.c:977-978: excluded (other): the text of message 1, the banner and the usage, which main prints only when read_input returns a value other than 0, which it never does: its only return is at line 691, and every other failure exits through error

  • main.c:979-1033: modelled by Ratpoints.Cli.Message.text (deviation of Ratpoints.Cli.Message.text: the banner of ratpoints-lean (Ratpoints.Cli.banner); a constructor for each message that ratpoints-lean prints, with its data, for the number n and the arguments of the library: message 1, which the program prints when read_input fails, which it never does, is left out; the loops over the intervals of messages 3 and 8 as Ratpoints.Cli.showIntervals, the conversion %lf of message 8 being %f; the difference sp3_used - sp2_used of message 4 an integer, for the long; no fflush.)

  • main.c:1036-1048: modelled by Ratpoints.Cli.Failure.message (deviation of Ratpoints.Cli.Failure.message: the banner and the usage are those of ratpoints-lean.)

  • main.c:1049-1049: excluded (memory): the message of error 10, for lack of memory, which the model cannot meet

  • main.c:1050-1053: modelled by Ratpoints.Cli.Failure.message (deviation of Ratpoints.Cli.Failure.message: the banner and the usage are those of ratpoints-lean.)

  • main.c:1054-1056: modelled by Ratpoints.Cli.Failure.status