• Nick Desaulniers's avatar
    kbuild: drop support for CONFIG_CC_OPTIMIZE_FOR_PERFORMANCE_O3 · a6036a41
    Nick Desaulniers authored
    The difference in most compilers between `-O3` and `-O2` is mostly down
    to whether loops with statically determinable trip counts are fully
    unrolled vs unrolled to a multiple of SIMD width.
    
    This patch is effectively a revert of
    commit 15f5db60 ("kbuild,arc: add
    CONFIG_CC_OPTIMIZE_FOR_PERFORMANCE_O3 for ARC") without re-adding
    ARCH_CFLAGS
    
    Ever since
    commit cfdbc2e1 ("ARC: Build system: Makefiles, Kconfig, Linker
    script")
    ARC has been built with -O3, though the reason for doing so was not
    specified in inline comments or the commit message. This commit does not
    re-add -O3 to arch/arc/Makefile.
    
    Folks looking to experiment with `-O3` (or any compiler flag for that
    matter) may pass them along to the command line invocation of make:
    
    $ make KCFLAGS=-O3
    
    Code that looks to re-add an explicit Kconfig option for `-O3` should
    provide:
    1. A rigorous and reproducible performance profile of a reasonable
       userspace workload that demonstrates a hot loop in the kernel that
       would benefit from `-O3` over `-O2`.
    2. Disassembly of said loop body before and after.
    3. Provides stats on terms of increase in file size.
    
    Link: https://lore.kernel.org/linux-kbuild/CA+55aFz2sNBbZyg-_i8_Ldr2e8o9dfvdSfHHuRzVtP2VMAUWPg@mail.gmail.com/Signed-off-by: default avatarNick Desaulniers <ndesaulniers@google.com>
    Signed-off-by: default avatarMasahiro Yamada <masahiroy@kernel.org>
    a6036a41
nsimosci_hs_smp_defconfig 2.06 KB