Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: "emin ak" <eminak71@gmail.com>
To: pgilliam@us.ibm.com
Cc: gdb-patches@sourceware.org
Subject: Re: [patch] "single step" atomic instruction sequences as a whole.
Date: Thu, 09 Nov 2006 13:07:00 -0000	[thread overview]
Message-ID: <2cf1ee820611090506te252d4apd925e5847db130d1@mail.gmail.com> (raw)
In-Reply-To: <2cf1ee820609180459o3b2fb25fi7cd9d8d6ac867fd0@mail.gmail.com>

Mr Gilliam,

I'am very interested in one of your gdb patches about ""single step"
atomic instruction sequences as a whole". we have experienced serious
problems on atomic functions while debugging linux kernel and we have
found only your approach can solve the problem. I have applied it
againts latest cvs source but it is not working truly, it can detects
atomic inc. successfully but cant step over them and gives this error:
 'breakpoint.c:7730: internal-error: remove_single_step_breakpoints: Assertion
`single_step_breakpoints[0] != NULL' failed.'

Mr Gilliam, if you can kindly guide me (or give a clue) to overcome
this problem, I can reorganize this patch and resend it to community

Thank you very much for your time.

Best Regards.
Emin Ak

2006/9/18, emin ak <eminak71@gmail.com>:
> Hi All;
> Is there aynone can succesfully apply or care about this patch. I have
> the same problem with my powerpc.
> I have checked the latest cvs gdb and I have found this patch did'nt
> merge into mainline. Will it commit later?
> Thanks. Best Regards.
> Emin Ak
> >Sorry forgot the logs.
> >--------------------test function.
> >#include <stdio.h>
> >#define __KERNEL__
> >#include <asm/atomic.h>
> >
> >atomic_t i;
> >int main(void)
> >{
> >printf("atomic_step_test\n");
> >atomic_set(&i,5);
> >printf("i=%d\n",atomic_read(&i));
> >atomic_dec(&i);
> >printf("i=%d\n",atomic_read(&i));
> >
> >
> >}
> >----------- gdb logs-----------
> >Breakpoint 2, main () at test.c:8
> >8       printf("atomic_step_test\n");
> >(gdb) next
> >9       atomic_set(&i,5);
> >(gdb) next
> >10      printf("i=%d\n",atomic_read(&i));
> >(gdb) next
> >151                     :"=m" (v->counter), "=qm" (c)
> >(gdb) next
> >Stepping over an atomic sequence of instructions beginning at 0x10000484
> >breakpoint.c:7730: internal-error: remove_single_step_breakpoints:
> >Assertion `single_step_breakpoints[0] != NULL' failed.
> >A problem internal to GDB has been detected,
> >further debugging may prove unreliable.
> >Quit this debugging session? (y or n)
> >--------------------------
> >Regards.
> >Emre
> > Hello Mr Gilliam;
> > Firstly thank you very much for your patch about single stepping problem
> > on atomic instructions. In my opinion, this bug is very critical for
> > powerpc arch (especially while kernel debugging). We have experienced this
> > problem  with both with h/w probe (BDI2000) and KGDB while debugging
> > kernel. I have applied your patch to latest gdb (20060911 taken from cvs)
> > and after correctting some fail warnings and test it on a PPC8540. It can
> > successfullt detects 'lwarx' instruction but can't step over the loop and
> > a little moment later, it gives an error message like 'breakpoint.c:7730:
> > internal-error: remove_single_step_breakpoints: Assertion
> > `single_step_breakpoints[0] != NULL' failed.'
> > I have corrected some patch error, I dont know, maybe this is the reason
> > of the problem. Here is the output of gdb and my test program that include
> > atomic_dec function.
> > Where can be the problem? And thank alot again, because atomic functions
> > are everywhere on kernel waiting to cause infinite loops..
> > Regards.
> > Emre KARA
> >
> >
> >
>


  reply	other threads:[~2006-11-09 13:07 UTC|newest]

Thread overview: 44+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-09-18 11:59 emin ak
2006-11-09 13:07 ` emin ak [this message]
  -- strict thread matches above, loose matches on Subject: below --
2007-03-15 22:24 [patch] " Luis Machado
2007-04-10 20:40 ` Daniel Jacobowitz
2007-04-12 12:09   ` Luis Machado
2007-04-12 12:15     ` Daniel Jacobowitz
2007-04-12 12:54       ` Luis Machado
2007-04-12 12:58         ` Daniel Jacobowitz
2007-04-12 13:30           ` Luis Machado
2007-04-12 13:35             ` Daniel Jacobowitz
2007-04-12 14:58               ` Ulrich Weigand
2007-04-12 15:33                 ` Daniel Jacobowitz
2007-04-12 17:16                   ` Ulrich Weigand
2007-04-12 18:25                     ` Daniel Jacobowitz
2007-04-12 20:09                       ` Ulrich Weigand
2007-04-12 20:16                         ` Mark Kettenis
2007-04-12 20:43                           ` Ulrich Weigand
2007-04-14 15:20                             ` Mark Kettenis
2007-04-14 18:13                               ` Ulrich Weigand
2007-04-12 20:49                           ` Daniel Jacobowitz
2007-04-12 20:48                         ` Daniel Jacobowitz
2007-04-12 14:32     ` Ulrich Weigand
2007-04-12 14:47       ` Luis Machado
2007-04-12 15:00         ` Ulrich Weigand
2007-02-17  2:24 Luis Machado
2007-02-27 13:00 ` Emi SUZUKI
2007-02-27 13:17   ` Daniel Jacobowitz
2007-02-28  8:08     ` Emi SUZUKI
2007-02-28 11:46       ` Daniel Jacobowitz
2007-02-28 16:09         ` Luis Machado
2007-03-02 12:47           ` Emi SUZUKI
2007-03-06 11:00             ` Andreas Schwab
2007-03-06 12:24               ` Daniel Jacobowitz
2007-03-08  8:50                 ` Emi SUZUKI
2007-03-08 16:15                   ` Ulrich Weigand
2007-03-13  6:12                     ` SUZUKI Emi
2007-02-06 11:02 Luis Machado
2007-02-06 12:11 ` Emi SUZUKI
2007-02-07 13:10   ` Luis Machado
2007-02-08 13:00     ` Emi SUZUKI
2006-06-22 20:56 PAUL GILLIAM
2006-06-22 21:53 ` PAUL GILLIAM
2006-06-22 22:20   ` PAUL GILLIAM
2006-11-10 21:18 ` Daniel Jacobowitz

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=2cf1ee820611090506te252d4apd925e5847db130d1@mail.gmail.com \
    --to=eminak71@gmail.com \
    --cc=gdb-patches@sourceware.org \
    --cc=pgilliam@us.ibm.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