From: Keith Seitz <keiths@redhat.com>
To: Markus Metzger <markus.t.metzger@intel.com>, gdb-patches@sourceware.org
Subject: Re: [PATCH] gdb, btrace: support libipt v2.2 events
Date: Thu, 30 Apr 2026 11:11:36 -0700 [thread overview]
Message-ID: <790c23b4-af98-4877-872d-2c92e134f6ca@redhat.com> (raw)
In-Reply-To: <20260430112428.1537534-1-markus.t.metzger@intel.com>
Hi,
On 4/30/26 4:24 AM, Markus Metzger wrote:
> ---
> gdb/btrace.c | 53 ++++++++++++++++++++++++++++++++++++++++++++++++++++
> 1 file changed, 53 insertions(+)
There appears to be no commit message other than the (admittedly
rather complete) title?
I think a brief NEWS entry is warranted, too.
There is one tiny nit (below), but otherwise, I think you should approve
your patch. ;-)
Reviewed-By: Keith Seitz <keiths@redhat.com>
Keith
>
> diff --git a/gdb/btrace.c b/gdb/btrace.c
> index 6a8f0f549d1..f9c6f0e5b6a 100644
> --- a/gdb/btrace.c
> +++ b/gdb/btrace.c
> @@ -1597,6 +1597,59 @@ handle_pt_insn_events (struct btrace_thread_info *btinfo,
> break;
> }
> #endif /* defined (LIBIPT_VERSION >= 0x201) */
> +
> +#if (LIBIPT_VERSION >= 0x202)
> + case ptev_trig:
> + {
> + std::string aux_string = std::string (_("trig: trbv = "))
> + + hex_string (event.variant.trig.trbv);
> +
> + if (event.variant.trig.mult != 0)
> + aux_string += std::string (", mult");
> +
> + if (event.ip_suppressed == 0)
> + {
> + pc = event.variant.trig.ip;
> + aux_string += std::string (", ip = ") + hex_string (*pc);
> + }
> +
> + if (event.variant.trig.icnt != 0)
> + aux_string += std::string (", icnt = ")
> + + hex_string (event.variant.trig.icnt);
> +
> + handle_pt_aux_insn (btinfo, aux_string, pc);
> + break;
> + }
> +
> + case ptev_swintr:
> + {
> + std::string aux_string = std::string (_("swintr: vector = "))
> + + hex_string (event.variant.swintr.vector);
> +
> + if (event.ip_suppressed == 0)
> + {
> + pc = event.variant.swintr.ip;
> + aux_string += std::string (", ip = ") + hex_string (*pc);
> + }
> +
> + handle_pt_aux_insn (btinfo, aux_string, pc);
> + break;
> + }
> +
> + case ptev_syscall:
> + {
> + std::string aux_string = std::string (_("syscall"));
> +
> + if (event.ip_suppressed == 0)
> + {
> + pc = event.variant.syscall.ip;
> + aux_string += std::string (": ip = ") + hex_string (*pc);
> + }
> +
> + handle_pt_aux_insn (btinfo, aux_string, pc);
> + break;
> + }
> +#endif /* (LIBIPT_VERSION >= 0x202) */
Elsewhere in the file, this comment includes "defined".
> }
> }
> #endif /* defined (HAVE_PT_INSN_EVENT) */
next prev parent reply other threads:[~2026-04-30 18:12 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-04-30 11:24 Markus Metzger
2026-04-30 18:11 ` Keith Seitz [this message]
2026-05-01 16:39 ` Tom Tromey
2026-05-04 7:16 ` Metzger, Markus T
2026-05-04 16:08 ` Simon Marchi
2026-05-05 13:28 ` Tom Tromey
2026-05-08 5:07 ` Metzger, Markus T
2026-05-04 7:16 ` Metzger, Markus T
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=790c23b4-af98-4877-872d-2c92e134f6ca@redhat.com \
--to=keiths@redhat.com \
--cc=gdb-patches@sourceware.org \
--cc=markus.t.metzger@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox