Package:
release.debian.org
Severity: normal
Tags: bullseye
User:
release.d...@packages.debian.org
Usertags: pu
X-Debbugs-Cc:
debian...@lists.debian.org
[ Reason ]
The glibc/2.31-13+deb11u4 update introduced a regression (bug #1019855)
on some early Intel Haswell processors which expose the AVX2
instructions, but lack the BMI2 instructions. On such systems the memchr
and strlen related functions fails with SIGILL, rendering them unusable.
The issue is that some of the backported commits to fix the overflow
bugs in the AVX2 implementation of wmemchr and wcslen that went in the
upstream 2.31 branch, started to use BMI2 instructions in addition to
the AVX2 instructions, without checking for the availability of those
instructions. This was done in another commit that hasn't been
backported.
It happens that a microcode update for the affected CPUs (either through
the BIOS/firmware or from a package) fixes this, so it went barely
noticed up to now, especially given other distributions usually install
firmware updates by default.
[ Impact ]
While the number of affected systems is probably small, this bug makes
them unusable.
[ Tests ]
This has been tested, by replacing all BMI2 instructions in the glibc
source code by the UD2 x86 instruction. This triggered the same issue
than the reported one in bug#1019855. Then the detection of BMI2
instructions has been disabled in the source code, and the resulting
glibc was working as expected without generating SIGILL.
[ Risks ]
The change is intentionally minimal, smaller than the upstream one, and
only targets the runtime execution. Some tests of the testsuite will
still fail on affected systems. This part can be fixed later in a point
release. This way the risks should be minimal.
[ Checklist ]
[x] *all* changes are documented in the d/changelog
[x] I reviewed all changes and I approve them
[x] attach debdiff against the package in (old)stable
[x] the issue is verified as fixed in unstable
[ Changes ]
The change is very simple and consists in adding a check for BMI2
instructions in the ifunc selector that selects the AVX2 optimized code.
[ Other info ]
Given the severity of the bug, it might be a good idea to release it
through stable-updates.