public inbox for gdb-prs@sourceware.org
help / color / mirror / Atom feed
* [Bug tdep/17379] New: PowerPC: internal-error: value_of_register_lazy: Assertion `frame_id_p (get_frame_id (frame))' failed.
@ 2014-09-11 20:55 emachado at sourceware dot org
  2014-09-12  9:17 ` [Bug tdep/17379] " palves at redhat dot com
                   ` (5 more replies)
  0 siblings, 6 replies; 7+ messages in thread
From: emachado at sourceware dot org @ 2014-09-11 20:55 UTC (permalink / raw)
  To: gdb-prs

https://sourceware.org/bugzilla/show_bug.cgi?id=17379

            Bug ID: 17379
           Summary: PowerPC: internal-error: value_of_register_lazy:
                    Assertion `frame_id_p (get_frame_id (frame))' failed.
           Product: gdb
           Version: HEAD
            Status: NEW
          Severity: normal
          Priority: P2
         Component: tdep
          Assignee: emachado at sourceware dot org
          Reporter: emachado at sourceware dot org
                CC: uweigand at sourceware dot org

GDB throws this internal-error when debugging a piece of code in ppc64 (also
reproducible in ppc64le):

$ cat bug.S 
#include <ppc-asm.h>
FUNC_START(main)
        li      sp,0
        mtlr    sp
        blr
FUNC_END(main)

$ gcc -g bug.S -o bug

$ ~/gdb/binutils-gdb.git/build.orig/gdb/gdb ./bug 
GNU gdb (GDB) 7.8.50.20140911-cvs
Copyright (C) 2014 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "powerpc64-unknown-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from ./bug...done.
(gdb) run
Starting program: /home/emachado/gdb/bugs/bug 

Program received signal SIGSEGV, Segmentation fault.
0x0000000000000000 in ?? ()
(gdb) info registers 
../../gdb/findvar.c:290: internal-error: value_of_register_lazy: Assertion
`frame_id_p (get_frame_id (frame))' failed.
A problem internal to GDB has been detected,
further debugging may prove unreliable.
Quit this debugging session? (y or n) y

This is a bug, please report it.  For instructions, see:
<http://www.gnu.org/software/gdb/bugs/>.

../../gdb/findvar.c:290: internal-error: value_of_register_lazy: Assertion
`frame_id_p (get_frame_id (frame))' failed.
A problem internal to GDB has been detected,
further debugging may prove unreliable.
Create a core file of GDB? (y or n) n

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Bug tdep/17379] PowerPC: internal-error: value_of_register_lazy: Assertion `frame_id_p (get_frame_id (frame))' failed.
  2014-09-11 20:55 [Bug tdep/17379] New: PowerPC: internal-error: value_of_register_lazy: Assertion `frame_id_p (get_frame_id (frame))' failed emachado at sourceware dot org
@ 2014-09-12  9:17 ` palves at redhat dot com
  2014-09-12  9:28 ` uweigand at gcc dot gnu.org
                   ` (4 subsequent siblings)
  5 siblings, 0 replies; 7+ messages in thread
From: palves at redhat dot com @ 2014-09-12  9:17 UTC (permalink / raw)
  To: gdb-prs

https://sourceware.org/bugzilla/show_bug.cgi?id=17379

Pedro Alves <palves at redhat dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |palves at redhat dot com

--- Comment #1 from Pedro Alves <palves at redhat dot com> ---
A backtrace would be good.  If indeed the frame doesn't have a valid id, then
it'd be a bug in the unwinder.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Bug tdep/17379] PowerPC: internal-error: value_of_register_lazy: Assertion `frame_id_p (get_frame_id (frame))' failed.
  2014-09-11 20:55 [Bug tdep/17379] New: PowerPC: internal-error: value_of_register_lazy: Assertion `frame_id_p (get_frame_id (frame))' failed emachado at sourceware dot org
  2014-09-12  9:17 ` [Bug tdep/17379] " palves at redhat dot com
