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 - polmodular.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.18.1 lcov report (development 30256-57c6c2b57f) Lines: 2314 2385 97.0 %
Date: 2025-05-09 09:19:30 Functions: 144 144 100.0 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
phi2_w3w13_ZV 14
phi2_atkin3_ZV 21
phi2_w3w3e2_ZV 21
phi3_f3_ZV 21
phi2_w3w5_ZV 35
phi3_w2w13_ZV 35
phi5_w3w7_ZV 42
db_add_levels 45
FpV_deriv 56
phi2_w5w7_ZV 56
phi5_w2w3_ZV 56
phi5_w3w3_ZV 63
weber_exponent 63
phi7_w2w5_ZV 98
phi2_g2_ZV 119
Fp_polmodular_evalx 126
modinv_parent 147
modinv_parent_power 147
polmodular0_powerup_ZM 147
phi5_f_ZV 182
phi3_w2w7_ZV 196
phi_w3w13_j 210
double_eta_raw_to_Fp 231
modinv_f3_from_j 358
modinv_ramified 581
polmodular 630
twelth_root 899
modinv_is_Weber 945
Fp_modinv_to_j 1021
phi_w2w3_j 1060
phi_w3w5_j 1147
modinv_j_from_f 1830
phi5_ZV 1859
phi3_ZV 1889
phi_w2w13_j 2340
phi_w3w7_j 2412
Flv_deriv_pre_inplace 2464
eval_modpoly_modp 2674
make_pcp_floor 2880
make_pcp_surface 2880
phi_w5w7_j 2896
discriminant_with_classno_at_least 3008
modpoly_height_bound 3008
select_L0 3008
calc_primes_for_discriminants 3010
modpoly_pickD 3010
scanD0 3010
phi_w2w5_j 3039
modinv_f_from_j 3070
phi_atkin3_j 3186
fourth_root 4073
phi_w3w3_j 4112
polmodular_db_add_levels 4913
eighth_root 5053
double_eta_initial_js 5963
modinv_double_eta_from_j 5963
sixth_root 6153
modinv_j_from_2double_eta 6511
phi_w2w7_j 6651
safe_abs_sqrt 10201
inflate_polys 10583
normalise_coeffs 10583
modpoly_pickD_primes 11928
modinv_double_eta_from_2j 14609
modfn_unambiguous_root 14688
modinv_pfilter 14938
carray_reverse_inplace 18667
polmodular_ZXX 19161
polmodular_ZM 19245
phi2_ZV 19994
polmodular_db_init 21471
sympol_to_ZM 24701
internal_db 24848
polmodular_small_ZM 24848
polmodular_db_add_level 25057
double_eta_Fl 26535
double_eta_raw 27053
double_eta_root 27495
polmodular0_ZM 27716
modinv_max_internal_level 27835
Flx_double_eta_jpoly 30911
double_eta_power 30911
double_eta_raw_to_Fl 33047
orientation_ambiguity 34756
polmodular_split_p_Flm 38679
oneroot_of_classpoly 38681
polmodular_worker 38684
enum_volcano_floor 38688
enum_volcano_surface 38689
get_Lsqr_cycle 38689
root_matrix 38690
modinv_level 40281
roots_to_coeffs 41098
Flv_powu_inplace_pre 41381
interpolate_coeffs 41442
modinv_sparse_factor 44550
Flx_double_eta_xpoly 47105
verify_L_sylow_is_cyclic 47234
double_eta_exponent 58637
modfn_preimage 65451
qform_primeform2 77321
compute_L_isogenous_curve 83336
select_curve_with_L_tors_point 83337
find_noniso_L_isogenous_curve 83340
Fl_mul7 91879
Fl_mul5 91883
Fle_quotient_from_kernel_generator 91888
find_L_tors_point 134373
mkqfis 134944
qfb_nform 135821
modfn_root 192129
primeform_discrete_log 198033
qfb_distinct_prods 229559
modinv_is_double_eta 236998
Flv_lastnonzero 345809
polmodular_db_for_inv 356906
polmodular_db_getp 519528
modinv_odd_conductor 527272
update_Lsqr_cycle 534538
append_neighbours 573231
vecsmall_pick 573233
Fl_mul6 750216
check_generators 770009
Fl_mul8 842063
primeform_exp_order 1060162
Fl_mul4 1684050
qfb_is_two_torsion 1692040
disc_best_modinv 1907423
Flm_Fl_phi3_evalx 3242686
prime_to_conductor 3249610
red_primeform 3249610
Flm_Fl_phi5_evalx 5012513
Fl_addmul4 5021644
modinv_double_eta_good_disc 5313964
modinv_degree 7244534
Fl_addmul3 9721088
modinv_good_prime 10750455
_qsort_cmp 14433820
modinv_good_disc 14990300
modinv_height_factor 21310598
Fl_addmul5 24980647
Flm_Fl_phi2_evalx 26399431
Flm_Fl_polmodular_evalx 41851769
Fl_addmul2 55874937

Generated by: LCOV version 1.16