Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Pedro Alves <palves@redhat.com>
To: Muhammad Waqas <mwaqas@codesourcery.com>
Cc: gdb-patches@sourceware.org
Subject: Re: [PATCH with testcase] Bug 11568 - delete thread-specific breakpoint on the thread exit
Date: Mon, 02 Sep 2013 10:24:00 -0000	[thread overview]
Message-ID: <5224675A.20104@redhat.com> (raw)
In-Reply-To: <52245E5D.2030806@codesourcery.com>

On 09/02/2013 10:46 AM, Muhammad Waqas wrote:
> On 09/02/2013 01:39 PM, Pedro Alves wrote:
>> Hmm.  I'm guessing the difference will be you don't have debug
>> info for you glibc.  Could you do
>>
>>  do make check RUNTESTFLAGS="thread-specific-bp.exp"
>>
>> and send the resulting gdb.log?
> 
> find gdb.log in attachment.

Alright, thanks.  That's indeed the difference:

Yours:

> (gdb) PASS: gdb.threads/thread-specific-bp.exp: All stop: continue to breakpoint: start> info threads
>   Id   Target Id         Frame
> * 2    Thread 0x2aaaab4af700 (LWP 5815) "thread-specific" start (arg=0x0) at ../.././../gdb/gdb/testsuite/gdb.threads/thread-specific-bp.c:23
>   1    Thread 0x2aaaab2ad700 (LWP 5811) "thread-specific" 0x00002aaaaacd9148 in pthread_join () from /lib/x86_64-linux-gnu/libpthread.so.0
> (gdb) PASS: gdb.threads/thread-specific-bp.exp: All stop: thread created

Mine:

> (gdb) PASS: gdb.threads/thread-specific-bp.exp: All stop: continue to breakpoint: start
> info threads
>   Id   Target Id         Frame
> * 2    Thread 0x7ffff7fca700 (LWP 16383) "thread-specific" start (arg=0x0) at ../../../src/gdb/testsuite/gdb.threads/thread-specific-bp.c:23
>   1    Thread 0x7ffff7fcb740 (LWP 16379) "thread-specific" 0x000000323dc08e60 in pthread_join (threadid=140737353918208, thread_return=0x0) at pthread_join.c:93
> (gdb) PASS: gdb.threads/thread-specific-bp.exp: All stop: thread created

I can tell because yours doesn't show the arguments to pthread_join.

So in your case the bug doesn't trigger because
set_current_sal_from_frame, called from print_stack_frame, does
nothing if the frame (in this case pthread_join's) doesn't have
a symtab:

void
set_current_sal_from_frame (struct frame_info *frame, int center)
{
  struct symtab_and_line sal;

  find_frame_sal (frame, &sal);
  if (sal.symtab)
    {
      if (center)
        sal.line = max (sal.line - get_lines_to_list () / 2, 1);
      set_current_source_symtab_and_line (&sal);
    }
}

-- 
Pedro Alves


  reply	other threads:[~2013-09-02 10:24 UTC|newest]

Thread overview: 36+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-07-29  7:29 Muhammad Waqas
2013-07-29  9:21 ` Yao Qi
2013-07-29 11:42   ` Muhammad Waqas
2013-07-29 14:18     ` Yao Qi
2013-07-30 10:34       ` Muhammad Waqas
2013-07-31  2:41         ` Yao Qi
2013-08-01 10:51           ` Pedro Alves
2013-08-01 10:59             ` Yao Qi
2013-08-01 11:27               ` Pedro Alves
2013-08-01 12:10                 ` Yao Qi
2013-08-01 11:57         ` Pedro Alves
2013-08-01 12:44           ` Muhammad Waqas
2013-08-02  9:45             ` Pedro Alves
2013-08-05 12:01               ` Muhammad Waqas
2013-08-05 13:57                 ` Tom Tromey
2013-08-06  6:12                   ` Muhammad Waqas
2013-08-22  9:42                     ` Muhammad Waqas
2013-08-22 17:14                       ` Pedro Alves
2013-08-23  5:31                         ` Muhammad Waqas
2013-08-27 11:31                         ` Muhammad Waqas
2013-08-27 19:02                           ` Pedro Alves
2013-08-27 19:06                             ` Pedro Alves
2013-08-28 12:26                             ` Muhammad Waqas
2013-08-30 16:28                               ` Pedro Alves
2013-09-02  4:06                                 ` Muhammad Waqas
2013-09-02  8:39                                   ` Pedro Alves
2013-09-02  9:46                                     ` Muhammad Waqas
2013-09-02 10:24                                       ` Pedro Alves [this message]
2013-09-02 10:32                                         ` Muhammad Waqas
2013-09-02 10:48                                           ` Pedro Alves
2013-09-02 16:46                               ` Pedro Alves
2013-09-02 16:52                                 ` [PATCH] PR gdb/11568 - delete thread-specific breakpoints on " Pedro Alves
2013-09-09 16:07                                   ` Tom Tromey
2013-09-17 19:36                                     ` Pedro Alves
2013-09-19 14:48                                       ` [COMMIT PATCH] Fix regressions caused by thread-specific breakpoint deletion. (was: Re: [PATCH] PR gdb/11568 - delete thread-specific breakpoints on thread exit) Pedro Alves
2013-08-28 12:26                             ` [PATCH with testcase] Bug 11568 - delete thread-specific breakpoint on the thread exit Muhammad Waqas

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=5224675A.20104@redhat.com \
    --to=palves@redhat.com \
    --cc=gdb-patches@sourceware.org \
    --cc=mwaqas@codesourcery.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