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 - Flx.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.18.0 lcov report (development 29792-e7296d7d08) Lines: 2402 2712 88.6 %
Date: 2024-12-05 09:09:40 Functions: 296 342 86.5 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
Fl_Xp1_powu 0
Flv_prod 0
FlxC_FlxqV_eval 0
FlxC_FlxqV_eval_pre 0
FlxC_Flxq_eval 0
FlxC_Flxq_eval_pre 0
FlxC_neg 0
FlxC_sub 0
FlxM_Flx_add_shallow 0
FlxM_neg 0
FlxM_sub 0
FlxM_to_FlxXV 0
FlxV_Flx_fromdigits 0
FlxV_prod 0
FlxV_red 0
Flx_Flv_multieval 0
Flx_composedprod 0
Flx_convol 0
Flx_digits 0
Flx_halfgcd 0
Flx_integ 0
Flx_invBarrett 0
Flx_matFrobenius 0
Flx_powu 0
Flx_recip 0
Flxn_exp 0
Flxn_sqr 0
Flxn_sqr_pre 0
FlxqC_Flxq_mul 0
FlxqM_Flxq_mul 0
FlxqV_dotproduct 0
Flxq_autsum 0
Flxq_auttrace 0
Flxq_is2npower 0
Flxq_lroot 0
Flxq_lroot_fast 0
Flxq_pow_init 0
Flxq_pow_table 0
ZXV_to_FlxV 0
Z_mod2BIL_Flx_3 0
_Flx_divrem 0
_Flx_sqr 0
kron_pack_Flx_spec_3 0
kron_unpack_Flx_3 0
zero_FlxC 0
zero_FlxM 0
Flxq_autpow 7
RgXV_to_FlxV 7
matJ2_FlxM 13
Flxq_conjvec 20
Flxq_pow_init_pre 28
Flx_extresultant 53
Flx_extresultant_basecase 53
Flx_extresultant_pre 53
_Flxq_powu 68
Flx_sqrspec_halfsqri 136
Flx_halfgcd_all 154
Flxq_matrix_pow 399
ZpX_invLaplace_init 497
matid2_FlxM 895
Flxn_inv 1030
Flx_halfres_pre 1044
Flx_rescale 1117
Flxq_autpowers 1667
Flx_sqrspec_sqri 2260
Flm_to_FlxV 2296
FlxqX_dotproduct 2456
FlxV_Flv_multieval 2471
FlxV_Flv_multieval_tree 2471
kron_unpack_Flx_2 2930
Flv_prod_pre 3255
kron_pack_Flx_spec_2 3389
Flxq_charpoly 3632
_Flx_composedsum 3826
Flxq_pow_table_pre 4392
Flxq_trace 4402
FlxM_to_ZXM 4611
Flx_FlxqV_eval 5103
Flx_mulspec_halfmulii 5454
Flx_FlxM_qmul 6345
FlxM_mul2 6517
gener_Flxq 7187
Flx_powu_pre 7838
Flx_is_l_pow 8407
Flx_halfres_update_pre 9405
Flx_mulspec_mulii 10023
Flx_sqrspec_quartsqri 10221
Flx_Fl2_eval_pre 10402
Flv_inv_pre 10848
Flx_sqrspec_sqri_inflate 11501
Flv_inv_inplace 12017
zl_Xp1_powu 12017
int_to_Flx 12295
init_invlaplace 12514
Flx_diff1 13447
Flx_halve 14265
Flx_translate1 16107
_Flxq_s 16890
_Flxq_inv 18980
Flx_halfres_split 19282
FlxM_eval_powers_pre 19452
Flxq_autpow_msqr 20730
Flx_invBarrett_Newton 23116
FlxM_Flx_mul2 24751
Flxq_lroot_pre 25053
zlx_translate1 25259
Flx_Laplace 27276
Flx_composedsum 27489
Flx_translate1_basecase 28201
FlxV_composedsum 28905
ZM_unpack_FlxqM 29345
Flx_mod_Xn1 30282
FlxV_Flc_mul 34482
Fl_Flxq_log 35408
translate_basecase 41366
kron_unpack_Flx 42953
Flxq_minpoly 44415
Flv_inv_indir 49733
kron_pack_Flx_spec 53832
Flx_Newton 53991
Flx_invLaplace 54254
Flxn_div 55036
Flxn_div_pre 55055
FlxM_pack_ZM 58683
ZM_unpack_FlxqM_bits 59848
Fl2_sqrt_pre 67842
Flx_to_FlxX 71517
get_Flxq_field 73608
set_Flxq 73628
Flx_is_smooth 74256
Fl2_sqrtn_pre 74736
Flxn_mul 75316
Flx_matFrobenius_pre 86454
Flx_Frobenius 86486
FlxqM_mul_Kronecker 89193
Flxq_order 96584
Flx_mulspec_quartmulii 97106
Flv_Flm_polint 101077
int_to_Flx_quart 107333
Flx_fromNewton 109343
Flxn_expint 109346
FlxC_to_ZXC 109566
_Fl2_rand 111070
FlxqV_dotproduct_pre 113589
Flxq_lroot_fast_pre 113589
Flx_is_smooth_pre 118977
FlxM_pack_ZM_bits 119615
Fl2_norm_pre 126146
Flx_is_smooth_squarefree 127366
Flx_invBarrett_basecase 134215
Flx_splitting 147320
Flx_Fl_sub 151012
Flx_extgcd_halfgcd 152027
Flv_invVandermonde 152995
Flx_inflate 158457
Flx_invBarrett_pre 158721
Flxq_log 164469
_Flxq_equal0 165726
Flxq_matrix_pow_pre 170491
FlxV_to_Flm 171715
Flxq_sqrtn 177037
Fl2_inv_pre 193278
Flx_to_int_quartspec 204431
Flxn_recip 216988
Flxq_sqrt 224774
Flxq_sqrt_pre 224774
Flxq_powers 232203
Flxq_div 237395
FlxC_eval_powers_pre 251072
Flx_mulspec_mulii_inflate 283389
FlxT_red 294153
Z_mod2BIL_Flx 294890
Z_mod2BIL_Flx_2 297820
Flxq_autpow_pre 304370
Flxq_autsum_pre 315824
_Flxq_rand 330192
Flxq_inv 345508
Flx_sqr 356012
Flv_polint 368207
Flxq_autsum_sqr 379957
Flxq_autpow_sqr 386199
FlxV_to_FlxX 396559
Flxq_issquare 399304
Flx_deflate 419205
Flx_integXn 422540
Flx_addmulmul 430134
get_Flxq_star 431804
Flxq_norm 438061
Fl2_equal1 440071
Flxq_powu 486933
Flx_to_int_halfspec 509899
Flxn_mulhigh 516014
Flx_blocks 516096
_Flxq_neg 553759
_Flx_add 578752
Flx_eval2BILspec 581668
Flxq_autsum_mul 588812
int_to_Flx_half 594101
FlxV_to_ZXV 600416
Flx_divrem_Barrett 603603
Flv_inv 623546
Flv_producttree 624753
Flxq_auttrace_sqr 635517
Flv_inv_i 635558
Flxq_invsafe 656243
_Fl2_pow 657684
Fl2_pow_pre 657697
Flx_Flv_multieval_tree 665055
Flx_sqrspec_Kronecker 688584
Flxq_easylog 691234
Flv_roots_to_pol 737412
Flxq_auttrace_mul 762453
Flxq_minpoly_pre 783888
Flx_Flxq_eval 786387
Flx_halfgcd_pre 845268
bounded_order 851099
Flx_extgcd 852675
kron_pack_Flx_spec_half 857451
Flx_subspec 896314
Flx_divrem_Barrettspec 903847
monomial_Flx 912053
Flxq_pow 915500
Flxq_auttrace_pre 934826
Flx_mulhigh_i 937684
Flx_triple 1043249
Flx_halfgcd_all_i 1110722
Flx_halfgcd_all_pre 1110724
Flx_halfres_basecase 1117233
Flx_halfres_i 1136518
FlvV_polint_tree 1386135
_Flxq_rmul 1577269
Flxq_transmul_init 1690496
Rg_to_F2 1707018
Flx_neg_inplace 1766287
_Flxq_red 1773388
Flx_red 1874300
_Fl2_mul 1888291
Fl2_mul_pre 1916409
Flx_lgrenormalizespec 2129455
Flxq_div_pre 2414463
Flx_double 2434345
Flx_Flxq_eval_pre 2627268
random_Flx 2663720
Z_to_Flx 2673270
Flxq_sqr 2746658
RgX_to_Flx 2826382
FlxV_to_ZXV_inplace 2923707
Flx_neg 3451489
Flx_negspec 3451494
Rg_to_Flxq 3565057
Flx_addshift 3701783
ZXT_to_FlxT 3782370
Flxq_transmul 4081030
Flx_val 4150578
Flx_resultant 4654622
Flxq_inv_pre 4809588
_Fl2_sqr 4821389
Fl2_sqr_pre 4821426
Flxn_mul_pre 5062896
Flx_mod_Xnm1 5097134
kron_unpack_Flx_bits_wide 5540392
kron_unpack_Flx_bits_narrow 5684577
Flxq_invsafe_pre 5911450
zx_to_Flx 6063887
Flxn_red 6229296
Flx_extgcd_basecase 6764123
Flx_extgcd_pre 6764130
Flx_recipspec 7115906
Flx_Fl_mul 7116095
mkF2 7191276
Flx_addspec 7204967
Flx_mulspec_Kronecker 7270837
maxbitcoeffpol 8383509
Flx_is_squarefree 8524438
Flx_Fl_add 9688164
Flx_resultant_basecase_pre 10185312
Flx_resultant_pre 10187203
_Flx_mul 10480456
Flx_Fl_mul_to_monic 11944971
Flx_blocks_Flm 13019331
FlxV_to_Flm_lg 13020045
Flxq_mul 13180602
Flx_FlxqV_eval_pre 13218279
Flx_Frobenius_pre 13668137
Flx_get_red 14033571
Flv_inv_pre_inplace 18283194
Flx_Fl_mul_pre 18847153
Flv_inv_pre_indir 18905135
Fl_to_Flx 19844578
Flx_eval 20395343
kron_pack_Flx_spec_bits 20845426
Flx_deriv 21063875
_Flxq_one 22682540
Flxq_powers_pre 22684398
_Flxq_powu_i 22871339
Flxq_powu_pre 23915697
Flx_valrem 26265055
Flx_shift 26732087
Flv_to_Flx 26922534
Flx_mul 28055653
_Flxq_pow 28380704
Flxq_pow_Frobenius 28388083
Flxq_pow_pre 29138124
Flx_divrem 30360356
Flx_equal 30648682
Flx_gcd 32490668
Flx_div_by_X_x 33011481
Flx_to_ZX_inplace 36786680
Flx_to_ZX 37065447
Flx_rem 41764204
Flx_eval_powers_pre 43719441
Flx_normalize 62089544
Flx_divrem_basecase 63157792
Flx_add 63683578
Flx_to_Flv 63887328
Rg_to_Fl 74783866
set_Flxq_pre 74904822
Flx_divrem_pre 80578418
Flx_gcd_basecase 82963081
Flx_gcd_pre 84605560
Flx_eval_pre 100647781
Flx_get_red_pre 102581089
Flx_sub 139469105
_Flxq_mul 155150767
ZX_to_Flx 167549287
Flxq_mul_pre 196633624
_Flxq_sqr 274570062
Flxq_sqr_pre 281989336
Flx_sqrspec_basecase 282959485
Flx_sqr_pre 283002607
Flx_sqrspec 283184512
Flx_mulspec_basecase 347596233
Flx_mul_pre 379442596
Flx_mulspec 384942794
Flx_shiftip 638934715
Flx_rem_basecase 796112274
Flx_rem_pre 921230249
get_Flx_red 986083364
Flx_mullimb 1150163799
Flx_renormalize 2146085098
get_Fl_threshold 2335754318
Flx_mullimb_ok 3463835463

Generated by: LCOV version 1.16