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 - kernel/gmp - mp.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.8.0 lcov report (development 17240-4611fa9) Lines: 641 716 89.5 %
Date: 2014-12-21 Functions: 53 54 98.1 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 421 533 79.0 %

Function Name Sort by function name Hit count Sort by hit count
GEN2mpz 110409376
addiispec 1174093182
adduispec 991737654
adduispec_offset 291432500
addumului 987620
affir 120434263
cmpiispec 1637277954
convi 348651
diviiexact 327040151
divis 36939
divis_rem 36796411
diviu_rem 111351010
diviuexact 317834781
diviuuexact 72723
divri 13688690
divri_with_gmp 3103858
divrr 88723555
divrr_with_gmp 15885758
dvmdii 566213631
equaliispec 27306777
floorr 358233
icopy_ef 10493466
incloop 17732289
incneg 5384
incpos 17718037
int_normalize 131718866
mantissa2nr 17097553
mpz2GEN 100916878
muliispec 1153674537
muliispec_mirror 54599694
muluispec 1307553145
muluui 94931
pari_gmp_free 2668
pari_gmp_realloc 0
pari_kernel_close 712
pari_kernel_init 724
red_montgomery 5321202
remi2n 8196325
resetloop 145468
roundr_up_ip 91680933
setloop 1475356
shiftispec 210439980
sqrispec 623265559
sqrispec_mirror 6707580
sqrtr_abs 12371228
sqrtremi 1402615
subiispec 1435339538
subiuspec 907411451
truncr 416316
umodiu 427014147
xmpn_copy 1679085
xmpn_mirror 187366337
xmpn_mirrorcopy 197441264
xmpn_zero 31360844

Generated by: LCOV version 1.9