[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v6 01/22] instrument: Add documentation
From: |
Emilio G. Cota |
Subject: |
Re: [Qemu-devel] [PATCH v6 01/22] instrument: Add documentation |
Date: |
Tue, 19 Sep 2017 09:50:19 -0400 |
User-agent: |
Mutt/1.5.24 (2015-08-30) |
On Mon, Sep 18, 2017 at 18:42:55 +0100, Peter Maydell wrote:
> On 18 September 2017 at 18:09, Lluís Vilanova <address@hidden> wrote:
> > It also means we won't be able to "conditionally" instrument instructions
> > (e.g.,
> > based on their opcode, address range, etc.).
>
> You can still do that, it's just less efficient (your
> condition-check happens in the callout to the instrumentation
> plugin). We can add "filter" options later if we need them
> (which I would rather do than have translate-time callbacks).
My initial reaction to not having translation-time hooks was that it'd
be too slow. However, thinking about it a bit more I suspect it might
not matter much. Other tools such as Pin/DynamoRIO have these hooks,
and in their case it makes sense because one can choose to, instead of
having one callback per executed instruction, get a callback per
executed "trace" (a trace is a chain of TBs). Crucially, these tools do
not go through an intermediate IR, and as a result are about 10X faster
than QEMU.
Therefore, given that QEMU is comparatively slow, we might find that
per-executed-instruction callbacks do not end up slowing things down
significantly.
I like the idea of discussing an API alone, but there is value in having
an implementation to go with it, so that we can explore the perf
trade-offs involved. I was busy with other things the last 10 days or so,
but by the end of this week I hope I'll be able to share some
perf numbers on the per-TB vs. per-instruction callback issue.
Thanks,
Emilio
- [Qemu-devel] [PATCH v6 00/22] instrument: Add basic event instrumentation, Lluís Vilanova, 2017/09/13
- [Qemu-devel] [PATCH v6 01/22] instrument: Add documentation, Lluís Vilanova, 2017/09/13
- Re: [Qemu-devel] [PATCH v6 01/22] instrument: Add documentation, Peter Maydell, 2017/09/14
- Re: [Qemu-devel] [PATCH v6 01/22] instrument: Add documentation, Lluís Vilanova, 2017/09/15
- Re: [Qemu-devel] [PATCH v6 01/22] instrument: Add documentation, Peter Maydell, 2017/09/18
- Re: [Qemu-devel] [PATCH v6 01/22] instrument: Add documentation, Lluís Vilanova, 2017/09/18
- Re: [Qemu-devel] [PATCH v6 01/22] instrument: Add documentation, Peter Maydell, 2017/09/18
- Re: [Qemu-devel] [PATCH v6 01/22] instrument: Add documentation,
Emilio G. Cota <=
- Re: [Qemu-devel] [PATCH v6 01/22] instrument: Add documentation, Lluís Vilanova, 2017/09/25
- Re: [Qemu-devel] [PATCH v6 01/22] instrument: Add documentation, Emilio G. Cota, 2017/09/25
- Re: [Qemu-devel] [PATCH v6 01/22] instrument: Add documentation, Lluís Vilanova, 2017/09/26
- Re: [Qemu-devel] [PATCH v6 01/22] instrument: Add documentation, Lluís Vilanova, 2017/09/29
- Re: [Qemu-devel] [PATCH v6 01/22] instrument: Add documentation, Emilio G. Cota, 2017/09/29
- Re: [Qemu-devel] [PATCH v6 01/22] instrument: Add documentation, Lluís Vilanova, 2017/09/29
- Re: [Qemu-devel] [PATCH v6 01/22] instrument: Add documentation, Emilio G. Cota, 2017/09/30
- Re: [Qemu-devel] [PATCH v6 01/22] instrument: Add documentation, Peter Maydell, 2017/09/19
Re: [Qemu-devel] [PATCH v6 01/22] instrument: Add documentation, Stefan Hajnoczi, 2017/09/18
Re: [Qemu-devel] [PATCH v6 01/22] instrument: Add documentation, Stefan Hajnoczi, 2017/09/18