[RFC PATCH v2] mvebu: compile the kernel in Thumb-2 mode for ARMv7 targets

Hauke Mehrtens hauke at hauke-m.de
Wed Jul 1 17:34:57 EDT 2020


On 7/1/20 12:30 AM, Rui Salvaterra wrote:
> Hi, Hauke,
> 
> On Tue, 30 Jun 2020 at 21:32, Hauke Mehrtens <hauke at hauke-m.de> wrote:
>>
>> Did you run a benchmark to test how much faster it is?
> 
> I haven't done any performance testing, but I expect it to be a wash
> (improvements/regressions within around 2-3 % across the board). The
> big win here is in the memory/icache footprint.
> How do we usually do performance testing in OpenWrt, by the way? I
> could try and see if there's any meaningful difference in, say,
> OpenSSL speed, but that won't tell us anything about networking
> performance.

I would like to know if these changes are worth the effort. If you see
some performance improvements somewhere like some VPN bandwidth is now
3% higher, it would be nice to know.

>> Did you also tested this with the current default toolchain?
>> I would like to use binutils 2.34 as default soon, but gcc will probably
>> not be updated soon.
> 
> There's no reason gcc 8 won't work fine too, the only snag we hit was
> with gas, and that's already fixed (see below). I'll test with gcc 8
> too, though, just to make sure (and 10, as soon as it hits master :)).
> 
>> Do you know if there is a fix for GNU gas available?
> 
> Yes, I do. Jason filled an upstream bug and it's already fixed [1]. I
> don't know if it'll be backported to other binutils versions, though.
> In any case, the only problematic module was WireGuard (due to an old
> hack), which Jason already fixed in the latest compat backport [2]
> (note that with this fix in place, the kernel R_ARM_THM_JUMP11
> workaround isn't required at all).

We could also backport this fix to the OpenWrt binutils version and then
we do not need the workaround any more. The fix is small and we can get
rid of the patch when we update binutils to the next major version.

Hauke

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: OpenPGP digital signature
URL: <http://lists.openwrt.org/pipermail/openwrt-devel/attachments/20200701/382122b5/attachment.sig>


More information about the openwrt-devel mailing list