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 16804-345a01c) Lines: 641 716 89.5 %
Date: 2014-09-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 98184279
addiispec 1060008524
adduispec 919469309
adduispec_offset 278084300
addumului 985880
affir 100266104
cmpiispec 1468141650
convi 349220
diviiexact 217407523
divis 24285
divis_rem 35345828
diviu_rem 108912363
diviuexact 208929742
diviuuexact 53196
divri 14343393
divri_with_gmp 3072049
divrr 74350825
divrr_with_gmp 14501205
dvmdii 520662982
equaliispec 22759554
floorr 376508
icopy_ef 7201876
incloop 17163877
incneg 5408
incpos 17149705
int_normalize 127429966
mantissa2nr 15203901
mpz2GEN 89547323
muliispec 1035118659
muliispec_mirror 54524066
muluispec 1168318369
muluui 75404
pari_gmp_free 2784
pari_gmp_realloc 0
pari_kernel_close 684
pari_kernel_init 696
red_montgomery 5314032
remi2n 7194374
resetloop 145484
roundr_up_ip 87320177
setloop 1464763
shiftispec 202916330
sqrispec 566941358
sqrispec_mirror 6700957
sqrtr_abs 11667278
sqrtremi 1396634
subiispec 1295293756
subiuspec 832754310
truncr 386998
umodiu 408070217
xmpn_copy 1659325
xmpn_mirror 167130160
xmpn_mirrorcopy 190911630
xmpn_zero 29240532

Generated by: LCOV version 1.9