Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Tom Tromey <tromey@redhat.com>
To: Sergio Durigan Junior <sergiodj@redhat.com>
Cc: gdb-patches@sourceware.org
Subject: Re: [RFC] Make static tracepoint with markers more OO
Date: Fri, 13 Jan 2012 15:46:00 -0000	[thread overview]
Message-ID: <m3d3any5r0.fsf@fleche.redhat.com> (raw)
In-Reply-To: <m362gg9ro7.fsf@gmail.com> (Sergio Durigan Junior's message of	"Fri, 13 Jan 2012 02:01:44 -0200")

>>>>> "Sergio" == Sergio Durigan Junior <sergiodj@redhat.com> writes:

Sergio> I have been working on this patch, and I would like some comments from
Sergio> you guys.  It basically implements new methods inside breakpoint_ops in
Sergio> order to make static tracepoint with markers (`strace -m') more OO.

I think it is very nice.  Thanks.

At first I thought that maybe the overlap between the
create_sals_from_address and decode_linespec methods could be eliminated.
But, I think the first one has to compute the text that is used
when re-evaluating, but the latter just has to re-evaluate it, and so
the savings would be minimal.

My only comment on the design is that I wonder if the handling of
pending breakpoints is done at the right place.  I assume we don't
support pending static tracepoint (not even sure if that can mean
anything) -- but I think we probably do want to support pending
SystemTap probe breakpoints.

Sergio> +  if (arg && strncmp (arg, "-m", 2) == 0 && isblank (arg[2]))

I am not sure that isblank is ok to use.  gdb doesn't use it anywhere
else.  I suggest just using the original check.

Sergio> +  /* This method will be responsible for creating a breakpoint given its SALs.
Sergio> +     Usually, it just calls `create_breakpoints_sal' (for ordinary
Sergio> +     breakpoints).  However, there may be some special cases where we might
Sergio> +     need to do some tweaks, e.g., see
Sergio> +     `strace_marker_init_or_create_breakpoint_sal'.

This function doesn't exist :)

Tom


  parent reply	other threads:[~2012-01-13 15:36 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-01-13  7:24 Sergio Durigan Junior
2012-01-13 11:14 ` Pedro Alves
2012-01-13 17:24   ` Sergio Durigan Junior
2012-01-16 12:32     ` Pedro Alves
2012-01-13 15:46 ` Tom Tromey [this message]
2012-01-13 23:49   ` Sergio Durigan Junior
2012-01-16 17:03     ` Tom Tromey
2012-01-16 17:10       ` Sergio Durigan Junior
2012-01-16 17:19         ` Pedro Alves
2012-01-16 19:29           ` Sergio Durigan Junior

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=m3d3any5r0.fsf@fleche.redhat.com \
    --to=tromey@redhat.com \
    --cc=gdb-patches@sourceware.org \
    --cc=sergiodj@redhat.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