[Bug runtime/10234] clean up aggregate hard-coded logic

fche at redhat dot com sourceware-bugzilla@sourceware.org
Tue Sep 13 18:53:00 GMT 2016


https://sourceware.org/bugzilla/show_bug.cgi?id=10234

--- Comment #4 from Frank Ch. Eigler <fche at redhat dot com> ---
One could measure some of the combinations.
In particular, compare the three options

 if (val > sd->max)  sd->max = val;
 if (sd->hist_ops & STAT_OP_MAX && val > sd->max)  sd->max = val;
 if (unlikely(sd->hist_ops & STAT_OP_MAX && val > sd->max))  sd->max = val;

for one or all of the aggregate variables.  That's a number of combinations to
test, but maybe with some #ifdef's and some shell script stap -D'ing, one can
get the computer to explore the whole space.

(Since it's unlikely we'll have a compile-time-only method ... like your #if 0
... unless we were to go to generated-code templates kind of like map-gen* etc.
for the various cartesian-product alternatives.)

-- 
You are receiving this mail because:
You are the assignee for the bug.


More information about the Systemtap mailing list