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 16912-212c0f0) Lines: 641 716 89.5 %
Date: 2014-10-20 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 98862403
addiispec 1079134258
adduispec 926042323
adduispec_offset 286366265
addumului 985752
affir 100203162
cmpiispec 1474225769
convi 327734
diviiexact 312983641
divis 24061
divis_rem 35296093
diviu_rem 108521358
diviuexact 304479520
diviuuexact 52920
divri 13529613
divri_with_gmp 3032313
divrr 74167530
divrr_with_gmp 14414066
dvmdii 530442916
equaliispec 21657134
floorr 371224
icopy_ef 7551590
incloop 17161474
incneg 5384
incpos 17147354
int_normalize 129895711
mantissa2nr 15336092
mpz2GEN 90230065
muliispec 1058446190
muliispec_mirror 54133593
muluispec 1171160996
muluui 75128
pari_gmp_free 3002
pari_gmp_realloc 0
pari_kernel_close 688
pari_kernel_init 720
red_montgomery 5321232
remi2n 7167913
resetloop 145468
roundr_up_ip 82355608
setloop 1464699
shiftispec 201943801
sqrispec 567204293
sqrispec_mirror 6678543
sqrtr_abs 11875017
sqrtremi 1395914
subiispec 1303723906
subiuspec 832655485
truncr 383169
umodiu 414868994
xmpn_copy 1658091
xmpn_mirror 166608740
xmpn_mirrorcopy 189972701
xmpn_zero 29321396

Generated by: LCOV version 1.9