From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 7706 invoked by alias); 22 Mar 2016 15:46:45 -0000 Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org Received: (qmail 7459 invoked by uid 89); 22 Mar 2016 15:46:44 -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,SPF_HELO_PASS,T_RP_MATCHES_RCVD autolearn=ham version=3.3.2 spammy=Hx-languages-length:1335, Yichao, yichao, registering 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 (AES256-GCM-SHA384 encrypted) ESMTPS; Tue, 22 Mar 2016 15:46:34 +0000 Received: from int-mx13.intmail.prod.int.phx2.redhat.com (int-mx13.intmail.prod.int.phx2.redhat.com [10.5.11.26]) by mx1.redhat.com (Postfix) with ESMTPS id 1B6FF64D04; Tue, 22 Mar 2016 15:46:33 +0000 (UTC) Received: from [127.0.0.1] (ovpn01.gateway.prod.ext.phx2.redhat.com [10.5.9.1]) by int-mx13.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id u2MFkV9V023843; Tue, 22 Mar 2016 11:46:32 -0400 Subject: Re: JIT debugging (Attach and speed) To: Yichao Yu , gdb@sourceware.org, Paul Pluzhnikov References: From: Pedro Alves Message-ID: <56F168D7.9050405@redhat.com> Date: Tue, 22 Mar 2016 15:46:00 -0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.6.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-SW-Source: 2016-03/txt/msg00024.txt.bz2 On 03/22/2016 02:55 PM, Yichao Yu wrote: > Hi, > > I've recently seen some issues when debugging julia JIT code with GDB. > Some of these might worth a bug report but I'd like to post here first > since the most blocking issue was discussed here a few years ago. > > 1. Registering JIT code to GDB is O(n^2) and this is very bad for > serious JIT users like julia. (I've seen 10k to 100k jit objects > generated in the test) > > The issue was discussed on this list ~2011[1] but it seems that the > issue is still there. I was also told that lldb 3.8 should support the > same JIT debugging interface without the O(n^2) slow down[2]. I re-read the 2011 discussion, and it seems like we had an idea for a fix: https://sourceware.org/ml/gdb/2011-01/msg00011.html Paul, did you ever manage to get that working? > > 2. JIT code registration on attach is broken. > > When I set a breakpoint on `jit_inferior_init`[3] (i.e. lauching > gdb with `gdb --args gdb -p `) which IIUC is what > responsible for walking the jit object list at init time, it seems > that the function is never called. > > (I haven't seen a bug report about this yet) Do you know whether this happens with 7.11 and master, and if so, would it be possible for you to git bisect the culprit? Thanks, Pedro Alves