From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 24873 invoked by alias); 8 Nov 2017 09:56:55 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 24830 invoked by uid 89); 8 Nov 2017 09:56:52 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.9 required=5.0 tests=BAYES_00,RP_MATCHES_RCVD,SPF_HELO_PASS autolearn=ham version=3.3.2 spammy=HTo:D*mips.com, Hx-languages-length:1334, HTo:U*macro X-Spam-User: qpsmtpd, 2 recipients X-HELO: mx1.redhat.com Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Wed, 08 Nov 2017 09:56:51 +0000 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 771D5883A4; Wed, 8 Nov 2017 09:56:50 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 771D5883A4 Authentication-Results: ext-mx02.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx02.extmail.prod.ext.phx2.redhat.com; spf=fail smtp.mailfrom=palves@redhat.com Received: from [127.0.0.1] (ovpn04.gateway.prod.ext.ams2.redhat.com [10.39.146.4]) by smtp.corp.redhat.com (Postfix) with ESMTP id 3C15A5C550; Wed, 8 Nov 2017 09:56:44 +0000 (UTC) Subject: Re: [PATCH 0/3] Fix issues with writing Linux core PRSTATUS note on MIPS o32, n32 and n64 into core file To: "Maciej W. Rozycki" , Djordje Todorovic References: <74618d56-fa31-4cfe-329f-6a9078bac92b@rt-rk.com> <724f0bc9-6744-a915-d19d-77db7e9ce514@rt-rk.com> <64ad38a4-b8ae-912e-45d6-7048135ada2e@rt-rk.com> Cc: binutils@sourceware.org, gdb-patches@sourceware.org, "nemanja.popov@rt-rk.com" , petar.jovanovic@rt-rk.com, "Ananthakrishna Sowda (asowda)" , Nikola Prica From: Pedro Alves Message-ID: <9461a925-363c-cc90-0a01-298da75ae00e@redhat.com> Date: Wed, 08 Nov 2017 09:56:00 -0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.4.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit X-SW-Source: 2017-11/txt/msg00162.txt.bz2 On 11/07/2017 09:29 PM, Maciej W. Rozycki wrote: > On Mon, 30 Oct 2017, Maciej W. Rozycki wrote: > >>> Exactly the same situation I have reproduced on MIPS platforms. Have I >>> missed something? >> >> I'll see if I can reproduce it with the x86-64 target and that may help >> me understand why I don't see it with the MIPS one. > > So I have looked into it now and tracked down `libthread_db' rather > than GDB to be the component requiring PID retrieval from a core file > for TLS access to work, and then only before glibc commit c579f48edba8 > ("Remove cached PID/TID in clone"), which was first included in 2.25 > glibc release. > > Given I have been using recent glibc checkouts for MIPS verification I > avoided the requirement, but I was indeed able to reproduce it natively > with x86-64 and the system-supplied `libthread_db', and then with my > MIPS environment as well, once I went with my glibc build back to commit > c579f48edba8^. > > I will be adding a reference to said glibc commit when pushing your 2/3 > change. Interesting, hadn't realized libthread_db stopped requiring this. I wonder whether it'd be a good idea to mention it in the code itself too, say, in proc-service.:ps_getpid. Thanks, Pedro Alves