mirror of
https://github.com/cloud-hypervisor/cloud-hypervisor.git
synced 2026-08-05 02:19:16 +00:00
tracing: Tracing infrastructure
Add a new feature "tracing" that enables tracing functionality via the "tracer" crate (sadly features and crates cannot share the same name.) Setup: tracer::start() The main functionality is a tracer::trace_scope()! macro that will add trace points for the duration of the scope. Tracing events are per thread. Finish: tracer::end() this will write the trace file (pretty printed JSON) to a file in the current directory. Signed-off-by: Rob Bradford <robert.bradford@intel.com>
This commit is contained in:
@@ -12,6 +12,7 @@ guest_debug = ["kvm"]
|
||||
kvm = ["hypervisor/kvm", "vfio-ioctls/kvm", "vm-device/kvm", "pci/kvm"]
|
||||
mshv = ["hypervisor/mshv", "vfio-ioctls/mshv", "vm-device/mshv", "pci/mshv"]
|
||||
tdx = ["arch/tdx", "hypervisor/tdx"]
|
||||
tracing = ["tracer/tracing"]
|
||||
|
||||
[dependencies]
|
||||
acpi_tables = { path = "../acpi_tables" }
|
||||
@@ -42,6 +43,7 @@ serde_json = "1.0.85"
|
||||
serial_buffer = { path = "../serial_buffer" }
|
||||
signal-hook = "0.3.14"
|
||||
thiserror = "1.0.35"
|
||||
tracer = { path = "../tracer" }
|
||||
uuid = "1.1.2"
|
||||
versionize = "0.1.6"
|
||||
versionize_derive = "0.1.4"
|
||||
|
||||
Reference in New Issue
Block a user