From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 8C7933857BB4; Tue, 12 Jul 2022 09:15:48 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 8C7933857BB4 From: "ulrich.weigand at de dot ibm.com" To: gdb-prs@sourceware.org Subject: [Bug tdep/29247] [gdb, tdep] ../../gdb/ppc-sysv-tdep.c:1945: internal-error: ppc64_sysv_abi_return_value: Assertion `ok' failed Date: Tue, 12 Jul 2022 09:15:48 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gdb X-Bugzilla-Component: tdep X-Bugzilla-Version: 12.1 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: ulrich.weigand at de dot ibm.com X-Bugzilla-Status: NEW X-Bugzilla-Resolution: X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: unassigned at sourceware dot org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://sourceware.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: gdb-prs@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-prs mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 12 Jul 2022 09:15:48 -0000 https://sourceware.org/bugzilla/show_bug.cgi?id=3D29247 --- Comment #19 from ulrich.weigand at de dot ibm.com --- For the final failing case, I think the problem is that for a struct with a single element, the ppc64_sysv_abi_push_param code may accidentally run into this code path: /* The ABI (version 1.9) specifies that structs containing a single floating-point value, at any level of nesting of single-member structs, are passed in floating-point registers. */ if (type->code () =3D=3D TYPE_CODE_STRUCT && type->num_fields () =3D=3D 1) { while (type->code () =3D=3D TYPE_CODE_STRUCT && type->num_fields () =3D=3D 1) type =3D check_typedef (type->field (0).type ()); if (type->code () =3D=3D TYPE_CODE_FLT) ppc64_sysv_abi_push_freg (gdbarch, type, val, argpos); } Now there's two problems with this: first of all, this code path should rea= lly only be used in ELFv1 - for ELFv2, this should be handled via the homogeneo= us aggregate rule instead. And secondly, when the path *is* executed (e.g. on big-endian targets), it also should handle IEEE long-double correctly. --=20 You are receiving this mail because: You are on the CC list for the bug.=