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 - F2x.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.18.1 lcov report (development 29877-9124a6ce27) Lines: 1543 1845 83.6 %
Date: 2025-01-18 09:08:44 Functions: 191 214 89.3 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
F2xC_to_FlxC 0
F2xXV_to_F2xM 0
F2xX_F2x_add 0
F2xX_to_F2xC 0
F2xXn_red 0
F2xY_F2xq_evalx 0
F2x_deflate 0
F2x_recip 0
F2x_recip_raw 0
F2xqXM_F2xqX_mul2 0
F2xqXM_mul2 0
F2xqX_F2xqXM_qmul 0
F2xqX_addmulmul 0
F2xqX_extgcd_halfgcd 0
F2xqX_halfgcd 0
F2xqX_halfres 0
F2xqX_halfres_split 0
F2xqX_halfres_update 0
F2xqX_invBarrett_basecase 0
F2xqX_powu 0
_F2xqX_sqr 0
matJ2_F2xXM 0
matid2_F2xXM 0
F2xqV_roots_to_deg1 7
F2xqV_roots_to_pol 7
F2xqXQ_inv 7
F2xqXQ_invsafe 7
F2xqXQ_pow 7
F2xqXV_prod 7
F2xqX_halfgcd_all 7
F2xqX_halfgcd_all_i 7
F2xqX_halfres_basecase 7
F2xqX_halfres_i 7
F2xq_conjvec 7
_F2xqXQ_zero 7
F2xqX_disc 14
F2xqX_extgcd 14
F2xqX_extgcd_basecase 14
F2xq_log_Coppersmith 14
F2xq_log_index 14
F2xq_pow_init 14
check_kernel 14
smallirred_F2x 14
F2xqX_resultant 21
F2xqX_resultant_basecase 21
F2xn_div1 28
F2xn_inv 28
F2xq_log_Coppersmith_rec 28
F2x_recip1 42
F2xn_div 42
F2xn_inv1 42
F2xn_inv_basecase1 42
F2xqX_invBarrett 45
F2xqX_invBarrett_Newton 45
F2xn_mul 46
F2xq_powu 49
F2xX_to_FlxX 56
F2xqXQV_red 63
monomial_F2x 63
F2xq_log_find_rel 64
F2xq_log_from_rel 81
F2xn_red 83
F2xq_log_Coppersmith_d 110
F2x_mulspec_mulii 132
int_to_F2x 132
gener_F2xq 161
F2x_degreespec 264
F2x_to_int 264
_F2xq_inv 364
F2x_to_F2xX 378
F2xq_order 392
FlxXC_to_F2xXC 406
polx_F2xX 441
_F2xq_s 623
_F2xq_neg 756
F2x_halfgcd 837
F2x_halfgcd_i 837
_F2xq_equal0 861
_F2xqX_mul 882
FlxX_to_F2xX 938
F2xXC_to_ZXXC 1092
F2xX_addspec 1186
F2xqX_divrem_Barrett 1186
F2xqX_divrem_Barrettspec 1189
F2x_shiftneg 1269
RgX_to_F2x 1400
F2xX_to_ZXX 1421
get_F2xq_field 1666
F2xq_log_Coppersmith_worker 2046
F2xX_recipspec 2423
F2xqXQ_auttrace 2730
random_F2xqX 2849
F2xqX_mulspec 3019
F2xX_lgrenormalizespec 3337
F2xC_to_ZXC 3843
F2xqXQ_auttrace_sqr 4921
ZXX_to_F2xX 4942
F2xq_pow_table 5246
F2xX_to_Kronecker_spec 6038
F2xqX_F2xq_mul 6993
F2xq_sqrtn 7161
F2xqXQ_auttrace_mul 7224
F2xqXQ_powers 7756
_F2xq_rand 9457
F2x_eval 13370
F2xqX_F2xqXQV_eval 14497
F2xq_autpow_mul 14678
F2x_factorel 15024
_F2xq_rmul 15799
FlxC_to_F2xC 16520
F2x_is_x 19251
F2xq_autpow 19258
mkF2 27021
F2xq_autpow_sqr 29322
F2xV_to_FlxV_inplace 30386
F2xqX_divrem 33229
F2xqXQ_autpow_mul 33243
_F2xqXQ_sqr 33292
F2x_valrem 35385
F2x_issquare 35737
F2xq_sqrt 38634
F2x_F2xq_eval 44727
F2x_addshift 46908
F2x_even_odd 61176
F2xq_sqrt_fast 61176
F2xqXQ_autpow 70434
F2x_addspec 73287
F2xX_deriv 80465
F2xqXQ_autpow_sqr 88809
F2xqXQ_sqr 104321
F2xqX_sqr 105399
_F2xqXQ_mul 114184
F2xqXQ_mul 114240
F2xqX_F2xqXQ_eval 122052
F2x_to_Flx 131464
F2xY_F2xqV_evalx 136500
rel_Coppersmith 147446
Flx_to_F2x 150591
F2xqX_mul 155354
Kronecker_to_F2xqX 158373
F2xqX_gcd_basecase 169372
F2xqX_gcd 169757
F2x_pow2n 182372
F2x_1_add 189890
F2xqX_F2xq_mul_to_monic 205961
F2xqX_normalize 205975
F2xY_degreex 206458
F2xq_Artin_Schreier 211596
Z_to_F2x 213009
F2x_get_red 218757
F2xqX_get_red 220108
F2xV_to_F2m 234902
F2xq_matrix_pow 234903
F2x_matFrobenius 234905
F2x_is_smooth 239870
F2x_sqrt 247107
_F2xq_zero 259306
F2x_is_smooth_squarefree 275341
F2x_shiftpos 281859
F2x_shift 283117
F2xX_to_Kronecker 310708
_F2xqXQ_add 345198
_F2xqXQ_red 351330
F2xq_powers 364179
_F2xqXQ_one 374899
F2xX_add 423577
pol1_F2xX 446313
F2xq_trace 456744
F2xX_F2x_mul 481740
_F2xqXQ_cmul 481740
F2xq_log 543719
F2xqX_divrem_basecase 545283
F2xq_div 558104
F2xq_easylog 559498
_F2xq_red 582568
F2x_F2xqV_eval 610778
F2x_Frobenius 658436
F2xqX_rem 750190
get_F2xqX_red 783419
_F2xq_one 925415
F2xqX_red 1004146
Rg_to_F2xq 1164194
_F2xq_sqr 1208507
F2x_deriv 1286336
F2x_to_ZX 1315733
F2xV_to_ZXV_inplace 1433502
F2x_to_F2v 1555336
F2x_slice 1609820
_F2xq_add 1695203
F2xq_inv 2041696
F2x_extgcd 2041703
F2xq_invsafe 2041703
_F2xq_cmul 2083264
_F2xq_mul 2181910
_F2xq_pow 2396845
F2xq_pow 2440104
F2xX_renormalize 2712129
ZX_to_F2x 3145830
F2x_mulspec_basecase 3819649
F2x_gcd 3889262
F2xq_sqr 8780423
F2x_sqr 9140602
F2xq_mul 10048188
F2x_divrem 11706040
F2x_mul1 20092348
F2x_shiftip 23944387
F2x_mul 28352837
F2x_mulspec 28417013
F2x_add 31069774
F2x_rem 49360590
F2x_degree 81407121
F2x_addshiftip 136762320
F2x_addshiftipspec 164376632
F2x_degree_lg 270464358

Generated by: LCOV version 1.16