RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1726641 - Request a backport of fixes for SVE Vector PCS on AArch64 (gcc part)
Summary: Request a backport of fixes for SVE Vector PCS on AArch64 (gcc part)
Alias: None
Product: Red Hat Enterprise Linux 8
Classification: Red Hat
Component: gcc
Version: ---
Hardware: Unspecified
OS: Unspecified
Target Milestone: rc
: 8.0
Assignee: Marek Polacek
QA Contact: Alexandra Petlanová Hájková
Kevin Owen
Depends On:
Blocks: 1724130 1755139
TreeView+ depends on / blocked
Reported: 2019-07-03 10:56 UTC by Nick Clifton
Modified: 2023-07-18 14:19 UTC (History)
9 users (show)

Fixed In Version: gcc-toolset-9-gcc-9.2.1-2.1.el8
Doc Type: Bug Fix
Doc Text:
.Advanced SIMD functions on the 64-bit ARM architecture no longer miscompile when lazily resolved Previously, the new vector Procedure Call Standard (PCS) for Advanced SIMD did not properly save and restore certain callee-saved registers when lazily resolving Advanced SIMD functions. As a consequence, binaries could misbehave at runtime. With this update, the Advanced SIMD and SVE vector functions in the symbol table are marked with `.variant_pcs` and, as a result, the dynamic linker will bind such functions early.
Clone Of:
Last Closed: 2020-04-28 15:58:37 UTC
Type: Bug
Target Upstream Version:

Attachments (Terms of Use)

System ID Private Priority Status Summary Last Updated
Red Hat Bugzilla 1724130 1 None None None 2023-07-18 14:19:32 UTC
Red Hat Issue Tracker RHELPLAN-26786 0 None None None 2021-08-27 22:46:04 UTC
Red Hat Product Errata RHBA-2020:1683 0 None None None 2020-04-28 15:58:46 UTC

Description Nick Clifton 2019-07-03 10:56:56 UTC
Clone of #1724130, created for the gcc component.

Description of problem:

Arm has introduced a vector PCS for SVE and Advanced SIMD. This showed a problem with lazy binding on SVE vector PCS while testing the qemu implementation of SVE primarily to do with saving and restoring the additional callee saved register state in the new vector PCS when lazily resolving SVE functions. 

The draft text for fixing the ABI for this is at

It requires the marking of vector functions in the symbol table so the dynamic linker can bind them early. For this the symbol marking has to be propagated from the compiler to the final dynamic linked binary.

Running an executable with vector pcs turned on for SVE. Note that such binaries could be generated by other commercial toolchains as well.

This has been fixed by a series of patches for gcc
binutils and glibc. These need to be backported on systems
that run on SVE hardware to support binaries with extern
SVE calls and to support compiling code with SVE or AdvSIMD
vector calls.

Without the glibc backport, the dynamic linker clobbers
SVE call argument registers in the lazy binding entry code
when the function is first called. So binaries with extern
SVE calls will misbehave at runtime.

Without the binutils backport, the bfd linker silently
drops symbol markings at link time, creating broken
binaries that misbehave even with an updated glibc.
Without the binutils backport, the assembler fails to
assemble code with SVE or AdvSIMD calls because it does
not understand the new .variant_pcs directive.

Without the gcc backport, gcc-9 emits AdvSIMD vector calls
without marking them with .variant_pcs and thus they won't
follow the new ABI. This is unlikely to cause runtime
problems now as AdvSIMD registers are unlikely to be
corrupted by the dynamic linker, but the marking is an ABI
requirement and will be necessary to support LD_AUDIT or
arbitrary ifunc resolvers for AdvSIMD vector calls among
other features.

We plan to backport the patches below to gcc-9, binutils-2.32
and several glibc release branches.



commit 779640c76d37b32f4d8a7b97637ed9e345d750b4
Commit:     nsz <nsz@138bc75d-0d04-0410-961f-82ee72b054a4>
CommitDate: 2019-06-03 13:50:53 +0000

    aarch64: emit .variant_pcs for aarch64_vector_pcs symbol references
    git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@271869 138bc75d-0d04-0410-961f-82ee72b054a4

commit d403a7711c2cf9a7a4892d76b875a1c99a690f89
Commit:     nsz <nsz@138bc75d-0d04-0410-961f-82ee72b054a4>
CommitDate: 2019-06-04 16:16:52 +0000

    aarch64: fix asm visibility for extern symbols
    git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@271913 138bc75d-0d04-0410-961f-82ee72b054a4

Comment 11 errata-xmlrpc 2020-04-28 15:58:37 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.


Note You need to log in before you can comment on or make changes to this bug.