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) Coverage Total Hit
Test: PARI/GP v2.18.1 lcov report (development 31042-0fbe168e69) Lines: 94.1 % 2817 2651
Test Date: 2026-07-23 17:04:59 Functions: 96.3 % 163 157
Legend: Lines:     hit not hit

Function Name Sort by function name Hit count Sort by function hit count
phi2_atkin11_ZV 0
phi2_atkin13_ZV 0
phi2_atkin17_ZV 0
phi2_atkin19_ZV 0
phi_atkin11_j 0
phi_atkin19_j 0
phi2_atkin23_ZV 7
phi2_atkin3_ZV 7
phi2_atkin5_ZV 7
phi2_atkin29_ZV 14
phi2_atkin31_ZV 14
phi2_atkin7_ZV 14
phi2_w3w13_ZV 14
phi3_f3_ZV 14
phi2_w3w3e2_ZV 21
db_add_levels 24
phi2_w3w5_ZV 35
phi5_w3w7_ZV 42
phi3_w2w13_ZV 49
FpV_deriv 56
phi5_w2w3_ZV 56
phi5_w3w3_ZV 63
weber_exponent 63
phi2_w5w7_ZV 70
phi7_w2w5_ZV 91
phi2_g2_ZV 98
Fp_polmodular_evalx 126
modinv_parent 140
modinv_parent_power 140
polmodular0_powerup_ZM 140
modinv_f3_from_j 168
phi5_f_ZV 175
phi3_w2w7_ZV 182
phi_w3w13_j 210
phi_atkin13_j 224
phi_atkin7_j 273
phi_atkin5_j 287
double_eta_raw_to_Fp 357
phi_atkin23_j 504
polmodular 651
phi_atkin17_j 672
modinv_ramified 700
twelth_root 893
phi_atkin3_j 931
modinv_is_Weber 1029
Fp_modinv_to_j 1043
phi_w2w3_j 1060
phi_w3w5_j 1161
modinv_j_from_f 1830
phi5_ZV 1908
phi3_ZV 1931
phi_atkin29_j 2039
phi_atkin31_j 2222
phi_w3w7_j 2412
Flv_deriv_pre_inplace 2464
phi_w2w5_j 2500
eval_modpoly_modp 2674
phi_w2w13_j 2755
make_pcp_floor 3016
make_pcp_surface 3016
discriminant_with_classno_at_least 3136
modpoly_height_bound 3136
select_L0 3136
calc_primes_for_discriminants 3138
modpoly_pickD 3138
scanD0 3138
modinv_f_from_j 3147
phi_w5w7_j 3342
phi_w3w3_j 3883
fourth_root 3926
eighth_root 4720
polmodular_db_add_levels 5049
sixth_root 5340
double_eta_initial_js 6102
modinv_double_eta_from_j 6102
phi_w2w7_j 6166
modinv_j_from_2double_eta 6398
inflate_polys 9646
normalise_coeffs 9646
safe_abs_sqrt 9840
modpoly_pickD_primes 13416
modinv_pfilter 16554
modinv_double_eta_from_2j 17800
modfn_unambiguous_root 17878
polmodular_ZXX 19217
polmodular_ZM 19315
phi2_ZV 20064
carray_reverse_inplace 20791
polmodular_db_init 21548
sympol_to_ZM 24876
internal_db 25016
polmodular_small_ZM 25016
polmodular_db_add_level 26253
polmodular0_ZM 28019
modinv_max_internal_level 28138
double_eta_Fl 30004
double_eta_raw 30641
double_eta_root 30864
Flx_double_eta_jpoly 31102
double_eta_power 31102
double_eta_raw_to_Fl 36402
Flv_powu_inplace_pre 38570
modinv_level 40954
enum_volcano_floor 42964
enum_volcano_surface 42964
get_Lsqr_cycle 42964
oneroot_of_classpoly 42964
polmodular_split_p_Flm 42964
polmodular_worker 42964
root_matrix 42964
orientation_ambiguity 43897
roots_to_coeffs 45199
interpolate_coeffs 45528
modinv_sparse_factor 49098
verify_L_sylow_is_cyclic 51785
Flx_double_eta_xpoly 53906
double_eta_exponent 62323
modfn_preimage 73724
qform_primeform2 85554
compute_L_isogenous_curve 92030
find_noniso_L_isogenous_curve 92030
select_curve_with_L_tors_point 92030
Fl_mul5 100851
Fl_mul7 100851
Fle_quotient_from_kernel_generator 100851
qfb_nform 144557
find_L_tors_point 147554
mkqfis 150920
modfn_root 206597
primeform_discrete_log 217195
qfb_distinct_prods 231183
modinv_is_double_eta 256642
Flv_lastnonzero 330574
polmodular_db_for_inv 384772
polmodular_db_getp 557228
modinv_odd_conductor 567766
modinv_good_atkin 633269
update_Lsqr_cycle 684593
append_neighbours 727557
vecsmall_pick 727557
check_generators 829790
Fl_mul6 887327
Fl_mul8 988178
primeform_exp_order 1133652
qfb_is_two_torsion 1697990
disc_best_modinv 1907423
Fl_mul4 1976356
prime_to_conductor 3464791
red_primeform 3464791
modinv_double_eta_good_disc 5468111
Flm_Fl_phi3_evalx 5502153
Fl_addmul4 5575109
Flm_Fl_phi5_evalx 5575109
modinv_degree 7402275
modinv_good_prime 11332379
_qsort_cmp 15030118
modinv_good_disc 15123964
Fl_addmul3 16506459
modinv_height_factor 22899771
Fl_addmul5 27875545
Flm_Fl_phi2_evalx 34356762
Flm_Fl_polmodular_evalx 52494767
Fl_addmul2 74215677

Generated by: LCOV version 2.0-1