[PATCH] ARM: iwmmxt: Remove support for PJ4/PJ4B cores

Matt Turner mattst88 at gmail.com
Thu Aug 15 11:41:42 PDT 2024


On 02/09, Ard Biesheuvel wrote:
>From: Ard Biesheuvel <ardb at kernel.org>
>
>PJ4 is a v7 core that incorporates a iWMMXt coprocessor. However, GCC
>does not support this combination (its iWMMXt configuration always
>implies v5te), and so there is no v6/v7 user space that actually makes
>use of this, beyond generic support for things like setjmp() that
>preserve/restore the iWMMXt register file using generic LDC/STC
>instructions emitted in assembler. As [0] appears to imply, this logic
>is triggered for the init process at boot, and so most processes will
>have a iWMMXt register context associated with it, even though it is
>never used.
>
>This means that advertising iWMMXt support on these cores results in
>context switch overhead without any associated benefit, and so it is
>better to simply ignore the iWMMXt unit on these systems. So rip out the
>support. Doing so also fixes the issue reported in [0] related to UNDEF
>handling of co-processor #0/#1 instructions issued from user space
>running in Thumb2 mode.

For what it's worth, there was usage of iwMMXt on ARM v7 cores.

pixman had [1][2] iwMMXt paths that I optimized for the XO 1.75 and
would occasionally test on a CuBox over the years.

I'm surprised to see that this landed with the claim that "there is
no v6/v7 user space that actually makes use of this". A quick Google
search reveals evidence of usage [3]. It doesn't seem like this should
have been backported to the stable branches in any case.

I know that ffmpeg used to have iwMMXt paths as well, but I believe they
were removed a few years ago.

Anyway, I guess it's totally dead now.

[1] https://gitlab.freedesktop.org/pixman/pixman/-/merge_requests/108
[2] https://mattst88.com/blog/2012/07/06/My_time_optimizing_graphics_performance_on_the_OLPC_XO_1.75_laptop/
[3] https://www.phoronix.com/news/MTEzNDQ



More information about the linux-arm-kernel mailing list