Debian Bug report logs - #1004504
Regression of -many on powerpc, ppc64

version graph

Package: binutils; Maintainer for binutils is Matthias Klose <[email protected]>; Source for binutils is src:binutils (PTS, buildd, popcon).

Affects: src:linux

Reported by: Ben Hutchings <[email protected]>

Date: Sat, 29 Jan 2022 17:45:02 UTC

Severity: important

Found in version binutils/2.37.90.20220123-2

Reply or subscribe to this bug.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to [email protected], Matthias Klose <[email protected]>:
Bug#1004504; Package binutils. (Sat, 29 Jan 2022 17:45:04 GMT) (full text, mbox, link).


Acknowledgement sent to Ben Hutchings <[email protected]>:
New Bug report received and forwarded. Copy sent to Matthias Klose <[email protected]>. (Sat, 29 Jan 2022 17:45:04 GMT) (full text, mbox, link).


Message #5 received at [email protected] (full text, mbox, reply):

From: Ben Hutchings <[email protected]>
To: Debian Bug Tracking System <[email protected]>
Subject: Regression of -many on powerpc, ppc64
Date: Sat, 29 Jan 2022 18:41:07 +0100
Package: binutils
Version: 2.37.90.20220123-2
Severity: important

Since the update from binutils 2.37 to this snapshot, linux no longer
builds for powerpc or ppc64 due to unrecognised instructions.

For ppc64, linux is built with the compiler options:

    -mtune=power7 -mcpu=power5 -mno-altivec -mno-vsx

so the generated assembly starts with ".machine power5".  But because
the kernel does need to conditionally use Altivec and other
extensions, it also uses the options:

    -Wa,-maltivec -Wa,-mpower4 -Wa,-many

This is rather strange but used to work.  It seems to have been
intentionally changed by commit b25f942e18d6 "PowerPC: ignore sticky
options for .machine" in binutils.  Can you find out whether there is
any possibility of this being reverted?

Ben.

-- System Information:
Debian Release: bookworm/sid
  APT prefers unstable-debug
  APT policy: (500, 'unstable-debug'), (500, 'oldstable-updates'), (500, 'unstable'), (500, 'oldstable'), (1, 'experimental')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 5.15.0-3-amd64 (SMP w/2 CPU threads)
Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8), LANGUAGE not set
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

Versions of packages binutils depends on:
ii  binutils-common            2.37.90.20220123-2
ii  binutils-x86-64-linux-gnu  2.37.90.20220123-2
ii  libbinutils                2.37.90.20220123-2

binutils recommends no packages.

Versions of packages binutils suggests:
ii  binutils-doc  2.37.90.20220123-2

-- debconf-show failed



Added indication that 1004504 affects src:linux Request was from Ben Hutchings <[email protected]> to [email protected]. (Sat, 29 Jan 2022 18:00:02 GMT) (full text, mbox, link).


Information forwarded to [email protected], Matthias Klose <[email protected]>:
Bug#1004504; Package binutils. (Sat, 29 Jan 2022 18:06:04 GMT) (full text, mbox, link).


Acknowledgement sent to Ben Hutchings <[email protected]>:
Extra info received and forwarded to list. Copy sent to Matthias Klose <[email protected]>. (Sat, 29 Jan 2022 18:06:04 GMT) (full text, mbox, link).


Message #12 received at [email protected] (full text, mbox, reply):

From: Ben Hutchings <[email protected]>
To: [email protected]
Subject: Re: Bug#1004504: Acknowledgement (Regression of -many on powerpc, ppc64)
Date: Sat, 29 Jan 2022 19:01:50 +0100
[Message part 1 (text/plain, inline)]
See also these reports on the linuxppc list:

https://lore.kernel.org/linuxppc-dev/CANtoAtPcRGHafb7LddtrY5g43m82txS_mY3WO_ZtJ+pfuLvKaw@mail.gmail.com/#t
https://lore.kernel.org/linuxppc-dev/[email protected]/

Ben.

