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 - RgX.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.18.0 lcov report (development 29644-f1a46412a2) Lines: 1620 1773 91.4 %
Date: 2024-10-12 09:06:38 Functions: 200 218 91.7 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
Kronecker_to_mod 184439
QXQC_to_mod_shallow 13426
QXQM_to_mod_shallow 6258
QXQV_to_mod 17873
QXQXV_to_mod 12530
QXQX_homogenous_evalpow 1652
QXQX_to_mod 37254
QXQX_to_mod_shallow 162229
QXQ_powers 8456
QXQ_to_mod 167041
QXQ_to_mod_shallow 711050
QXV_QXQ_eval 2331
QXY_QXQ_evalx 231
QX_ZXQV_eval 5698
RgM_to_RgXV 301693
RgM_to_RgXV_reverse 7202
RgM_to_RgXX 23466
RgV_to_RgM 333995
RgV_to_RgX 1493734
RgV_to_RgX_reverse 189837
RgXQC_red 63903
RgXQM_mul 322
RgXQM_red 12271
RgXQV_RgXQ_mul 133
RgXQV_factorback 7118
RgXQV_red 1204
RgXQX_RgXQ_mul 35
RgXQX_divrem 136800
RgXQX_mul 0
RgXQX_powers 0
RgXQX_pseudodivrem 12084
RgXQX_pseudorem 629218
RgXQX_red 467973
RgXQX_sqr 0
RgXQX_translate 23840
RgXQ_matrix_pow 2912
RgXQ_norm 5144
RgXQ_pow 102328
RgXQ_powers 8519
RgXQ_powu 115766
RgXQ_trace 448
RgXV_RgV_eval 2947
RgXV_maxdegree 588
RgXV_prod 0
RgXV_rescale 2401
RgXV_to_RgM 77659
RgXV_unscale 5845
RgXX_to_RgM 322
RgXY_degreex 288
RgXY_derivx 3836
RgXY_swap 952
RgXY_swapspec 31296
RgX_RgV_eval 166768
RgX_RgXQV_eval 0
RgX_RgXQ_eval 401373
RgX_RgXnV_eval 966
RgX_RgXn_eval 0
RgX_Rg_add 22009144
RgX_Rg_add_shallow 64887
RgX_Rg_div 30143500
RgX_Rg_divexact 7159413
RgX_Rg_eval_bk 0
RgX_Rg_mul 133886084
RgX_Rg_sub 179495
RgX_add 82276464
RgX_addmulXn 516075
RgX_addmulXn_shallow 10032051
RgX_addspec 223516
RgX_addspec_shallow 8881303
RgX_affine 0
RgX_blocks 2787567
RgX_deflate 981464
RgX_deriv 821496
RgX_digits 6923
RgX_div_by_X_x 249677
RgX_divrem 14359962
RgX_divrem_i 23600759
RgX_divs 2660
RgX_equal 24618563
RgX_even_odd 49613698
RgX_homogenize 18732
RgX_homogenous_evalpow 664997
RgX_inflate 797299
RgX_integXn 56304
RgX_liftred 428716
RgX_mul 63910981
RgX_mul2n 65268
RgX_mulXn 2984903
RgX_mul_FpX 818173
RgX_mul_FpXQX 2044
RgX_mul_QXQX 169320
RgX_mul_fast 77642687
RgX_mul_i 20902493
RgX_mul_normalized 1710509
RgX_mulhigh_i 2670763
RgX_mulhigh_i2 1589258
RgX_muls 3964
RgX_mulspec 22342916
RgX_mulspec_basecase 21613722
RgX_mulspec_basecase_limb 94243375
RgX_neg 7764433
RgX_normalize 38906
RgX_pseudodivrem 11846
RgX_pseudorem 629218
RgX_recip 31220
RgX_recip_i 5107045
RgX_recip_shallow 59367
RgX_recipspec_shallow 1379434
RgX_rem 14393053
RgX_rem_FpX 68670
RgX_rem_FpXQX 70
RgX_rem_QXQX 38329
RgX_rem_fast 14393035
RgX_renormalize_lg 6216875
RgX_rescale 4331513
RgX_rotate_shallow 317037
RgX_shift 1567508
RgX_shift_shallow 175260839
RgX_splitting 43631
RgX_sqr 1345515
RgX_sqr_FpX 1421
RgX_sqr_FpXQX 196
RgX_sqr_QXQX 13418
RgX_sqr_fast 1357667
RgX_sqr_i 8855
RgX_sqrhigh_i 0
RgX_sqrhigh_i2 0
RgX_sqrspec 8933
RgX_sqrspec_basecase 8894
RgX_sqrspec_basecase_limb 50452
RgX_sub 63644395
RgX_to_RgC 13220666
RgX_translate 5955185
RgX_translate_basecase 5954761
RgX_unscale 19861
RgX_val 3647115
RgX_valrem 82364767
RgX_valrem_inexact 851677
RgXnV_red_shallow 483
RgXn_div 584443
RgXn_div_FpX 119
RgXn_div_FpXQX 7
RgXn_div_fast 1284106
RgXn_div_gen 2188910
RgXn_div_i 1284106
RgXn_eval 5145
RgXn_exp 0
RgXn_expint 52890
RgXn_inv 807452
RgXn_inv_FpX 91
RgXn_inv_FpXQX 0
RgXn_inv_fast 905018
RgXn_inv_i 905018
RgXn_mul 11060938
RgXn_mul2 9413660
RgXn_mul_basecase 6627805
RgXn_mulhigh 2614442
RgXn_powers 483
RgXn_powu 0
RgXn_powu_i 2286
RgXn_recip_shallow 639087
RgXn_red_shallow 7923784
RgXn_reverse 154
RgXn_sqr 12152
RgXn_sqr2 315
RgXn_sqr_basecase 0
RgXn_sqrhigh 14
RgXn_sqrt 7
RgXspec_kill0 56491691
Rg_RgX_sub 4853319
Rg_get_0 6974422
Rg_get_1 156627454
Rg_to_RgC 1346713
ZXQX_dvd 17231
ZXQ_powers 11018
ZXQ_powu 168507
ZX_unscale 1009704
ZX_unscale2n 925197
ZX_unscale_div 12997
ZX_unscale_divpow 966
ZX_z_unscale 1463320
_RgX_divrem 30352
_RgX_mul 0
_ZXQmul 111119
_ZXQsqr 200493
_add 605534
_cmul 1007030
_gen_add 19230609
_gen_cmul 512818
_gen_mul 1842358
_gen_nored 2027327
_gen_one 2068432
_gen_sqr 599501
_gen_sub 0
_gen_zero 24184
_mul 274475
_mulXn 4528
_one 984881
_oneXn 1939
_pow 88307
_red 705071
_sqr 67175
_sqrXn 11893
_sub 0
_zero 840
_zeroXn 0
brent_kung_optpow 19659811
do_QXQ_eval 2562
gen_RgXQ_eval_powers 14467040
gen_bkeval 858718
gen_bkeval_powers 12418305
get_Rg_algebra 281033
rem 4036618
rfrac_deflate 105
rfrac_deflate_max 105
rfrac_deflate_order 105
zero_FpXQX_mod 532
zero_FpX_mod 152790

Generated by: LCOV version 1.16