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 - FpX.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.8.0 lcov report (development 18888-55e726a) Lines: 1106 1183 93.5 %
Date: 2016-04-30 Functions: 139 142 97.9 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 524 656 79.9 %

Function Name Sort by function name Hit count Sort by hit count
FpV_inv 2423
FpV_roots_to_pol 5083
FpXC_FpXQV_eval 434
FpXM_FpXQV_eval 98
FpXM_FpX_mul2 498
FpXM_mul2 166
FpXQM_autsum 70
FpXQM_autsum_mul 98
FpXQM_autsum_sqr 70
FpXQ_autpow 528
FpXQ_autpow_mul 7
FpXQ_autpow_sqr 556
FpXQ_autpowers 595
FpXQ_autsum 970
FpXQ_autsum_mul 1894
FpXQ_autsum_sqr 984
FpXQ_auttrace 14
FpXQ_auttrace_mul 7
FpXQ_auttrace_sqr 7
FpXQ_charpoly 1
FpXQ_conjvec 8
FpXQ_div 255958
FpXQ_inv 326925
FpXQ_invsafe 327417
FpXQ_issquare 3489
FpXQ_log 84598
FpXQ_matrix_pow 3878
FpXQ_minpoly 3095
FpXQ_mul 39488385
FpXQ_norm 3441
FpXQ_order 29
FpXQ_pow 729568
FpXQ_pow_Frobenius 450401
FpXQ_powers 181917
FpXQ_powu 61698
FpXQ_red 3160856
FpXQ_sqr 2978798
FpXQ_sqrt 6654
FpXQ_sqrtn 7708
FpXQ_trace 20691
FpXQ_transmul 123
FpXQ_transmul_init 30
FpXT_red 723243
FpXV_prod 19491
FpXV_red 287194
FpX_FpXM_qmul 162
FpX_FpXQV_eval 99229
FpX_FpXQ_eval 150210
FpX_Fp_add 550453
FpX_Fp_add_shallow 0
FpX_Fp_mul 3874485
FpX_Fp_mul_to_monic 52385
FpX_Fp_mulspec 3876186
FpX_Fp_sub 118419
FpX_Fp_sub_shallow 1551
FpX_Frobenius 76778
FpX_add 8855637
FpX_addmulmul 1004
FpX_center 642796
FpX_chinese_coprime 665
FpX_deriv 798111
FpX_digits 5642
FpX_disc 14
FpX_div_by_X_x 20015
FpX_divrem 3886840
FpX_divrem_Barrett_noGC 96046
FpX_divrem_Barrettspec 96485
FpX_divrem_basecase 57333391
FpX_dotproduct 566
FpX_eval 524980
FpX_extgcd 361026
FpX_extgcd_basecase 277338
FpX_extgcd_halfgcd 4
FpX_fromdigits 2296
FpX_gcd 126813
FpX_gcd_basecase 51911
FpX_gcd_check 0
FpX_get_red 675222
FpX_halfgcd 455
FpX_halfgcd_basecase 187
FpX_halfgcd_i 349
FpX_halfgcd_split 162
FpX_halve 606
FpX_invBarrett 1976
FpX_invBarrett_Newton 569
FpX_invBarrett_basecase 1403
FpX_is_squarefree 2471
FpX_matFrobenius 2583
FpX_mul 45741355
FpX_mulspec 369039
FpX_mulu 1185611
FpX_neg 153206
FpX_normalize 245851
FpX_powu 144410
FpX_recipspec 193630
FpX_red 64511846
FpX_rem 57450370
FpX_rescale 13076
FpX_resultant 6055
FpX_sqr 3042403
FpX_sub 5132062
FpX_subspec 5228548
FpX_valrem 23296
FpXn_mul 108
Fp_FpXQ_log 37747
Fp_FpX_sub 33872
Fp_issquare 46872
Fp_neg_FpX 29
Fp_red_FpX 2564
FqV_inv 0
Fq_ispower 112
Fq_issquare 46662
Fq_log 1876
ZX_lgrenormalizespec 204484
Z_to_FpX 1710
_FpXQ_add 993713
_FpXQ_cmul 1095747
_FpXQ_easylog 796
_FpXQ_mul 1252937
_FpXQ_one 236809
_FpXQ_pow 449802
_FpXQ_rand 2441
_FpXQ_red 255892
_FpXQ_sqr 2471572
_FpXQ_zero 408
_FpX_add 10241
_FpX_divrem 69706
_FpX_mul 66883
_FpX_sqr 29344
bounded_order 3936
gener_FpXQ 6666
gener_FpXQ_i 1444
gener_FpXQ_local 1428
get_FpXQ_star 1265
get_FpX_degree 1889478
get_FpX_mod 437699
get_FpX_red 61337241
get_FpX_var 1342656
matid2_FpXM 4
random_FpX 45222
to_Flx 41300517
to_Flxq 645877

Generated by: LCOV version 1.9