From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm1-x330.google.com (mail-wm1-x330.google.com [IPv6:2a00:1450:4864:20::330]) by sourceware.org (Postfix) with ESMTPS id F34C83858C27 for ; Mon, 15 Mar 2021 09:50:52 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org F34C83858C27 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=embecosm.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=andrew.burgess@embecosm.com Received: by mail-wm1-x330.google.com with SMTP id g20so7720706wmk.3 for ; Mon, 15 Mar 2021 02:50:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=embecosm.com; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=O2M+/0YHGFRXMO5KPrh2j4+Pmc4JEXqz02C+2UCag3o=; b=DnsIxYzguON1Sg8JZjQK/snevxsHjP6pr34a8HfYEl1GVHL9n0eizBJEgoEfqqyeQP But4ZgX7OtzgT+SKQy07RNJP28Jr8iPUSgtKWyvQLtcdppQNh5SCGynAQkq9yhadKn5k KfrZuLIBbMWHFGDA/77sQcxvzcqBFSWImSw+FqhbMJwj97/SmTa8tuF9kiTkd+bOV0do THe/bySqThkMIgeqFavr8fbDJCrLSyDYqS4bOfStxijtC+1SspmE21S1y5WUzc2kZb14 HSmJuDxr1zmVUokXoHGNTObTZKufUeD1wqtOms+skXj7bi6r8J/C09lOWmY7OdJftB64 DXpw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=O2M+/0YHGFRXMO5KPrh2j4+Pmc4JEXqz02C+2UCag3o=; b=DxKrh3820X2ahOnCsQ+BP7xfikHjHCirZqvoHHDHBM+PVlBDPw2Kq9sYHafcU0JvE/ U5ZXQZOxVBUi1u8H/YXWFLyRV/9ipd8tXEBQonUiLA73o+1xshlZiJoCf3Uq+onMyRHC K9kPtU53RvAgWs8o/DfnGzdityrzOaJhT/kVPNZSF8k64odPN7J8OF3bMAaWafQ2kWPF qU8YF/CDnxlnDgfis3AE8eFHnPQc+K5jteIUA8YVibxEHnJT2P42P9m9JESG8PyyykZW g+u19AQo5p7q77lRit+Bjshwba2Sq/86Sm2TWiy86H/csq0DMxzDXV4bodWEG3CB8G1H 3wSA== X-Gm-Message-State: AOAM530nGR5uZe81A0uPBggxa5zcG0SGp12RMT5f9l49k3D8vOil8W1N 1hNumJzcFbQJOYGvcV1Fspufqg== X-Google-Smtp-Source: ABdhPJzgPzD9UsrBG4j8i/EQp8COgj/ZvngQlA3vWB5kVjHK6/jniNrSvtWF0OQY/EOPptMhNRZ4zw== X-Received: by 2002:a1c:2155:: with SMTP id h82mr25748677wmh.169.1615801851965; Mon, 15 Mar 2021 02:50:51 -0700 (PDT) Received: from localhost (host86-134-238-232.range86-134.btcentralplus.com. [86.134.238.232]) by smtp.gmail.com with ESMTPSA id x25sm14031612wmj.14.2021.03.15.02.50.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 15 Mar 2021 02:50:51 -0700 (PDT) Date: Mon, 15 Mar 2021 09:50:50 +0000 From: Andrew Burgess To: Felix Willgerodt Cc: gdb-patches@sourceware.org Subject: Re: [PATCH] gdb/fortran: Fix quad floating-point type for Intel compilers. Message-ID: <20210315095050.GA5520@embecosm.com> References: <20210312093521.1026996-1-felix.willgerodt@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210312093521.1026996-1-felix.willgerodt@intel.com> X-Operating-System: Linux/5.8.13-100.fc31.x86_64 (x86_64) X-Uptime: 09:50:13 up 3 days, 17:01, X-Editor: GNU Emacs [ http://www.gnu.org/software/emacs ] X-Spam-Status: No, score=-12.0 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP 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, 15 Mar 2021 09:50:54 -0000 * Felix Willgerodt via Gdb-patches [2021-03-12 10:35:21 +0100]: > Intel Fortran compilers emit the following DWARF for gdb.fortran/complex.c: > > 0x00000071: DW_TAG_base_type > DW_AT_name ("COMPLEX*32") > DW_AT_encoding (DW_ATE_complex_float) > DW_AT_byte_size (0x20) > > 0x00000078: DW_TAG_base_type > DW_AT_name ("REAL*16") > DW_AT_encoding (DW_ATE_float) > DW_AT_byte_size (0x10) > > This results in GDB not reading the right values, as it wrongly assumes the > default floatformat "floatformat_i387_ext" instead of > "floatformat_ia64_quad_little". > > gdb/ChangeLog: > 2021-03-08 Felix Willgerodt > > * i386-tdep.c (i386_floatformat_for_type): Add COMPLEX*32 and REAL*16. Thanks for doing this. LGTM. Andrew > --- > gdb/i386-tdep.c | 5 ++++- > 1 file changed, 4 insertions(+), 1 deletion(-) > > diff --git a/gdb/i386-tdep.c b/gdb/i386-tdep.c > index 4f8da924073..2649fad08f2 100644 > --- a/gdb/i386-tdep.c > +++ b/gdb/i386-tdep.c > @@ -8162,9 +8162,12 @@ i386_floatformat_for_type (struct gdbarch *gdbarch, > || strcmp (name, "_Float128") == 0 > || strcmp (name, "complex _Float128") == 0 > || strcmp (name, "complex(kind=16)") == 0 > + || strcmp (name, "complex*32") == 0 > + || strcmp (name, "COMPLEX*32") == 0 > || strcmp (name, "quad complex") == 0 > || strcmp (name, "real(kind=16)") == 0 > - || strcmp (name, "real*16") == 0) > + || strcmp (name, "real*16") == 0 > + || strcmp (name, "REAL*16") == 0) > return floatformats_ia64_quad; > > return default_floatformat_for_type (gdbarch, name, len); > -- > 2.25.4 > > Intel Deutschland GmbH > Registered Address: Am Campeon 10, 85579 Neubiberg, Germany > Tel: +49 89 99 8853-0, www.intel.de > Managing Directors: Christin Eisenschmid, Sharon Heck, Tiffany Doon Silva > Chairperson of the Supervisory Board: Nicole Lau > Registered Office: Munich > Commercial Register: Amtsgericht Muenchen HRB 186928 >