https://gcc.gnu.org/bugzilla/show_bug.cgi?id=79149
--- Comment #11 from Arnd Bergmann <arnd at linaro dot org> --- I've submitted a workaround for the kernel now, addressing the stack usage warning on MIPS, as well as performance on ARM and others: https://patchwork.kernel.org/patch/9555183/ The patch has two different workarounds, as I found that adding -Wno-schedule-insns gives us the best results on the whirlpool512 code for both stack size and performance by a wide margin, while -fsched-pressure is better on stack size for "serpent" across architectures and compiler versions However, it is interesting to notice that arm-linux-gnueabi-gcc-7 produces worse results with the serpent source code in terms of stack size with the default "-fsched-pressure" ("press") than older versions, and worse than -fno-schedule-insns (nosched): default press nopress nosched arm-linux-gnueabi-gcc-4.4.7 592 440 arm-linux-gnueabi-gcc-4.5.4 776 448 776 544 arm-linux-gnueabi-gcc-4.6.4 776 448 776 544 arm-linux-gnueabi-gcc-4.7.4 768 448 768 544 arm-linux-gnueabi-gcc-4.8.5 488 488 776 544 arm-linux-gnueabi-gcc-4.9.3 552 552 776 536 arm-linux-gnueabi-gcc-5.3.1 552 552 776 536 arm-linux-gnueabi-gcc-6.1.1 560 560 776 536 arm-linux-gnueabi-gcc-7.0.1 616 616 808 536 If we want to continue investigating this, I can try to construct a standalone test case for performance testing on 'serpent' as well.