Skip to content
Commit f47716b7 authored by Kalesh Singh's avatar Kalesh Singh Committed by Steven Rostedt (VMware)
Browse files

tracing/histogram: Covert expr to const if both operands are constants



If both operands of a hist trigger expression are constants, convert the
expression to a constant. This optimization avoids having to perform the
same calculation multiple times and also saves on memory since the
merged constants are represented by a single struct hist_field instead
or multiple.

Link: https://lkml.kernel.org/r/20211025200852.3002369-6-kaleshsingh@google.com

Signed-off-by: default avatarKalesh Singh <kaleshsingh@google.com>
Suggested-by: default avatarSteven Rostedt <rostedt@goodmis.org>
Signed-off-by: default avatarSteven Rostedt (VMware) <rostedt@goodmis.org>
parent c5eac6ee
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