QEMU User-Space Markers
QEMU has included support for SystemTap user-space markers since 2011. The QEMU user-space markers are enabled in current versions of Fedora and Red Hat Enterprise Linux 7. The markers allow SystemTap to probe various QEMU events such as when a guest VM enters or exits a system call and emulates USB operations. RPC and QEMU operations. You can list the available tapset probe points available for x86_64 with the following command:
stap -L 'qemu.system.x86_64.**'
If you are using QEMU to emulate other architectures, you can change the 'x86_64' in the above command. For example to look at probe points for aarch64 (armv8) QEMU emulator use the following command:
stap -L 'qemu.system.aarch64.**'
Using QEMU User-Space Markers
To use the QEMU user-space markers on Fedora you will need:
- Membership to the stapdev group (or root access)
Examples and Demonstrations of Markers
The SystemTap examples includes qemu_count.stp and qemu_io.stp scripts under the QEMU keyword.