OK, this is a binutils problem. We need to backport this commit to the assembler: https://sourceware.org/git/?p=binutils-gdb.git;a=commitdiff;h=af4bcb4ce6939da1738c847a06789d2223b67ca4 and then additionally the patch that allows the rng extension to be used without armv8.5: https://sourceware.org/pipermail/binutils/2022-March/120304.html
Fixed in binutils-2.30-115.el8
Verified with binutils-2.30-116.el8 reproducer from comment #5: $ cat x.c int main () { } $ $ cat flags processor : 0 BogoMIPS : 2100.00 Features : fp asimd evtstrm aes pmull sha1 sha2 crc32 atomics fphp asimdhp cpuid asimdrdm jscvt fcma lrcpc dcpop sha3 sm3 sm4 asimddp sha512 sve asimdfhm dit uscat ilrcpc flagm ssbs dcpodp svei8mm svebf16 i8mm bf16 dgh rng CPU implementer : 0x41 CPU architecture: 8 CPU variant : 0x1 CPU part : 0xd40 CPU revision : 1 $ $ GCC_CPUINFO=flags gcc x.c -mcpu=native Assembler messages: Error: unknown architectural extension `rng+nodotprod+nofp16fml' Error: unrecognized option -march=armv8.4-a+crypto+rcpc+sha3+sm4+sve+rng+nodotprod+nofp16fml $ $ GCC_CPUINFO=flags gcc x.c -mcpu=native $
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 (binutils bug fix and enhancement update), and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHBA-2022:7693