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 16624-25b9976) Lines: 639 713 89.6 %
Date: 2014-06-24 Functions: 53 54 98.1 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 424 533 79.5 %

Function Name Sort by function name Hit count Sort by hit count
GEN2mpz 52982655
addiispec 566460978
adduispec 444103992
adduispec_offset 136451564
addumului 625083
affir 59626836
cmpiispec 802326334
convi 176231
diviiexact 112770597
divis 12250
divis_rem 18827546
diviu_rem 73120893
diviuexact 106083380
diviuuexact 26598
divri 7796142
divri_with_gmp 1895095
divrr 41093457
divrr_with_gmp 6469245
dvmdii 293907829
equaliispec 11341575
floorr 359140
icopy_ef 4514800
incloop 10222027
incneg 2704
incpos 10214943
int_normalize 63466364
mantissa2nr 9406979
mpz2GEN 47187624
muliispec 661922447
muliispec_mirror 69755677
muluispec 680271307
muluui 37702
pari_gmp_free 1070
pari_gmp_realloc 0
pari_kernel_close 386
pari_kernel_init 418
red_montgomery 1680749
remi2n 474292
resetloop 72742
roundr_up_ip 52666862
setloop 732377
shiftispec 102327302
sqrispec 288760101
sqrispec_mirror 6809874
sqrtr_abs 6460425
sqrtremi 678999
subiispec 713249326
subiuspec 399858994
truncr 298183
umodiu 177550587
xmpn_copy 1178934
xmpn_mirror 144166063
xmpn_mirrorcopy 179197326
xmpn_zero 14824765

Generated by: LCOV version 1.9