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 21351-66b5338) Lines: 639 716 89.2 %
Date: 2017-11-22 06:21:08 Functions: 53 54 98.1 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
pari_gmp_realloc 0
pari_kernel_close 900
pari_kernel_init 900
incneg 6268
resetloop 170732
pari_gmp_free 297402
floorr 467134
divis 489059
diviuuexact 528565
muluui 550773
addumului 840696
convi 848822
truncr 1599061
xmpn_copy 1675365
setloop 2496389
divri_with_gmp 3313666
sqrtremi 3340368
sqrispec_mirror 5311357
red_montgomery 11981509
icopy_ef 14322995
remi2n 17858864
divri 21856302
sqrtr_abs 23156153
mantissa2nr 24941892
divis_rem 31509185
divrr_with_gmp 35170764
muliispec_mirror 61441834
xmpn_zero 61640583
incpos 66674069
incloop 66706067
divrr 89150918
int_normalize 89506388
equaliispec 100907391
affir 117847551
diviu_rem 126542948
xmpn_mirror 194938223
mpz2GEN 247837914
diviiexact 254620049
adduispec_offset 255516693
GEN2mpz 259609695
diviuexact 271100259
xmpn_mirrorcopy 284255263
roundr_up_ip 298085642
shiftispec 391432441
sqrispec 790781889
subiuspec 831886657
umodiu 922055289
dvmdii 973956860
adduispec 1146912796
addiispec 1631965527
subiispec 1676892409
cmpiispec 2083602053
muliispec 2291235572
muluispec 2341427246

Generated by: LCOV version 1.11