@ 2014-09-12  9:28 ` uweigand at gcc dot gnu.org
  2014-09-12 10:01 ` palves at redhat dot com
                   ` (3 subsequent siblings)
  5 siblings, 0 replies; 7+ messages in thread
From: uweigand at gcc dot gnu.org @ 2014-09-12  9:28 UTC (permalink / raw)
  To: gdb-prs

https://sourceware.org/bugzilla/show_bug.cgi?id=17379

Ulrich Weigand <uweigand at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |uweigand at gcc dot gnu.org

--- Comment #2 from Ulrich Weigand <uweigand at gcc dot gnu.org> ---
Hi Pedro, the problem was in rs6000_frame_cache, where a
read_memory_unsigned_integer would throw an exception if the stack is invalid. 
This exception was caught somewhere higher up in the frame unwinding logic, but
this lead to a situation where frame 0 was marked invalid, which the rest of
GDB doesn't really handle well.

Edjunior has already posted a patch to the list.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Bug tdep/17379] PowerPC: internal-error: value_of_register_lazy: Assertion `frame_id_p (get_frame_id (frame))' failed.
  2014-09-11 20:55 [Bug tdep/17379] New: PowerPC: internal-error: value_of_register_lazy: Assertion `frame_id_p (get_frame_id (frame))' failed emachado at sourceware dot org
  2014-09-12  9:17 ` [Bug tdep/17379] " palves at redhat dot com
  2014-09-12  9:28 ` uweigand at gcc dot gnu.org
@ 2014-09-12 10:01 ` palves at redhat dot com
  2014-09-12 12:29 ` cvs-commit at gcc dot gnu.org
                   ` (2 subsequent siblings)
  5 siblings, 0 replies; 7+ messages in thread
From: palves at redhat dot com @ 2014-09-12 10:01 UTC (permalink / raw)
  To: gdb-prs

https://sourceware.org/bugzilla/show_bug.cgi?id=17379

--- Comment #3 from Pedro Alves <palves at redhat dot com> ---
Ah, indeed, hadn't seen it yet:

 https://sourceware.org/ml/gdb-patches/2014-09/msg00377.html

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Bug tdep/17379] PowerPC: internal-error: value_of_register_lazy: Assertion `frame_id_p (get_frame_id (frame))' failed.
  2014-09-11 20:55 [Bug tdep/17379] New: PowerPC: internal-error: value_of_register_lazy: Assertion `frame_id_p (get_frame_id (frame))' failed emachado at sourceware dot org
                   ` (2 preceding siblings ...)
  2014-09-12 10:01 ` palves at redhat dot com
@ 2014-09-12 12:29 ` cvs-commit at gcc dot gnu.org
  2014-09-12 13:04 ` emachado at sourceware dot org
  2021-09-03 15:05 ` ovilewade9 at gmail dot com
  5 siblings, 0 replies; 7+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2014-09-12 12:29 UTC (permalink / raw)
  To: gdb-prs

https://sourceware.org/bugzilla/show_bug.cgi?id=17379

--- Comment #4 from cvs-commit at gcc dot gnu.org <cvs-commit at gcc dot gnu.org> ---
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "gdb and binutils".

The branch, master has been updated
       via  9d9bf2df89db515958b429a1aeb1db38884ba488 (commit)
      from  1cf2f1b045e9e647f6dfd28829ff4592c588dcb7 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=9d9bf2df89db515958b429a1aeb1db38884ba488

commit 9d9bf2df89db515958b429a1aeb1db38884ba488
Author: Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
Date:   Fri Sep 12 09:20:25 2014 -0300

    PR tdep/17379: Fix internal-error when stack pointer is invalid.

    The problem is that rs6000_frame_cache attempts to read the stack backchain
via
    read_memory_unsigned_integer, which throws an exception if the stack
pointer is
    invalid.  With this patch, it calls safe_read_memory_integer instead, which
    doesn't throw an exception and allows for safe handling of that situation.

    gdb/ChangeLog
    2014-09-12  Edjunior Barbosa Machado  <emachado@linux.vnet.ibm.com>
            Ulrich Weigand� <uweigand@de.ibm.com>

        PR tdep/17379
        * rs6000-tdep.c (rs6000_frame_cache): Use safe_read_memory_integer
        instead of read_memory_unsigned_integer.

    gdb/testcase/ChangeLog
    2014-09-12  Edjunior Barbosa Machado  <emachado@linux.vnet.ibm.com>

        PR tdep/17379
        * gdb.arch/powerpc-stackless.S: New file.
        * gdb.arch/powerpc-stackless.exp: New file.

-----------------------------------------------------------------------

Summary of changes:
 gdb/ChangeLog                                |    7 ++++
 gdb/rs6000-tdep.c                            |   11 +++++--
 gdb/testsuite/ChangeLog                      |    6 ++++
 gdb/testsuite/gdb.arch/powerpc-stackless.S   |   24 +++++++++++++++
 gdb/testsuite/gdb.arch/powerpc-stackless.exp |   42 ++++++++++++++++++++++++++
 5 files changed, 87 insertions(+), 3 deletions(-)
 create mode 100644 gdb/testsuite/gdb.arch/powerpc-stackless.S
 create mode 100644 gdb/testsuite/gdb.arch/powerpc-stackless.exp

-- 
You are receiving this mail because:
You are on the CC list for the bug.
>From gdb-prs-return-16462-listarch-gdb-prs=sources.redhat.com@sourceware.org Fri Sep 12 13:00:59 2014
Return-Path: <gdb-prs-return-16462-listarch-gdb-prs=sources.redhat.com@sourceware.org>
Delivered-To: listarch-gdb-prs@sources.redhat.com
Received: (qmail 21484 invoked by alias); 12 Sep 2014 13:00:59 -0000
Mailing-List: contact gdb-prs-help@sourceware.org; run by ezmlm
Precedence: bulk
List-Id: <gdb-prs.sourceware.org>
List-Subscribe: <mailto:gdb-prs-subscribe@sourceware.org>
List-Archive: <http://sourceware.org/ml/gdb-prs/>
List-Post: <mailto:gdb-prs@sourceware.org>
List-Help: <mailto:gdb-prs-help@sourceware.org>, <http://sourceware.org/lists.html#faqs>
Sender: gdb-prs-owner@sourceware.org
Delivered-To: mailing list gdb-prs@sourceware.org
Received: (qmail 21416 invoked by uid 48); 12 Sep 2014 13:00:59 -0000
From: "emachado at sourceware dot org" <sourceware-bugzilla@sourceware.org>
To: gdb-prs@sourceware.org
Subject: [Bug tdep/17379] PowerPC: internal-error: value_of_register_lazy:
 Assertion `frame_id_p (get_frame_id (frame))' failed.
