From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 43498 invoked by alias); 10 Apr 2015 15:39:59 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Received: (qmail 43431 invoked by uid 48); 10 Apr 2015 15:39:55 -0000 From: "jakub at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug sanitizer/65479] sanitizer stack trace missing frames past #0 on powerpc64 Date: Fri, 10 Apr 2015 15:39:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: sanitizer X-Bugzilla-Version: 5.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: jakub at gcc dot gnu.org X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2015-04/txt/msg00864.txt.bz2 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65479 --- Comment #6 from Jakub Jelinek --- (In reply to Martin Sebor from comment #5) > Created attachment 35289 [details] > Test case demonstrating stability problem with backtrace_qsort. > > Attached is a demo program showing the stability bug in the backtrace_qsort > function. The output shows the result of the current implementation > (Unstable) and the expected result (Stable). A better test case wouldn't > rely on the knowledge of the line_compare function and instead arrange to > construct a DWARF line program with similar properties that would then cause > the backtrace line problem. I suspect that would take quite a bit of effort > to put together, especially if we wanted it to be reproducible across > targets. > > I plan to work on the fast unwinding but I don't expect it to be ready in > time for the 5.0 release. In the meantime, I'll post a patch to fix the > test failures and maintain stability to be considered for 5.0. That hints at a bug in the line_compare function, what it does is just bogus. Adding the idx field to struct line sounds IMHO like the right thing, and on 64-bit arches won't even eat any extra memory because there have been 32 bits of padding.