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 - FpE.c (source / functions) Coverage Total Hit
Test: PARI/GP v2.18.1 lcov report (development 31041-bd73e9fcdd) Lines: 89.4 % 1277 1142
Test Date: 2026-07-22 22:45:42 Functions: 92.0 % 137 126
Legend: Lines:     hit not hit

Function Name Sort by function name Hit count Sort by function hit count
FpE_neg_i 0
FpE_sub 0
FpJ_neg 0
FpXQE_log 0
FpXQE_mul 0
FpXQE_neg_i 0
FpXQE_sub 0
FpXQV_ell_to_a4a6 0
FpXQV_ellcard 0
Fp_ellpoint 0
Fp_elltwist 0
FpE_Miller_add 4
FpE_chord_update 4
FpXQE_tatepairing 7
FpXQ_ellcard_supersingular 7
FpXQ_is4power 7
FpXQ_ellgens 8
FpXQ_ffellcard 8
FpXQE_order 14
FpXQ_ellgroup 15
get_FpXQE_group 16
Fq_ellcard_supersingular 21
_FpXQE_pairorder 21
FpXQE_weilpairing 28
FpXQE_changepointinv 42
RgE_to_FpXQE 42
FpE_Miller 44
FpE_Miller_line 45
FpE_log 49
FpXQE_Miller 63
Fp_ellcard_Shanks 79
get_table_size 79
FpE_Miller_dbl 92
FpE_tangent_update 92
Fp_ellj 98
ap_j8000 133
FpE_vert 140
_FpXQE_rand 147
ap_j287496 147
FpE_tatepairing 203
FpXQV_ellcharpoly 231
FpXQV_initsmall5 231
random_nonsquare_Fp 420
Fp_path_extends_to_floor 455
FpXQE_Miller_add 567
FpXQE_chord_update 567
Fp_ellgens 574
FpE_order 737
FpXQ_elltwist 840
random_nonsquare_FpXQ 840
get_FpE_group 903
FpXQE_changepoint 942
Fq_elljissupersingular 1043
FpE_to_mod 1045
RgE_is_FpE 1080
random_FpXQE 1081
Fp_ellj_to_a4a6 1092
ellsupersingularj_easy_FpXQ 1183
find_inert_disc 1183
ellsupersingularj_FpXQ 1204
FpX_quad_root 1244
FpE_mul 1308
ap_cm 1456
FpXQ_ellcardj 1687
FpE_changepoint 1718
FpXQ_ellj 1718
ell_to_a4a6_FpXQ 1726
FpE_changepointinv 2725
RgE_to_FpE 2725
Fp_jissupersingular 2788
Fp_elljissupersingular 3780
FpXQE_Miller_dbl 4158
FpXQE_tangent_update 4158
FpXQE_Miller_line 4655
FpXQE_vert 4788
Fq_path_extends_to_floor 4881
FpJ_mul 5725
_FpJ_mul 5725
FpXQ_ellcard 8508
FpXQ_ellcard_i 8508
affii2 9440
Fl_ellpoint 12379
jissupersingular 14007
Fp_ffellcard 14637
u2_is_CMj 14806
elltrace_extension 15400
_fix 19196
FpXQ_is_quad 33523
ellinf_FpJ 44635
Fp_ellj_nodiv 50566
Fp_ellj_get_CM 54118
FpXQE_dbl 68504
_FpXQE_dbl 68504
FqX_quad_root 71367
FpXQE_dbl_slope 72606
_FpE_pairorder 72723
FpE_weilpairing 72968
FpXQE_neg 73329
_FpXQE_mul 80841
Fp_ellgroup 120715
ap_j0 133968
FpXQ_elljissupersingular 165508
_FpE_rand 186277
random_FpE 188664
FpJ_to_FpE 198412
FpE_to_FpJ 198944
FpXQE_add 221956
_FpXQE_add 221956
FpXQE_add_slope 222516
RgE_is_FpXQE 249340
FpE_dbl 258747
_FpE_dbl 258747
FpE_dbl_slope 259341
FpE_add_ip 305694
FpE_neg 362490
Fle_dbl_inplace 380971
Fl_ellcard_Shanks 430185
closest_lift 430320
uclosest_lift 442554
ec_ap_cm 495679
is_CMj 669321
Fl_elltrace_naive 790538
Fl_elltrace 816464
_FpE_mul 890998
_FpE_add 897344
FpE_add 916615
FpE_add_slope 916619
_FpJ_add 1127269
FpJ_add 1127680
Fl_elltrace_CM 1360464
Fp_ellcard_CM 4889984
Fp_ellcard 5195875
ap_j1728 5199966
_FpJ_dbl 6254216
FpJ_dbl 6271485
Fle_add_inplace 8095420
compare_multiples 17768564

Generated by: LCOV version 2.0-1