From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-qt1-x844.google.com (mail-qt1-x844.google.com [IPv6:2607:f8b0:4864:20::844]) by sourceware.org (Postfix) with ESMTPS id 95B3D3858D37 for ; Mon, 6 Jul 2020 20:14:24 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 95B3D3858D37 Received: by mail-qt1-x844.google.com with SMTP id w27so6992795qtb.7 for ; Mon, 06 Jul 2020 13:14:24 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=qqZC8sQie68Wg+8eM0ccRlx8hRrQToBoUnH4O5+bF4M=; b=RHwJ4dpPy/lUM8rbFrFJNq89PAKSnyNK6bKDk2tM+DwBwn7/v5O/1+vvkgHGnvHLjs mYVT3pmLWeDL359oZrq83jHrn81dMGcq/xANxTvK5p7aPEjhNYf0m/PhDjetr32Wl/LU Q9tnLhJjyvk4Oyw4hJGyvqYQbQD0PKrjza8EvuyBbmQSMcCRhkuIpimMjni0saXxUDip OITwLW/DCYCh2z/RsbxCv9+fJ5Tv5YrtFkxNxat6Uxv280dDG1rr5W4n9L3NmSzWeYxK oCWyh6KnvDAPRHb1MHNzRVFCgoXqUips6VHxm4J+PVL70M6tww+/4IaGHoWukU6iH1hw a8cw== X-Gm-Message-State: AOAM530oR/Q2fR0PIX5g+YcFOMh2Ftzf7nAr8tqbLELdAtCK1OYHswx1 RLAAIG6MBJdgKuZ29AiSo1md3Pgt37IarQlCPCuCGg== X-Google-Smtp-Source: ABdhPJxXlFKZuSicplnOQpfTxNRSTg9IzcpmmWGmROOyTmscx9a+o9TrQlh+KQeWY5utY8GT9ob6qpeUnziskX2PaJo= X-Received: by 2002:ac8:7a9a:: with SMTP id x26mr50486808qtr.161.1594066463927; Mon, 06 Jul 2020 13:14:23 -0700 (PDT) MIME-Version: 1.0 References: <20200701213225.14144-1-jon.turney@dronecode.org.uk> <20200701213225.14144-8-jon.turney@dronecode.org.uk> In-Reply-To: <20200701213225.14144-8-jon.turney@dronecode.org.uk> From: Christian Biesinger Date: Mon, 6 Jul 2020 15:13:47 -0500 Message-ID: Subject: Re: [PATCH 7/7] Add handling for 64-bit module addresses in Cygwin core dumps To: Jon Turney Cc: gdb-patches Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-17.5 required=5.0 tests=BAYES_00, DKIMWL_WL_MED, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, ENV_AND_HDR_SPF_MATCH, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP, USER_IN_DEF_DKIM_WL, USER_IN_DEF_SPF_WL autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 06 Jul 2020 20:14:25 -0000 On Wed, Jul 1, 2020 at 4:34 PM Jon Turney wrote: > --- a/bfd/elf.c > +++ b/bfd/elf.c > @@ -10185,10 +10185,19 @@ elfcore_grok_win32pstatus (bfd *abfd, Elf_Internal_Note *note) > break; > > case 3 /* NOTE_INFO_MODULE */: > - /* Make a ".module/xxxxxxxx" section. */ > + case 4 /* NOTE_INFO_MODULE64 */: It really seems like these should be actual constants, which would also make it easier to understand... > + /* Make a ".module/" section. */ > /* module_info.base_address */ > - base_addr = bfd_get_32 (abfd, note->descdata + 4); > - sprintf (buf, ".module/%08lx", (unsigned long) base_addr); > + if (type == 3) ...this if. > --- a/gdb/windows-tdep.c > +++ b/gdb/windows-tdep.c > + if (data_type == 3) /* NOTE_INFO_MODULE */ Same here.