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 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.10.0 lcov report (development 21947-4fc3047) Lines: 1457 1612 90.4 %
Date: 2018-02-24 06:16:21 Functions: 171 184 92.9 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
Kronecker_to_mod 122128
QXQC_to_mod_shallow 16674
QXQM_to_mod_shallow 5908
QXQV_to_mod 4726
QXQXV_to_mod 1029
QXQX_to_mod 2961
QXQX_to_mod_shallow 121754
QXQ_powers 2028
QXQ_to_mod 850357
QXQ_to_mod_copy 22110
QXV_QXQ_eval 1218
QXX_QXQ_eval 63
QX_ZXQV_eval 2653
RgM_to_RgXV 48027
RgM_to_RgXX 15911
RgV_to_RgM 103393
RgV_to_RgX 452579
RgV_to_RgX_reverse 152919
RgXQC_red 80535
RgXQM_mul 0
RgXQM_red 12278
RgXQV_RgXQ_mul 77
RgXQV_red 686
RgXQX_RgXQ_mul 4417
RgXQX_divrem 57873
RgXQX_mul 12789
RgXQX_powers 448
RgXQX_pseudodivrem 5333
RgXQX_pseudorem 25298
RgXQX_red 341036
RgXQX_sqr 1792
RgXQX_translate 6083
RgXQ_matrix_pow 287
RgXQ_minpoly_naive 56
RgXQ_norm 34738
RgXQ_pow 18121
RgXQ_powers 2903
RgXQ_powu 207101
RgXV_RgV_eval 2814
RgXV_to_RgM 2841
RgXV_unscale 308
RgXX_to_RgM 98
RgXY_degreex 92
RgXY_swap 952
RgXY_swapspec 13918
RgX_RgV_eval 129927
RgX_RgXQV_eval 0
RgX_RgXQ_eval 45388
RgX_RgXnV_eval 714
RgX_RgXn_eval 0
RgX_Rg_add 11538020
RgX_Rg_add_shallow 2547
RgX_Rg_div 22619127
RgX_Rg_divexact 434049
RgX_Rg_eval_bk 0
RgX_Rg_mul 67754063
RgX_Rg_sub 33505
RgX_add 17272859
RgX_addmulXn 471092
RgX_addmulXn_shallow 2118193
RgX_addspec 180602
RgX_addspec_shallow 2993734
RgX_blocks 105041
RgX_deflate 122520
RgX_deriv 231155
RgX_digits 2219
RgX_div_by_X_x 40687
RgX_divrem 10983834
RgX_divrem_i 11898842
RgX_divs 2457
RgX_equal 3875765
RgX_even_odd 30617
RgX_inflate 382253
RgX_liftred 303761
RgX_mul 36808800
RgX_mulXn 2859853
RgX_mul_FpX 394036
RgX_mul_FpXQX 56
RgX_mul_QXQX 118144
RgX_mul_fast 40799798
RgX_mul_i 7340402
RgX_mul_normalized 604821
RgX_mulhigh_i 34929
RgX_mulhigh_i2 1434
RgX_muls 14217
RgX_mulspec 8745830
RgX_mulspec_basecase 8212130
RgX_mulspec_basecase_limb 42142993
RgX_neg 1067368
RgX_normalize 1925
RgX_pseudodivrem 5172
RgX_pseudorem 25298
RgX_recip 2093
RgX_recip_shallow 372137
RgX_recipspec_shallow 445056
RgX_rem 5986353
RgX_rem_FpX 329539
RgX_rem_FpXQX 35
RgX_rem_QXQX 31846
RgX_rem_fast 5986322
RgX_renormalize_lg 752701
RgX_rescale 1855
RgX_rotate_shallow 315273
RgX_shift 3403257
RgX_shift_shallow 59155736
RgX_splitting 40670
RgX_sqr 2538406
RgX_sqr_FpX 1260
RgX_sqr_FpXQX 147
RgX_sqr_QXQX 3781
RgX_sqr_fast 2554467
RgX_sqr_i 5768
RgX_sqrhigh_i 0
RgX_sqrhigh_i2 0
RgX_sqrspec 5846
RgX_sqrspec_basecase 5807
RgX_sqrspec_basecase_limb 32595
RgX_sub 12296838
RgX_to_RgC 6570173
RgX_translate 1091049
RgX_unscale 5880
RgX_val 2111575
RgX_valrem 43136589
RgX_valrem_inexact 13926
RgXnV_red_shallow 357
RgXn_eval 2016
RgXn_exp 12810
RgXn_inv 125664
RgXn_mul 3956070
RgXn_mul2 1716223
RgXn_mul_basecase 1678157
RgXn_mulhigh 34929
RgXn_powers 357
RgXn_powu 0
RgXn_powu_i 1617
RgXn_recip_shallow 315
RgXn_red_shallow 1568032
RgXn_reverse 91
RgXn_sqr 16086
RgXn_sqr2 238
RgXn_sqr_basecase 0
RgXn_sqrhigh 0
RgXn_sqrt 0
RgXspec_kill0 19786381
Rg_RgX_sub 464773
Rg_get_0 129045
Rg_get_1 2065233
Rg_to_RgC 678623
ZXQX_dvd 5947
ZX_translate 382391
ZX_unscale 7336
ZX_unscale2n 19029
ZX_unscale_div 1176
ZX_z_unscale 322504
_RgX_divrem 9058
_add 65905
_cmul 111909
_gen_add 21638488
_gen_cmul 367381
_gen_mul 749653
_gen_nored 877523
_gen_one 895107
_gen_sqr 243063
_gen_sub 0
_gen_zero 14588
_mul 103089
_mulXn 1218
_one 107259
_oneXn 1477
_red 71505
_sqr 250597
_sqrXn 1897
_sub 0
_zero 105
_zeroXn 0
brent_kung_optpow 3038685
do_QXQ_eval 1281
gen_RgXQ_eval_powers 11845378
gen_bkeval 1371139
gen_bkeval_powers 7418525
get_Rg_algebra 113075
rem 450325
zero_FpXQX_mod 7
zero_FpX_mod 244973

Generated by: LCOV version 1.11