From patchwork Tue Feb 14 11:00:49 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Willgerodt, Felix" X-Patchwork-Id: 64954 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 34E843858C39 for ; Tue, 14 Feb 2023 11:01:36 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 34E843858C39 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1676372496; bh=MKqERauzahlbqrN53IHq1DtSeZow4YolrsgBjQCbmwE=; h=To:Cc:Subject:Date:List-Id:List-Unsubscribe:List-Archive: List-Post:List-Help:List-Subscribe:From:Reply-To:From; b=OFJL4Ub8bqYOQJUyTe6vfeKK90gaVU5k3mbvDv6yKQJexUN7x/pNoKlINDInjjyfa AD71V9IhARiGiHbkN9I1rV7Qdy91qLWrNK6/YkGv+qBo3i4GcG2DJnY2uYkT1tVK+i NOi1yAruGG02+n0oNIdFR6l32LpNDD/qmzp8qszY= X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) by sourceware.org (Postfix) with ESMTPS id 16EC03858D33 for ; Tue, 14 Feb 2023 11:01:10 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 16EC03858D33 X-IronPort-AV: E=McAfee;i="6500,9779,10620"; a="417353084" X-IronPort-AV: E=Sophos;i="5.97,296,1669104000"; d="scan'208";a="417353084" Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by fmsmga105.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 14 Feb 2023 03:01:08 -0800 X-IronPort-AV: E=McAfee;i="6500,9779,10620"; a="778279214" X-IronPort-AV: E=Sophos;i="5.97,296,1669104000"; d="scan'208";a="778279214" Received: from mulfelix.iul.intel.com (HELO localhost) ([172.28.49.163]) by fmsmga002-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 14 Feb 2023 03:01:06 -0800 To: gdb-patches@sourceware.org Cc: Felix Willgerodt Subject: [PATCH 1/1] gdb, fortran: Fix quad floating-point type for ifort compiler. Date: Tue, 14 Feb 2023 12:00:49 +0100 Message-Id: <20230214110049.649769-1-felix.willgerodt@intel.com> X-Mailer: git-send-email 2.39.1 MIME-Version: 1.0 X-Spam-Status: No, score=-10.3 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, SPF_HELO_NONE, SPF_NONE, TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) 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-Patchwork-Original-From: Felix Willgerodt via Gdb-patches From: "Willgerodt, Felix" Reply-To: Felix Willgerodt Errors-To: gdb-patches-bounces+patchwork=sourceware.org@sourceware.org Sender: "Gdb-patches" I fixed this a while ago for ifx, one of the two Intel compilers, in 8d624a9d8050ca96e154215c7858ac5c2d8b0b19. Apparently I missed that the older ifort Intel compiler actually emits slightly different debug info again: 0x0000007a: DW_TAG_base_type DW_AT_byte_size (0x20) DW_AT_encoding (DW_ATE_complex_float) DW_AT_name ("COMPLEX(16)") 0x00000081: DW_TAG_base_type DW_AT_byte_size (0x10) DW_AT_encoding (DW_ATE_float) DW_AT_name ("REAL(16)") This fixes two failures in gdb.fortran/complex.exp with ifort. --- gdb/i386-tdep.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/gdb/i386-tdep.c b/gdb/i386-tdep.c index da4950ac259..acf22dba98d 100644 --- a/gdb/i386-tdep.c +++ b/gdb/i386-tdep.c @@ -8238,12 +8238,14 @@ 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(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 + || strcmp (name, "REAL(16)") == 0) return floatformats_ieee_quad; return default_floatformat_for_type (gdbarch, name, len);