Attempting to build media-libs/opencv-4.9.0 without unmasking cpu_flags_arm_neon causes the linker to find undefined references to NEON functions. Tested with GCC+bfd and Clang+lld. Manually unmasking cpu_flags_arm_neon and building resolves the issue using both toolchains, but this of course then introduces issues with other packages.
Please provide emerge --info and attach a build log demonstrating the link failure.
Created attachment 890747 [details] emerge --info
Created attachment 890748 [details] build.log
cpu_flags_arm_neon shouldn't be used on arm64 - it's really for 32-bit NEON. The problem is that this is undocumented, not even widely agreed on in more public mediums and not all packages actually unconditionally enable 64-bit NEON on arm64 arch.
I am well aware of what the behaviour *should* be, hence the bug.
I was discussing this with Paul on IRC and thus "documented" it here for his justification purposes to proxy maintainers or otherwise :)
cpu_flags_arm_neon has been unmasked in https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=cebb6e2fdce12a8c5f81f1b19bd494469ace2786 I'll leave this bug open until the situation is cleared up so I have a reminder.