Commit d8f0e31e authored by Geoff Simmons's avatar Geoff Simmons

Fix QP favg stat.

parent 41a1b027
......@@ -565,7 +565,7 @@ qp_stats(const struct qp_y * const restrict y,
if (fanout > stats->fmax)
stats->fmax = fanout;
stats->favg +=
(fanout - stats->favg) / ((stats->nodes - stats->terms) + 1.);
(fanout - stats->favg) / ((stats->nodes - stats->leaves));
for (int i = 0; i < popcount(y->bitmap); i++)
qp_stats(y->branch[i], strings, stats, depth);
......
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