Commit 02cd183a authored by David BAELDE's avatar David BAELDE

More countfuns fun

parent a1424337
......@@ -289,6 +289,12 @@ for $fname (sort { $table{$b} <=> $table{$a} } keys %table) {
print "* There are $n functions with >=$threshold occurrences,\n";
printf(" together they account for %.2f%% of occurrences.\n",
open THR,">","countfuns_${suffix}_${threshold}nb.tex";
printf THR "$n";
close THR;
open THR,">","countfuns_${suffix}_${threshold}pc.tex";
printf THR "%.2f\\%%", 100*$sofar/$total;
close THR;
......@@ -298,15 +304,14 @@ for $fname (sort { $table{$b} <=> $table{$a} } keys %table) {
"* $n functions (out of $nbfuns) needed to cover 70% of occurrences.\n";
$percent = 100*$sofar/$total;
print DAT "$n $table{$fname} $percent\n";
printf DAT "$n $table{$fname} %.2f\n", 100*$sofar/$total;
if (grep { $fname eq $_ } @stdfuns) {
$percent = 100*$sofar_std/$total;
print STD "$n $table{$fname} $percent\n";
printf STD "$n $table{$fname} %.2f\n",100*$sofar_std/$total;
} else {
print NONSTD "$n $table{$fname}\n";
$locale_nbfuns = reverse join ',', unpack '(A3)*', reverse $nbfuns;
print TOTAL ("$locale_nbfuns");
printf COV "%.2f", 100*$sofar_std/$total;
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment