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 - FpX.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.8.0 lcov report (development 17588-7fd783e) Lines: 1018 1092 93.2 %
Date: 2015-03-04 Functions: 131 134 97.8 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 489 620 78.9 %

Function Name Sort by function name Hit count Sort by hit count
FpV_inv 2423
FpV_roots_to_pol 4811
FpXC_FpXQV_eval 364
FpXM_FpXQV_eval 77
FpXM_FpX_mul2 498
FpXM_mul2 166
FpXQM_autsum 56
FpXQM_autsum_mul 77
FpXQM_autsum_sqr 56
FpXQ_autpow 514
FpXQ_autpow_mul 7
FpXQ_autpow_sqr 542
FpXQ_autpowers 532
FpXQ_autsum 978
FpXQ_autsum_mul 1910
FpXQ_autsum_sqr 992
FpXQ_charpoly 2956
FpXQ_conjvec 8
FpXQ_div 261396
FpXQ_inv 342393
FpXQ_invsafe 342893
FpXQ_issquare 2326
FpXQ_log 58467
FpXQ_matrix_pow 6551
FpXQ_minpoly 2955
FpXQ_mul 38058596
FpXQ_norm 2299
FpXQ_order 38
FpXQ_pow 320060
FpXQ_pow_Frobenius 61433
FpXQ_powers 96413
FpXQ_powu 51597
FpXQ_red 3370165
FpXQ_sqr 2205782
FpXQ_sqrt 7040
FpXQ_sqrtn 7870
FpXQ_trace 10495
FpXT_red 383167
FpXV_prod 18408
FpXV_red 146927
FpX_FpXM_qmul 162
FpX_FpXQV_eval 53537
FpX_FpXQ_eval 152355
FpX_Fp_add 491527
FpX_Fp_add_shallow 0
FpX_Fp_mul 4303746
FpX_Fp_mul_to_monic 51558
FpX_Fp_mulspec 4304894
FpX_Fp_sub 87883
FpX_Fp_sub_shallow 1566
FpX_Frobenius 71746
FpX_add 8223074
FpX_addmulmul 1004
FpX_center 581923
FpX_chinese_coprime 665
FpX_deriv 788006
FpX_digits 5572
FpX_disc 14
FpX_div_by_X_x 18540
FpX_divrem 3762056
FpX_divrem_Barrett_noGC 92523
FpX_divrem_Barrettspec 92963
FpX_divrem_basecase 53701795
FpX_eval 481638
FpX_extgcd 374141
FpX_extgcd_basecase 282540
FpX_extgcd_halfgcd 4
FpX_fromdigits 2296
FpX_gcd 89157
FpX_gcd_basecase 18751
FpX_gcd_check 0
FpX_get_red 175573
FpX_halfgcd 398
FpX_halfgcd_basecase 172
FpX_halfgcd_i 334
FpX_halfgcd_split 162
FpX_halve 875
FpX_invBarrett 2159
FpX_invBarrett_Newton 557
FpX_invBarrett_basecase 1598
FpX_is_squarefree 2205
FpX_matFrobenius 2498
FpX_mul 52791680
FpX_mulspec 345502
FpX_mulu 1106124
FpX_neg 192816
FpX_normalize 240828
FpX_powu 3094
FpX_recipspec 186483
FpX_red 67133028
FpX_rem 53043764
FpX_rescale 13146
FpX_resultant 4948
FpX_sqr 2250302
FpX_sub 13955841
FpX_subspec 14048804
FpX_valrem 23289
Fp_FpXQ_log 37078
Fp_FpX_sub 31902
Fp_issquare 46837
Fp_neg_FpX 52
Fp_red_FpX 828
FqV_inv 0
Fq_issquare 46641
Fq_log 1575
ZX_lgrenormalizespec 197240
Z_to_FpX 870
_FpXQ_add 483498
_FpXQ_cmul 539832
_FpXQ_easylog 863
_FpXQ_mul 399928
_FpXQ_one 130241
_FpXQ_pow 60856
_FpXQ_rand 2376
_FpXQ_red 135268
_FpXQ_sqr 1701652
_FpXQ_zero 240
_FpX_add 10241
_FpX_divrem 69622
_FpX_mul 65363
_FpX_sqr 24395
bounded_order 3947
gener_FpXQ 6512
gener_FpXQ_i 1444
gener_FpXQ_local 1428
get_FpXQ_star 1279
get_FpX_degree 1252291
get_FpX_mod 372422
get_FpX_red 56805821
get_FpX_var 1114473
matid2_FpXM 4
random_FpX 61033
to_Flx 40279970
to_Flxq 574430

Generated by: LCOV version 1.9