From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 100195 invoked by alias); 5 Nov 2019 10:25:29 -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 100186 invoked by uid 89); 5 Nov 2019 10:25:29 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-2.9 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=3.3.1 spammy=apps X-HELO: us-smtp-1.mimecast.com Received: from us-smtp-delivery-1.mimecast.com (HELO us-smtp-1.mimecast.com) (205.139.110.120) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 05 Nov 2019 10:25:28 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1572949526; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=xn91QW8miu1ZxqQg4pIh1ySstCsjOA9vlDVvMchlsAQ=; b=h7bk3y68XWHV1LeTuWwvnlzXkVF7YAvsROE3NWGHBBRZkh4Jj+KNagYtveETd3thWdK6Cg +tdOfaMRP+27u5z60rA9Mo98BYZIOb3zWTudqR98pS3wKL1qwlTuRmhXlCwaa/omFK3T/z eBnW3wDYxjiAVJl8j54IPyO9DE+wQ3o= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-278-iSkphktXNCm1Lwdy6yiZKQ-1; Tue, 05 Nov 2019 05:25:23 -0500 Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 40DF3107ACC2; Tue, 5 Nov 2019 10:25:22 +0000 (UTC) Received: from redhat.com (ovpn-116-53.phx2.redhat.com [10.3.116.53]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 130041A7E2; Tue, 5 Nov 2019 10:25:21 +0000 (UTC) Received: from fche by redhat.com with local (Exim 4.92) (envelope-from ) id 1iRw1X-0005l0-Ri; Tue, 05 Nov 2019 05:25:19 -0500 Date: Tue, 05 Nov 2019 10:25:00 -0000 From: "Frank Ch. Eigler" To: Simon Marchi Cc: Aaron Merey , Tom Tromey , Christian Biesinger via gdb-patches , Christian Biesinger Subject: Re: [RFC PATCH] Support debuginfo and source file fetching via debuginfo server Message-ID: <20191105102519.GA18724@redhat.com> References: <87pnj6dl3k.fsf@tromey.com> <87sgn71ji6.fsf@tromey.com> <87lfsye5l5.fsf@redhat.com> <87bltrelab.fsf@redhat.com> <20191104162616.GA13319@redhat.com> <6f3fb81a-09ef-ab07-eef4-0460181bcaa0@simark.ca> MIME-Version: 1.0 In-Reply-To: <6f3fb81a-09ef-ab07-eef4-0460181bcaa0@simark.ca> User-Agent: Mutt/1.12.0 (2019-05-25) X-Mimecast-Spam-Score: 0 Content-Type: text/plain; charset=WINDOWS-1252 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline X-SW-Source: 2019-11/txt/msg00116.txt.bz2 Hi - > Maybe a user_data void pointer would be useful, to be able to get some > context in the callback? In your case, with a single-threaded app with C++ lambda captured variables, you wouldn't need the library to do that. In a multithreaded app's case, __thread variables and the promise to call those functions back from the calling thread should again let one get context if required. > I am noticing that debuginfod calls don't have any "context" or "handle" > parameters, which could suggest that the state of the library (if there > is any) is kept as global variables. [...] It turns out it's the opposite: except for this callback function pointer, it's practically all local variables therefore multithread-safe. - FChE