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-bordeaux.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.10.0 lcov report (development 20277-2bd9113) Lines: 639 716 89.2 %
Date: 2017-02-21 05:49:51 Functions: 53 54 98.1 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
GEN2mpz 238065583
addiispec 1482743087
adduispec 1123745872
adduispec_offset 319320372
addumului 759734
affir 106227630
cmpiispec 1816222578
convi 493319
diviiexact 247452914
divis 267420
divis_rem 29814860
diviu_rem 126805883
diviuexact 262060749
diviuuexact 532396
divri 17082123
divri_with_gmp 3211465
divrr 84089358
divrr_with_gmp 32948528
dvmdii 813672570
equaliispec 55579491
floorr 459891
icopy_ef 14656584
incloop 32933213
incneg 6188
incpos 32923419
int_normalize 145509524
mantissa2nr 22373760
mpz2GEN 228948250
muliispec 2046008967
muliispec_mirror 63492915
muluispec 2107244331
muluui 554604
pari_gmp_free 204585
pari_gmp_realloc 0
pari_kernel_close 1324
pari_kernel_init 816
red_montgomery 6692859
remi2n 10228916
resetloop 156748
roundr_up_ip 267200999
setloop 2445759
shiftispec 332254300
sqrispec 681251436
sqrispec_mirror 4944422
sqrtr_abs 21897909
sqrtremi 2679291
subiispec 1420583838
subiuspec 790007734
truncr 1500031
umodiu 780365508
xmpn_copy 1259372
xmpn_mirror 186253769
xmpn_mirrorcopy 278580070
xmpn_zero 58057902

Generated by: LCOV version 1.11