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.16.2 lcov report (development 29115-f22e516b23) Lines: 1610 1770 91.0 %
Date: 2024-02-22 08:05:55 Functions: 199 218 91.3 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
RgXQX_mul 0
RgXQX_powers 0
RgXQX_sqr 0
RgXV_prod 0
RgX_RgXQV_eval 0
RgX_RgXn_eval 0
RgX_Rg_eval_bk 0
RgX_affine 0
RgX_sqrhigh_i 0
RgX_sqrhigh_i2 0
RgXn_div_FpXQX 0
RgXn_exp 0
RgXn_inv_FpXQX 0
RgXn_powu 0
RgXn_sqr_basecase 0
_RgX_mul 0
_gen_sub 0
_sub 0
_zeroXn 0
RgXn_sqrt 7
RgXn_sqrhigh 14
RgXQX_RgXQ_mul 35
RgX_rem_FpXQX 70
RgXn_inv_FpX 91
rfrac_deflate 98
rfrac_deflate_max 98
rfrac_deflate_order 98
RgXn_div_FpX 119
RgXQV_RgXQ_mul 133
RgXn_reverse 154
RgX_sqr_FpXQX 196
QXY_QXQ_evalx 231
RgXY_degreex 288
RgXn_sqr2 315
RgXQM_mul 322
RgXX_to_RgM 322
RgXQ_trace 455
RgXnV_red_shallow 483
RgXn_powers 483
zero_FpXQX_mod 532
RgXV_maxdegree 588
_zero 840
RgXY_swap 952
RgX_RgXnV_eval 966
ZX_unscale_divpow 966
RgXQV_red 1204
RgX_sqr_FpX 1365
QXQX_homogenous_evalpow 1652
_oneXn 1939
RgX_mul_FpXQX 2044
QXV_QXQ_eval 2261
RgXn_powu_i 2286
RgXV_rescale 2401
do_QXQ_eval 2492
RgX_divs 2660
RgXQ_matrix_pow 2891
RgXV_RgV_eval 2947
RgXY_derivx 3052
RgX_muls 3943
RgXQ_powers 4214
_mulXn 4528
RgXn_eval 5092
RgXQ_norm 5179
QX_ZXQV_eval 5502
RgXV_unscale 5754
QXQM_to_mod_shallow 6251
RgX_digits 6923
RgXQV_factorback 7013
RgM_to_RgXV_reverse 7097
QXQ_powers 8344
RgX_sqr_i 8813
RgX_sqrspec_basecase 8852
RgX_sqrspec 8891
ZXQ_powers 10906
RgX_pseudodivrem 11650
RgXQX_pseudodivrem 11888
_sqrXn 11893
ZX_unscale_div 12073
RgXn_sqr 12152
RgXQM_red 12257
QXQXV_to_mod 12495
RgX_sqr_QXQX 13390
QXQC_to_mod_shallow 13412
ZXQX_dvd 17083
QXQV_to_mod 18177
RgX_homogenize 18732
RgX_normalize 18998
RgX_unscale 19161
RgM_to_RgXX 23116
RgXQX_translate 23651
_gen_zero 24184
_RgX_divrem 30352
RgX_recip 31150
RgXY_swapspec 31246
QXQX_to_mod 37184
RgX_rem_QXQX 38310
RgX_splitting 43547
RgX_sqrspec_basecase_limb 50354
RgXn_expint 52857
RgX_recip_shallow 57526
RgX_integXn 58713
RgXQC_red 63875
RgX_Rg_add_shallow 64691
_sqr 65139
RgX_mul2n 65268
RgX_rem_FpX 68670
RgXV_to_RgM 77516
_pow 86452
RgXQ_pow 100165
_ZXQmul 113840
RgXQ_powu 115506
RgXQX_divrem 136541
RgXQX_pseudorem 138469
RgX_pseudorem 138469
zero_FpX_mod 152783
get_Rg_algebra 154097
QXQX_to_mod_shallow 161699
RgX_mul_QXQX 163468
QXQ_to_mod 166649
RgX_RgV_eval 166768
Kronecker_to_mod 178559
RgX_Rg_sub 182838
ZXQ_powu 188551
RgV_to_RgX_reverse 189375
_ZXQsqr 213718
ZX_unscale2n 216985
RgX_addspec 222774
RgX_homogenous_evalpow 226034
RgX_div_by_X_x 242796
_mul 270603
RgM_to_RgXV 300630
RgX_rotate_shallow 317037
RgV_to_RgM 333263
_gen_sqr 345087
RgX_RgXQ_eval 400537
RgX_liftred 416946
RgXQX_red 456154
_gen_cmul 512818
RgX_addmulXn 515333
RgXn_div 583134
_add 603797
RgXn_recip_shallow 637312
_red 703311
QXQ_to_mod_shallow 709351
gen_bkeval 731233
RgX_deriv 793076
RgX_inflate 796701
RgXn_inv 807452
RgX_mul_FpX 818061
RgX_valrem_inexact 831791
RgXn_inv_fast 901528
RgXn_inv_i 901528
RgX_deflate 959234
_one 978229
ZX_unscale 999575
_cmul 1004464
_gen_mul 1042482
_gen_nored 1194349
RgX_sqr 1194415
RgX_sqr_fast 1206567
_gen_one 1217930
RgXn_div_fast 1279480
RgXn_div_i 1279480
rem 1318404
Rg_to_RgC 1344097
RgX_recipspec_shallow 1378314
ZX_z_unscale 1450726
RgV_to_RgX 1488745
RgX_shift 1567501
RgX_mulhigh_i2 1583632
RgX_mul_normalized 1692196
RgXn_div_gen 2180797
RgXn_mulhigh 2602526
RgX_mulhigh_i 2661256
RgX_blocks 2775644
RgX_mulXn 2984861
RgX_recip_i 3630104
RgX_val 3633368
RgX_Rg_divexact 3951143
RgX_rescale 4141400
Rg_RgX_sub 4684722
RgX_neg 5172614
RgX_translate_basecase 5806679
RgX_translate 5807100
RgX_renormalize_lg 6151717
RgXn_mul_basecase 6601346
Rg_get_0 6974331
RgXn_red_shallow 7905452
RgX_addspec_shallow 8506590
RgX_addmulXn_shallow 9067737
RgXn_mul2 9375638
RgXn_mul 11012929
gen_bkeval_powers 12269315
RgX_to_RgC 13110538
gen_RgXQ_eval_powers 13716509
RgX_rem_fast 13878180
RgX_rem 13878191
RgX_divrem 14049057
_gen_add 15705453
RgX_Rg_add 18859812
brent_kung_optpow 19605065
RgX_mul_i 20509139
RgX_mulspec_basecase 21219382
RgX_mulspec 21947449
RgX_divrem_i 22903278
RgX_equal 24761386
RgX_Rg_div 29208994
RgX_even_odd 47593638
RgXspec_kill0 55650034
RgX_mul 60828230
RgX_sub 61841866
RgX_mul_fast 74502385
RgX_add 76926120
RgX_valrem 80187181
RgX_mulspec_basecase_limb 93179461
RgX_Rg_mul 127714478
Rg_get_1 156646092
RgX_shift_shallow 164786461

Generated by: LCOV version 1.14