Originally, we don't format the output of analyser well. It is hard to read the
result.
This patch make every entry of the result align with the corresponding title to
make it easier for users to read.
Without patch:
Event NR_Exit NR_Exit/Sec Time Consumed(cycles) Time Percentage
VMEXIT_INTERRUPT_WINDOW 78090 130.15 40 0.01
VMEXIT_CR_ACCESS 0 0.00 0 0.00
VMEXIT_APICV_ACCESS 0 0.00 0 0.00
VMEXIT_EXCEPTION_OR_NMI 0 0.00 0 0.00
VMEXIT_RDTSC 0 0.00 0 0.00
...
Vector Count NR_Exit/Sec
0x000000f0 82337 137.23
0x000000ef 247713 412.85
With patch:
Event NR_Exit NR_Exit/Sec Time Consumed(cycles) Time percentage
VMEXIT_APICV_WRITE 13352 22.25 14331304 0.00
VMEXIT_WRMSR 309085 515.14 241166212 0.02
VMEXIT_INTERRUPT_WINDOW 78090 130.15 76841734 0.01
...
Vector Count NR_Exit/Sec
0x000000f0 82337 137.23
0x000000ef 247713 412.85
Signed-off-by: Kaige Fu <kaige.fu@intel.com>
Reviewed-by: Eddie Dong <eddie.dong@intel.com>
Acked-by: Yan, Like <like.yan@intel.com>
Value of VMEXIT_XXX must have the same as TRACE_VMEXIT_XXX defined in
./hypervisor/include/debug/trace.h. This patch fix the events with wrong event id.
Fixes: 8a233ee (tools: acrntrace: Refactor vmexit_analyzer based on new trace format)
Signed-off-by: Kaige Fu <kaige.fu@intel.com>
Reviewed-by: Yan, Like <like.yan@intel.com>
We have TRACE_6C and TRACE_16STR API in hypervisor now. It's time to add support
for parsing data traced by both APIs.
Signed-off-by: Kaige Fu <kaige.fu@intel.com>
Reviewed-by: Yan, Like <like.yan@intel.com>
The trend is to focus on Python3 and deprecate Python2. This patch make all the
acrntrace related scripts as Python3 module.
- Add parentheses to all the print as Python3 required.
- Remove suffix L and long() Python3 has deprecated. Python3 will treat all
intergers as long.
- Replace has_key() with "key in .keys()" because has_key() has been deprecated.
- Other minor fixes.
Signed-off-by: Kaige Fu <kaige.fu@intel.com>
Reviewed-by: Geoffroy Van Cutsem <geoffroy.vancutsem@intel.com>
This analyzer is implemented in vmexit_analyze. This patch make it as independent
analyzer with an option "--irq"
Signed-off-by: Kaige Fu <kaige.fu@intel.com>
Reviewed-by: Yan, Like <like.yan@intel.com>
Reviewed-by: Geoffroy Van Cutsem <geoffroy.vancutsem@intel.com>
- Refactor vmexit_analyzer based on new trace format (raw data). We can get
the same output like original implementation.
- Remove irq related analysis. Will add it back with an option "--irq".
- Remove unused VMEXIT_EPT_VIOLATION_GVT
Signed-off-by: Kaige Fu <kaige.fu@intel.com>
Reviewed-by: Yan, Like <like.yan@intel.com>
Reviewed-by: Geoffroy Van Cutsem <geoffroy.vancutsem@intel.com>
As we may analyze multi-cases at the same time. It's better to store all the
analyzer in an array. Then we can traverse the array and exec all analyzer one
by one.
Signed-off-by: Kaige Fu <kaige.fu@intel.com>
Reviewed-by: Yan, Like <like.yan@intel.com>
Reviewed-by: Geoffroy Van Cutsem <geoffroy.vancutsem@intel.com>
Originally, acrntrace stores cpu frequency in output file and use it for time-based
analysis. Actually, we should use TSC frequency instead of cpu frequency.
This patch change to using TSC frequency for time-based analysis and introduce
an option "-f --frequency" to let user configure TSC frequency.
Signed-off-by: Kaige Fu <kaige.fu@intel.com>
Reviewed-by: Yan, Like <like.yan@intel.com>
Reviewed-by: Geoffroy Van Cutsem <geoffroy.vancutsem@intel.com>
acrntrace_format.py is used for parsing raw trace data to human-readable file on
given format. A sample format file for acrntrace predefined trace events is available
in tools/acrntrace/scripts/formats in acrn source tree.
Signed-off-by: Kaige Fu <kaige.fu@intel.com>
Reviewed-by: Yan, Like <like.yan@intel.com>
Reviewed-by: Geoffroy Van Cutsem <geoffroy.vancutsem@intel.com>
The tools directory is moved out of ./devicemodle, to be in parallel with
hypervisor, devicemodel and doc.
Signed-off-by: Yan, Like <like.yan@intel.com>