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 16827-3d78da8) Lines: 1010 1106 91.3 %
Date: 2014-09-29 Functions: 130 135 96.3 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 480 624 76.9 %

Function Name Sort by function name Hit count Sort by hit count
FpX_red 61377362
get_FpX_red 50374965
FpX_mul 49824385
FpX_divrem_basecase 48176367
FpX_rem 47575578
FpXQ_mul 37694798
to_Flx 36158770
FpX_subspec 12204651
FpX_sub 12121224
FpX_add 4617705
FpX_Fp_mulspec 3032577
FpX_Fp_mul 3031421
FpX_divrem 2799387
FpXQ_red 2525140
FpX_sqr 2055347
FpXQ_sqr 2025597
_FpXQ_sqr 1551550
FpX_mulu 1019245
get_FpX_var 647868
get_FpX_degree 595979
_FpXQ_cmul 541643
FpX_center 512866
_FpXQ_add 486932
FpX_eval 464629
FpX_deriv 448617
to_Flxq 405880
FpX_mulspec 372176
FpXT_red 367443
get_FpX_mod 336832
FpX_extgcd 335434
FpX_Fp_add 322160
FpXQ_invsafe 310304
FpXQ_inv 309818
_FpXQ_mul 277092
FpX_extgcd_basecase 268096
FpXQ_div 255834
FpX_normalize 233786
ZX_lgrenormalizespec 167547
FpX_recipspec 166900
FpX_FpXQ_eval 151141
FpXV_red 146266
FpX_neg 134338
_FpXQ_red 133384
_FpXQ_one 127563
FpX_get_red 125736
FpXQ_pow 119018
FpXQ_powers 95642
FpX_gcd 85772
FpX_divrem_Barrettspec 83427
FpX_divrem_Barrett_noGC 83089
FpX_Frobenius 69992
FpX_Fp_sub 62748
FpXQ_log 56219
_FpX_mul 52023
FpX_FpXQV_eval 51939
FpXQ_powu 51343
FpX_Fp_mul_to_monic 49766
Fq_issquare 46578
Fp_issquare 46578
Fp_FpXQ_log 36605
_FpX_divrem 36351
random_FpX 30799
FpX_valrem 23002
FpX_div_by_X_x 17784
FpX_gcd_basecase 17432
Fp_FpX_sub 16270
FpXV_prod 16200
FpXQ_pow_Frobenius 15796
_FpXQ_pow 15372
_FpX_sqr 13160
FpX_rescale 12964
FpXQ_trace 10263
gener_FpXQ 6413
FpXQ_matrix_pow 6210
_FpX_add 4858
FpX_resultant 4489
FpV_roots_to_pol 4090
bounded_order 3930
FpX_digits 3416
FpXQ_charpoly 2879
FpXQ_minpoly 2878
FpX_matFrobenius 2451
_FpXQ_rand 2425
FpV_inv 2423
FpXQ_issquare 2199
FpXQ_sqrtn 2161
FpX_is_squarefree 2121
FpXQ_autsum_mul 1933
FpX_invBarrett 1564
FpX_invBarrett_basecase 1510
FpX_fromdigits 1449
FpXQ_sqrt 1366
gener_FpXQ_i 1352
gener_FpXQ_local 1337
FpX_Fp_sub_shallow 1319
get_FpXQ_star 1271
Fq_log 1253
FpXQ_autsum_sqr 998
FpXQ_autsum 984
FpX_addmulmul 914
_FpXQ_easylog 889
Z_to_FpX 870
FpX_halve 728
FpX_chinese_coprime 665
FpXQ_autpowers 539
FpXQ_autpow_sqr 534
FpXQ_autpow 506
FpXM_FpX_mul2 453
FpX_halfgcd 347
Fp_red_FpX 338
FpX_halfgcd_i 303
FpXC_FpXQV_eval 294
FpX_halfgcd_basecase 156
FpXM_mul2 151
FpX_halfgcd_split 147
FpX_FpXM_qmul 147
FpXM_FpXQV_eval 119
FpXQM_autsum_mul 119
FpXQM_autsum_sqr 84
FpX_invBarrett_Newton 46
FpXQM_autsum 42
FpXQ_order 36
Fp_neg_FpX 22
_FpXQ_zero 16
FpX_disc 14
FpXQ_conjvec 8
FpXQ_autpow_mul 7
FpX_extgcd_halfgcd 4
matid2_FpXM 4
FpXQ_norm 1
FpX_Fp_add_shallow 0
FpX_gcd_check 0
FqV_inv 0
famat_Z_gcd 0
FpX_powu 0

Generated by: LCOV version 1.9