Code coverage tests

This page documents the degree to which the PARI/GP source code is tested by our public test suite, distributed with the source distribution in directory src/test/. This is measured by the gcov utility; we then process gcov output using the lcov frond-end.

We test a few variants depending on Configure flags on the pari.math.u-bordeaux.fr machine (x86_64 architecture), and agregate them in the final report:

The target is to exceed 90% coverage for all mathematical modules (given that branches depending on DEBUGLEVEL or DEBUGMEM are not covered). This script is run to produce the results below.

LCOV - code coverage report
Current view: top level - basemath - polclass.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.18.0 lcov report (development 29806-4d001396c7) Lines: 825 846 97.5 %
Date: 2024-12-22 09:08:28 Functions: 72 73 98.6 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
Flv_powsum_pre 15978
adjust_orientation 6159
adjust_signs 10843
best_torsion_constraint 139937
check_modinv 2793
classgp_make_pcp 4931
classgp_pcp_check_generators 4419
distinct_inverses 1001
evec_clear 5112
evec_compose 518
evec_copy 12283
evec_equal 259
evec_inverse 203
evec_inverse_o 735
evec_n_to_m 4398
evec_order 5599
evec_orders 4398
evec_reduce 21624
evec_ri 13522
evec_ri_mutate 5796
evec_to_index 10797
factor_uv 186357
famatsmall_divexact 2565
find_j_inv_with_given_trace 140108
find_jinv 139790
hasse_bounds 140052
hclassno_wrapper 191288
height_margin 4931
index_to_evec 1386
logfac 0
modinv_has_sign_ambiguity 4931
modinv_inverted_involution 2229
modinv_negated_involution 2229
modinv_units 3472
next_generator 5725
next_prime_evec 1239
norm_eqn_set 177367
oneroot_of_classpoly 140332
orient_pcp 280
oriented_n_action 6159
pcp_get_D 148436
pcp_get_D0 191288
pcp_get_L 9429
pcp_get_L0 9429
pcp_get_fau 4931
pcp_get_h 191288
pcp_get_inv 148722
pcp_get_k 11370
pcp_get_m 6712
pcp_get_n 6439
pcp_get_o 6439
pcp_get_orient_p 6712
pcp_get_orient_q 6712
pcp_get_orient_reps 6439
pcp_get_r 6439
pcp_get_u 138597
polclass 2170
polclass0 6422
polclass_psum 553
polclass_roots_modp 138577
polclass_small_disc 1491
polclass_worker 138633
primecmp 1226903
quadnegclassnou 4931
random_FleV 857660
select_classpoly_prime_pool 4931
select_classpoly_primes 4931
test_curve_order 166450
torsion_constraint 418760
upper_bound_on_classpoly_coeffs 4931
vecsmall_isin_skip 7604
verify_2path 672
verify_edge 3966

Generated by: LCOV version 1.16