linux/arch/s390
Heiko Carstens 63678eecec s390/preempt: disable __preempt_count_add() optimization for PROFILE_ALL_BRANCHES
gcc 12 does not (always) optimize away code that should only be generated
if parameters are constant and within in a certain range. This depends on
various obscure kernel config options, however in particular
PROFILE_ALL_BRANCHES can trigger this compile error:

In function ‘__atomic_add_const’,
    inlined from ‘__preempt_count_add.part.0’ at ./arch/s390/include/asm/preempt.h:50:3:
./arch/s390/include/asm/atomic_ops.h:80:9: error: impossible constraint in ‘asm’
   80 |         asm volatile(                                                   \
      |         ^~~

Workaround this by simply disabling the optimization for
PROFILE_ALL_BRANCHES, since the kernel will be so slow, that this
optimization won't matter at all.

Reported-by: Thomas Richter <tmricht@linux.ibm.com>
Reviewed-by: Sven Schnelle <svens@linux.ibm.com>
Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
2022-05-11 14:40:58 +02:00
..
appldata s390/appldata: use struct_size() helper 2020-06-29 16:32:34 +02:00
boot s390/boot: convert parmarea to C 2022-05-06 20:45:15 +02:00
configs s390: enable CONFIG_HARDENED_USERCOPY in debug_defconfig 2022-04-12 11:56:08 +02:00
crypto s390/crypto: fix typos in comments 2022-05-06 20:45:13 +02:00
hypfs s390/hypfs: fix typos in comments 2022-05-06 20:45:13 +02:00
include s390/preempt: disable __preempt_count_add() optimization for PROFILE_ALL_BRANCHES 2022-05-11 14:40:58 +02:00
kernel s390/stp: clock_delta should be signed 2022-05-11 14:40:57 +02:00
kvm s390/ptrace: move short psw definitions to ptrace header file 2022-05-06 20:45:15 +02:00
lib s390: current_stack_pointer shouldn't be a function 2022-04-12 11:56:08 +02:00
mm s390/mmap: increase stack/mmap gap to 128MB 2022-04-25 13:54:14 +02:00
net s390: raise minimum supported machine generation to z10 2022-03-10 15:58:17 +01:00
pci s390/pci: add error record for CC 2 retries 2022-04-25 13:54:15 +02:00
purgatory s390: enable KCSAN 2021-07-30 17:09:23 +02:00
tools s390: raise minimum supported machine generation to z10 2022-03-10 15:58:17 +01:00
Kbuild kbuild: use more subdir- for visiting subdirectories while cleaning 2021-10-24 13:49:46 +09:00
Kconfig s390: allow to compile with z16 optimizations 2022-04-06 13:08:50 +02:00
Kconfig.debug tracing: Refactor TRACE_IRQFLAGS_SUPPORT in Kconfig 2021-08-16 11:37:21 -04:00
Makefile s390: allow to compile with z16 optimizations 2022-04-06 13:08:50 +02:00