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 - F2xqE.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.18.1 lcov report (development 30702-bddb8d6928) Lines: 426 454 93.8 %
Date: 2026-02-23 02:23:56 Functions: 56 59 94.9 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
F2x_Teichmuller 5741
F2x_is_pcyc 5940
F2xqE_Miller 7788
F2xqE_Miller_add 7788
F2xqE_Miller_dbl 14454
F2xqE_Miller_line 14484
F2xqE_add 298008
F2xqE_add_slope 298038
F2xqE_changepoint 304811
F2xqE_changepointinv 166656
F2xqE_chord_update 7788
F2xqE_dbl 885300
F2xqE_dbl_slope 900972
F2xqE_log 36
F2xqE_mul 157776
F2xqE_neg 72
F2xqE_neg_i 0
F2xqE_order 240
F2xqE_sub 0
F2xqE_tangent_update 14454
F2xqE_tatepairing 24
F2xqE_vert 30000
F2xqE_weilpairing 4590
F2xq_ellcard 38562
F2xq_ellgens 3204
F2xq_ellgroup 3264
F2xq_elltrace_Harley 6144
F2xq_elltracej 32274
F2xq_elltwist 3012
RgE_to_F2xqE 166656
Z2XQ_frob 11769
Z2XQ_invnorm 5736
Z2XQ_invnorm_pcyc 204
Z2x_rshift 11257
Z2xq_frob 5745
_F2xqE_add 298008
_F2xqE_dbl 885300
_F2xqE_mul 181632
_F2xqE_pairorder 330
_F2xqE_rand 11514
_can_invd 11546
_can_invls 17067
_can_iter 11546
_can_lin 9
_can_lins 5512
_frob_invls 17514
_frob_lin 9
_frob_lins 5745
_lift_invd 11760
_lift_iter 11760
gen_Z2X_Dixon 23342
gen_Z2x_Dixon 45838
get_F2xqE_group 0
get_r 8634
get_v 20460
is_2_torsion 16518
nonzerotrace_F2xq 3012
random_F2xqE 155273
solve_AGM_eqn 5940

Generated by: LCOV version 1.16