From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 804743854801; Fri, 17 Mar 2023 14:24:31 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 804743854801 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1679063071; bh=PcAc2Ldd0hXpXpt01hC8xwAjsuQPEEDqLrx88ur4+5E=; h=From:To:Subject:Date:In-Reply-To:References:From; b=t1hHxCcKcQMo6DyuTZssrQ4VwzPtXRnmvGB2ztG25OnXPbCcaHW14HExzlRfcnhGY l+c+vEWEkQQQ04LhxQgCw5FRU+H7ixcBNrxtdF61/6AAyp2l4JEnsdUN694Wc5irwY yygescBEojj2dRVax5i+rRjL32w85vS3rk7HY7/I= From: "tromey at sourceware dot org" To: gdb-prs@sourceware.org Subject: [Bug tdep/19797] Unsupported powerpc bfd arch/machine variants Date: Fri, 17 Mar 2023 14:24:31 +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: HEAD X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: tromey at sourceware dot org 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 List-Id: https://sourceware.org/bugzilla/show_bug.cgi?id=3D19797 --- Comment #10 from Tom Tromey --- For my file, a sufficiently old gdb (7.10) works (or at least -- it does not complain) but a newer one fails. It comes from this patch: commit 14b57c7c6a53c747a8819fed3da858eae4195a0e Author: Alan Modra Date: Tue Jun 7 22:04:38 2016 +0930 PowerPC VLE I'm not a PPC expert so I don't know whether gdb should be trying to handle ever bfd_mach_* value, or if some fallback is appropriate instead. I do see that the logic in _bfd_elf_ppc_set_arch is a little strange in that the order of entries in the apuinfo can affect the result. Like in my file, the order is description data: 00 43 00 01 00 40 00 01 00 42 00 01=20 so it moves through the loop like: if (mach =3D=3D bfd_mach_ppc_titan) mach =3D bfd_mach_ppc_e500mc; if (mach =3D=3D 0) mach =3D bfd_mach_ppc_titan; ... so it ends up picking 'titan'. But if the entries were reordered, it would pick e500mc instead (which gdb also doesn't handle :-) --=20 You are receiving this mail because: You are on the CC list for the bug.=