mailing list of musl libc
 help / color / mirror / code / Atom feed
From: James Gregurich <bayoubengal@mac.com>
To: musl@lists.openwall.com
Subject: Re: mistake in powerpc clone.s?
Date: Fri, 27 Dec 2013 16:34:30 -0600	[thread overview]
Message-ID: <7F719E8E-5B66-4A9A-AB4C-8505740090C4@mac.com> (raw)
In-Reply-To: <FB9D99E4-2058-4D66-A618-5A04444840F0@mac.com>

[-- Attachment #1: Type: text/plain, Size: 2128 bytes --]

a followup…


GDB log example.  this is what one typically sees. I edited out the private source code info. A message like that can easily send one chasing wild geese when he is hunting for a fault.
 

(gdb) bt
#0  c::f (this=0x0, dmxData=0x19cea20 "")
    at <source location>
#1  0x0182e5e0 in c::f (this=0x1a1e860, 
    enabledPorts=0x48015cb8)
    at <source location>
#2  0x0182e4c0 in c::f (this=<optimized out>)
    at <source location>
#3  0x0181fdd8 in c::f (this=<optimized out>)
    at <source location>
#4  0x0181faf4 in c::f (arg=0x1a1e860)
    at <source location>
#5  0x0190ff20 in start (p=0x48015d40) at src/thread/pthread_create.c:104
#6  0x01922e54 in clone ()
Backtrace stopped: frame did not save the PC
(gdb) 




On Dec 26, 2013, at 9:45 PM, James Gregurich <bayoubengal@mac.com> wrote:

> If you want me to try a patch, let me know.
> 
> BTW: I have an actual crash in my app that appears to be a stack corruption. I was following up on that message to see if it was relevant to the crash.
> 
> -James
> 
> 
> On Dec 26, 2013, at 9:42 PM, Rich Felker <dalias@aerifal.cx> wrote:
> 
>> On Thu, Dec 26, 2013 at 09:13:59PM -0600, James Gregurich wrote:
>>> 
>>> 
>>> When I debug my app in gdb, I consistently get “Backtrace stopped:
>>> previous frame inner to this frame (corrupt stack?)” at the lower
>>> end of the backtrace. I set break points at each function in the
>>> back trace and that message persists up to the __clone() invocation.
>>> until that line that I pointed out, the backtrace is normal. Once
>>> that instruction is executed, the backtrace is permanently broken
>>> for that thread.
>> 
>> In the backtrace for a thread other than the main thread, it's normal
>> and expected for the backtrace to end at __clone; it's where the
>> thread started. The "corrupt stack" message is unwanted (musl should
>> be arranging for the frame pointer to be zero so that debuggers
>> recognize that there's nothing else on the stack, and maybe this needs
>> fixing) but I don't think it's necessarily indicative of any bug.
>> 
>> Rich
> 


[-- Attachment #2: Type: text/html, Size: 3916 bytes --]

      reply	other threads:[~2013-12-27 22:34 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-12-26 22:08 James Gregurich
2013-12-27  1:57 ` John Spencer
2013-12-27  3:13   ` James Gregurich
2013-12-27  3:42     ` Rich Felker
2013-12-27  3:45       ` James Gregurich
2013-12-27 22:34         ` James Gregurich [this message]

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=7F719E8E-5B66-4A9A-AB4C-8505740090C4@mac.com \
    --to=bayoubengal@mac.com \
    --cc=musl@lists.openwall.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.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/musl/

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 NNTP newsgroup(s).