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 to exceed 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 - basemath - ifactor1.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.16.2 lcov report (development 29420-55f63b8cfe) Lines: 1578 1918 82.3 %
Date: 2024-07-03 09:03:24 Functions: 93 107 86.9 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
COPY 0
ECM_alloc 72
ECM_init 72
ECM_loop 109
FpE_add_i 8391380
INIT 45561
SHALLOWCOPY 0
STORE 951105
STOREi 50133
STOREu 900820
ZV_aff 27339
Z_ECM 0
Z_factor 9624499
Z_factor_limit 45188
Z_factor_until 98
Z_issmooth 0
Z_issmooth_fact 178680
Z_pollardbrent 0
absZ_factor 3335315
absZ_factor_limit 289988
absZ_factor_limit_strict 888553
aux_end 145292
check_res 3926926
core 709162
coreu 61931
coreu_fact 61931
ecm_elladd 245357
ecm_elladd0 251467
ecm_elladd2 7485
elldouble 42413
ellfacteur 2434
ellmult 27240
factorint 10290
factoru 3809461
factoru_sign 20535536
get_rule 217707
ifac_GC 0
ifac_check 0
ifac_checkprime 9557
ifac_core 323
ifac_crack 4936
ifac_decomp 2627
ifac_defrag 14
ifac_delete 40356
ifac_divide 9126
ifac_factor_dbg 0
ifac_factoru 988
ifac_find 14710
ifac_insert_multiplet 2471
ifac_ispowerful 7
ifac_isprime 29056
ifac_main 13720
ifac_moebius 211
ifac_moebiusu 684
ifac_next 6009
ifac_print 0
ifac_read 682
ifac_realloc 0
ifac_resort 7
ifac_skip 308
ifac_sort_one 7
ifac_start 1527
ifac_start_hint 5142
ifac_whoiswho 4929
ifactor 9680017
ifactor_sign 14316188
is_357_power 2800417
is_kth_power 468489
is_pth_power 68165
ispowerful 1708
matsmalltrunc_append 98656546
matsmalltrunc_init 38385233
maxomegaoddu 2195
maxomegau 71584
moebius 57114
moebiusu 2514961
moebiusu_fact 54173
nextprime 126847
one_iter 28599353
pollardbrent 4229
pollardbrent_i 425
precprime 49
radicalu 0
rho_dbg 0
snextpr 4612605
special_primes 39299
squfof 3966
squfof_ambig 1891
tridiv_bound 877961
tridiv_boundu 11881988
u_forprime_next_fast 199303997
uis_357_power 2366440
uis_357_powermod 2421206
uis_357_powermod_32bit_1 14203
uis_357_powermod_32bit_2 815
uisprime_nosmall 18763
unextprime 1232006
unextprime_overflow 1094746
update_pow 944
uprecprime 32
vecfactoroddu 0
vecfactoroddu_i 2195
vecfactorsquarefreeu 7014
vecfactorsquarefreeu_coprime 32575
vecfactoru 0
vecfactoru_i 31918
vecsquarefreeu 49

Generated by: LCOV version 1.16