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-bordeaux1.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.8.0 lcov report (development 16791-0d1274a) Lines: 1169 1335 87.6 %
Date: 2014-09-16 Functions: 124 132 93.9 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 773 990 78.1 %

Function Name Sort by function name Hit count Sort by hit count
Kronecker_to_mod 0
QXQV_to_mod 115
QXQXV_to_mod 210
QXQX_to_mod 870
QXQX_to_mod_shallow 3765
QXQ_powers 460
QXQ_to_mod 10993
QXQ_to_mod_copy 6385
QXV_QXQ_eval 115
QXX_QXQ_eval 20
QX_ZXQV_eval 435
RgM_to_RgXV 22022
RgM_to_RgXX 470
RgV_to_RgM 2090
RgV_to_RgX 167520
RgV_to_RgX_reverse 72505
RgXQC_red 0
RgXQV_RgXQ_mul 30
RgXQV_red 30
RgXQX_RgXQ_mul 10
RgXQX_divrem 9175
RgXQX_mul 2260
RgXQX_pseudodivrem 128391
RgXQX_pseudorem 15015
RgXQX_red 7320
RgXQX_sqr 0
RgXQX_translate 340
RgXQ_matrix_pow 130
RgXQ_minpoly_naive 5
RgXQ_norm 16325
RgXQ_pow 474
RgXQ_powers 610
RgXQ_powu 94275
RgXV_to_RgM 8906
RgXV_unscale 105
RgXX_to_RgM 15
RgXY_swap 160
RgXY_swapspec 9622
RgX_RgXQV_eval 0
RgX_RgXQ_eval 11140
RgX_RgXnV_eval 480
RgX_RgXn_eval 0
RgX_Rg_add 6846326
RgX_Rg_add_shallow 1680
RgX_Rg_div 16167412
RgX_Rg_divexact 487302
RgX_Rg_mul 43580144
RgX_Rg_sub 20391
RgX_add 9533559
RgX_blocks 25000
RgX_deflate 23632
RgX_deriv 72924
RgX_div_by_X_x 15980
RgX_divrem 8589615
RgX_divs 195
RgX_equal 582860
RgX_even_odd 9753
RgX_get_0 3375
RgX_get_1 120205
RgX_inflate 40128
RgX_mul 6334355
RgX_mulXn 1882786
RgX_mul_normalized 121627
RgX_muls 125
RgX_mulspec 7406479
RgX_mulspec_basecase 6927308
RgX_mulspec_basecase_limb 27676467
RgX_neg 491668
RgX_normalize 30
RgX_pseudodivrem 128366
RgX_pseudorem 15015
RgX_recip 10
RgX_recip_shallow 467828
RgX_recipspec_shallow 87761
RgX_renormalize_lg 115565
RgX_rescale 500
RgX_rotate_shallow 115205
RgX_shift 2505980
RgX_shift_shallow 38530867
RgX_splitting 14555
RgX_sqr 119694
RgX_sqrspec 119766
RgX_sqrspec_basecase 119730
RgX_sqrspec_basecase_limb 1032670
RgX_sub 4902720
RgX_to_RgC 670489
RgX_translate 120423
RgX_unscale 1590
RgX_val 858604
RgX_valrem 29264577
RgX_valrem_inexact 871
RgXnV_red_shallow 240
RgXn_eval 45
RgXn_exp 0
RgXn_inv 210
RgXn_mul 78400
RgXn_mul_basecase 74650
RgXn_powers 240
RgXn_red_shallow 2150
RgXn_reverse 60
RgXn_sqr 190
RgXn_sqr_basecase 0
RgXspec_kill0 14123636
Rg_RgX_sub 246447
Rg_to_RgC 10885
ZXQX_dvd 465
ZX_translate 18282
ZX_unscale 3215
ZX_unscale2n 3850
ZX_unscale_div 105
_add 26025
_cmul 37645
_mul 36747
_mulXn 545
_one 31300
_oneXn 1030
_red 26435
_sqr 88746
_sqrXn 190
_zero 10
_zeroXn 0
addmulXn 777154
addmulXncopy 357951
addpol 1390200
addpolcopy 139019
addshiftpol 14875
brent_kung_optpow 452151
do_QXQ_eval 135
gen_RgXQ_eval_powers 2957633
gen_bkeval 476860
gen_bkeval_powers 1690076
rem 905726

Generated by: LCOV version 1.9