Date: Fri, 12 Sep 2014 13:00:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gdb
X-Bugzilla-Component: tdep
X-Bugzilla-Version: HEAD
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: emachado at sourceware dot org
X-Bugzilla-Status: ASSIGNED
X-Bugzilla-Priority: P2
X-Bugzilla-Assigned-To: emachado at sourceware dot org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_status
Message-ID: <bug-17379-4717-E9OwFW2KXY@http.sourceware.org/bugzilla/>
In-Reply-To: <bug-17379-4717@http.sourceware.org/bugzilla/>
References: <bug-17379-4717@http.sourceware.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: 7bit
X-Bugzilla-URL: http://sourceware.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2014-q3/txt/msg00451.txt.bz2
Content-length: 384

https://sourceware.org/bugzilla/show_bug.cgi?id\x17379

Edjunior Machado <emachado at sourceware dot org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |ASSIGNED

--
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Bug tdep/17379] PowerPC: internal-error: value_of_register_lazy: Assertion `frame_id_p (get_frame_id (frame))' failed.
  2014-09-11 20:55 [Bug tdep/17379] New: PowerPC: internal-error: value_of_register_lazy: Assertion `frame_id_p (get_frame_id (frame))' failed emachado at sourceware dot org
                   ` (3 preceding siblings ...)
  2014-09-12 12:29 ` cvs-commit at gcc dot gnu.org
@ 2014-09-12 13:04 ` emachado at sourceware dot org
  2021-09-03 15:05 ` ovilewade9 at gmail dot com
  5 siblings, 0 replies; 7+ messages in thread
From: emachado at sourceware dot org @ 2014-09-12 13:04 UTC (permalink / raw)
  To: gdb-prs

https://sourceware.org/bugzilla/show_bug.cgi?id=17379

Edjunior Machado <emachado at sourceware dot org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
         Resolution|---                         |FIXED

--- Comment #5 from Edjunior Machado <emachado at sourceware dot org> ---
Marking this bugzilla as fixed.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Bug tdep/17379] PowerPC: internal-error: value_of_register_lazy: Assertion `frame_id_p (get_frame_id (frame))' failed.
  2014-09-11 20:55 [Bug tdep/17379] New: PowerPC: internal-error: value_of_register_lazy: Assertion `frame_id_p (get_frame_id (frame))' failed emachado at sourceware dot org
                   ` (4 preceding siblings ...)
  2014-09-12 13:04 ` emachado at sourceware dot org
@ 2021-09-03 15:05 ` ovilewade9 at gmail dot com
  5 siblings, 0 replies; 7+ messages in thread
From: ovilewade9 at gmail dot com @ 2021-09-03 15:05 UTC (permalink / raw)
  To: gdb-prs

https://sourceware.org/bugzilla/show_bug.cgi?id=17379

ovile009988 <ovilewade9 at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |ovilewade9 at gmail dot com

--- Comment #6 from ovile009988 <ovilewade9 at gmail dot com> ---
Best app for all windows users get http://alarmsinwindows10.com and see best
tips to look at.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2021-09-03 15:05 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-09-11 20:55 [Bug tdep/17379] New: PowerPC: internal-error: value_of_register_lazy: Assertion `frame_id_p (get_frame_id (frame))' failed emachado at sourceware dot org
2014-09-12  9:17 ` [Bug tdep/17379] " palves at redhat dot com
2014-09-12  9:28 ` uweigand at gcc dot gnu.org
2014-09-12 10:01 ` palves at redhat dot com
2014-09-12 12:29 ` cvs-commit at gcc dot gnu.org
2014-09-12 13:04 ` emachado at sourceware dot org
2021-09-03 15:05 ` ovilewade9 at gmail dot com

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).