-- 
Ben Hutchings
Absolutum obsoletum. (If it works, it's out of date.) - Stafford Beer
[signature.asc (application/pgp-signature, inline)]

Information forwarded to [email protected], Matthias Klose <[email protected]>:
Bug#1004504; Package binutils. (Thu, 03 Mar 2022 18:39:02 GMT) (full text, mbox, link).


Acknowledgement sent to Sean Christopherson <[email protected]>:
Extra info received and forwarded to list. Copy sent to Matthias Klose <[email protected]>. (Thu, 03 Mar 2022 18:39:02 GMT) (full text, mbox, link).


Message #17 received at [email protected] (full text, mbox, reply):

From: Sean Christopherson <[email protected]>
To: Ben Hutchings <[email protected]>
Cc: [email protected]
Subject: Re: Bug#1004504: Acknowledgement (Regression of -many on powerpc, ppc64)
Date: Thu, 3 Mar 2022 18:36:14 +0000
On Sat, Jan 29, 2022, Ben Hutchings wrote:
> See also these reports on the linuxppc list:
> 
> https://lore.kernel.org/linuxppc-dev/CANtoAtPcRGHafb7LddtrY5g43m82txS_mY3WO_ZtJ+pfuLvKaw@mail.gmail.com/#t
> https://lore.kernel.org/linuxppc-dev/[email protected]/

Cross-compiling PPC on x86-64 is also broken in 2.37 due to assembler errors.
I don't know enough about PPC to know if this is the same underlying root cause
or something different.

With 2.37-90 (amd64), attempting to compile various inline assembly (popcntd is
just one example), e.g.

  echo 'int foo(int x) { int p; asm ("popcntd %0,%1" : "=r" (p) : "r" (x)); return p; }' | \
  powerpc64-linux-gnu-gcc -x c - -c -o /dev/null

fails with:

  /tmp/ccWfffoZ.s: Assembler messages:
  /tmp/ccWfffoZ.s:26: Error: unrecognized opcode: `popcntd'

whereas version 2.34 compiles the above without error.



Information forwarded to [email protected], Matthias Klose <[email protected]>:
Bug#1004504; Package binutils. (Thu, 03 Mar 2022 18:42:02 GMT) (full text, mbox, link).


Acknowledgement sent to Sean Christopherson <[email protected]>:
Extra info received and forwarded to list. Copy sent to Matthias Klose <[email protected]>. (Thu, 03 Mar 2022 18:42:02 GMT) (full text, mbox, link).


Message #22 received at [email protected] (full text, mbox, reply):

From: Sean Christopherson <[email protected]>
To: Ben Hutchings <[email protected]>
Cc: [email protected]
Subject: Re: Bug#1004504: Acknowledgement (Regression of -many on powerpc, ppc64)
Date: Thu, 3 Mar 2022 18:38:54 +0000
On Thu, Mar 03, 2022, Sean Christopherson wrote:
> On Sat, Jan 29, 2022, Ben Hutchings wrote:
> > See also these reports on the linuxppc list:
> > 
> > https://lore.kernel.org/linuxppc-dev/CANtoAtPcRGHafb7LddtrY5g43m82txS_mY3WO_ZtJ+pfuLvKaw@mail.gmail.com/#t
> > https://lore.kernel.org/linuxppc-dev/[email protected]/
> 
> Cross-compiling PPC on x86-64 is also broken in 2.37 due to assembler errors.
> I don't know enough about PPC to know if this is the same underlying root cause
> or something different.
> 
> With 2.37-90 (amd64), attempting to compile various inline assembly (popcntd is
> just one example), e.g.
> 
>   echo 'int foo(int x) { int p; asm ("popcntd %0,%1" : "=r" (p) : "r" (x)); return p; }' | \
>   powerpc64-linux-gnu-gcc -x c - -c -o /dev/null
> 
> fails with:
> 
>   /tmp/ccWfffoZ.s: Assembler messages:
>   /tmp/ccWfffoZ.s:26: Error: unrecognized opcode: `popcntd'
> 
> whereas version 2.34 compiles the above without error.

Ah, I belatedly see that Ben's bug report says "update from binutils 2.37 to this
snapshot", which suggests that earlier versions of 2.37 are healthy?  Whereas the
cross-compiling issue goes back to at least 2.37.7.



Send a report that this bug log contains spam.


Debian bug tracking system administrator <[email protected]>. Last modified: Tue May 13 12:18:58 2025; Machine Name: bembo

Debian Bug tracking system

Debbugs is free software and licensed under the terms of the GNU General Public License version 2. The current version can be obtained from https://bugs.debian.org/debbugs-source/.

Copyright © 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson, 2005-2017 Don Armstrong, and many other contributors.