HP Caliper Advisor Rule Writer Guide
• IO_ADVICE (advice about any I/O issues)
• SYSTEM_ADVICE (advice about system calls, system resources,
process management, and so forth)
description
A one-sentence description of the performance focus of the analysis
rule.
A string value or None.
improvement
Detailed guidance on what to try that might improve the
application’s performance in this area.
A string value or None.
measurement
A specific recommendation of what additional measurement(s)
would help to analyze a potential performance problem.
A string value or None.
explanation
A detailed explanation of this performance problem area.
A string value or None.
The index value is used to order rules based on their relative importance. It is usually
calculated by a rule based on the metric values it analyzes rather than being a fixed
value. It is not the amount of improvement that will be gained if the user follows the
advice, although it is related to it. The value must also factor in how likely it is that this
advice applies to the application being measured and that the bottleneck can be reduced.
For example, assume that performance data shows that 23.5% of the CPU cycles are
consumed by data cache misses. This would be the upper bound of speedup that could
be achieved if all data cache misses were gone, but this will never happen. Depending
on the nature of the advice, it might be possible to eliminate only a fraction of these
lost cycles, and the rule must take this into account when computing the index value.
All four of the advice strings are optional, but at least one must be present. “Null”
advice (advice with none of the advice strings) is discarded by the Advisor.
It might not be possible to include all four sections (the advice strings) in any one rule,
but the more information and guidance that a rule can give the user, the better.
Missing sections are passed to advice() as the None value, and the argument list can
be truncated if the final values are None.
The Advisor controls most of the formatting of the four text strings. In general, text
longer than 62 characters is wrapped at word boundaries, with any white space at the
beginning of a line discarded. If a “word” is too long, then it is split every 62 characters.
The Advisor honors embedded newline characters (\n) by breaking the line there and
not discarding any following white space. This allows a rule to produce indented lists.
Portions of the advice text (such as the names of the hot functions) can be dynamically
generated with application-specific information.
54 HP Caliper Advisor Advice Function