Re: Instructions for clock sync for tracing host/guest
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
- Subject: Re: Instructions for clock sync for tracing host/guest
- From: Steven Rostedt <rostedt@xxxxxxxxxxx>
- Date: Sun, 25 Apr 2021 14:29:35 -0400
- Cc: Joel Fernandes <joelaf@xxxxxxxxxx>, "Yordan Karadzhov (VMware)" <y.karadz@xxxxxxxxx>, Linux Trace Devel <linux-trace-devel@xxxxxxxxxxxxxxx>
- In-reply-to: <CAPpZLN5J8OYy2e87ns5tbxhd_O6Sh-r3_JJiX72iimEHn_dzrg@mail.gmail.com>
- References: <CAJWu+opJEtyXyhYnKL1iNzhfSCYRZN4PD50igckVvQV8416HEQ@mail.gmail.com> <CAPpZLN7=e+TL5WY7RKAo9Hm6AJGDygneqUWwoNnZexx+=KrxsQ@mail.gmail.com> <CAJWu+op2bU+-z6W_+XB0v2g__oGXj8Be2WWDg36E9uaCjNp+HA@mail.gmail.com> <CAJWu+orm+tm3C=MSF=p9eC1qgfE_pXzA2B0CiXgVXFemVRiVtA@mail.gmail.com> <CAJWu+opzT20OprG-8L_Lvv2DaJzF-ROaKnEWX8wjrbagPpwVzA@mail.gmail.com> <CAJWu+oqJk+BE2q=CjtAZJko-kJCS0Kyqwor_FVM3fu-X-rRRkg@mail.gmail.com> <20210422153845.3e6e9304@gandalf.local.home> <CAJWu+ooTVfprhd49__0H_61Fz_rSQA53n-VM6e1eEr8cTZ5aYQ@mail.gmail.com> <20210422154830.52f3e4f5@gandalf.local.home> <CAJWu+oqYWv5OHTLrC+oa7Y+LOe7AHumhtyVP8TC2LkK2=_JjPA@mail.gmail.com> <20210422160313.2eee1f77@gandalf.local.home> <CAJWu+ooZ9UptDBdii7dj=ui7dhiseOqZJE1CqMhP-Zy98QueXA@mail.gmail.com> <CAJWu+opsWVBDA8R-wVhhn2G_6h1LsMwzRDE=gMruZpFG+AH5zQ@mail.gmail.com> <CAJWu+oo8W9TVexZhhOs4P-DW1bH5DSjAzuV8QZMxvt9XHbRnJg@mail.gmail.com> <CAPpZLN5J8OYy2e87ns5tbxhd_O6Sh-r3_JJiX72iimEHn_dzrg@mail.gmail.com>
On Fri, 23 Apr 2021 11:16:50 +0300
Tzvetomir Stoyanov <tz.stoyanov@xxxxxxxxx> wrote:
> Currently we collect that information from quemu, is there a way to
> get it from crosvm ? If yes, a crosvm support can be implemented in
> trace-cmd. But as I said, it is not mandatory to have it for the
> trace, I can send you a patch next week addressing this gap in the
> implementation.
I think we should be able to get the above information during the KVM
timesync logic. The host can enable KVM events (specifically
kvm_entry), and that should give use the pids.
# trace-cmd record -e kvm_entry ssh guest taskset -c 0 ls \; taskset -c 1 cat /etc/passwd
# trace-cmd report
[..]
<...>-129042 [004]1122452427093922: kvm_entry: vcpu 0
<...>-129043 [005]1122452427148178: kvm_entry: vcpu 1
<...>-129042 [004]1122452427150380: kvm_entry: vcpu 0
<...>-129043 [005]1122452427201498: kvm_entry: vcpu 1
There, I see the guest vcpu 0 is controlled by the host thread with pid
129042 and vcpu 1 is controlled by host thread pid 129043.
-- Steve
[Index of Archives]
[Linux USB Development]
[Linux USB Development]
[Linux Audio Users]
[Yosemite Hiking]
[Linux Kernel]
[Linux SCSI]