[PATCH 4/4] arm: Enable ARM mode for armv6 strlen

Wilco Dijkstra Wilco.Dijkstra@arm.com
Fri Apr 13 15:10:00 GMT 2018


Hi,

I can't see a valid reason for disabling Thumb-2 when it is available - it's not slower
and if necessary you can align loops or force Thumb-2 instructions to be 32 bit in an inner
loop. So basically if you have Thumb-2 available you might as well use it to get smaller
code - there is no advantage in using Arm. Supporting a no-Thumb-2 build would be
additional maintenance (unless it was an official variant it would not be tested as you've
shown, and I think there are already too many variants...).

Also keeping assembly code clean without lots of #if's that make it hard to follow the
logic (or the carry flags!) is best.

Wilco


More information about the Libc-alpha mailing list