Re: crosstool: x86 kernel compiled with GCC 14.1 fails to boot

From: Jeff Johnson
Date: Mon Jul 08 2024 - 23:55:27 EST


On 7/8/2024 6:57 PM, Jeff Johnson wrote:
> We tend to enable a lot of debug config options, so I'm wondering if one of
> them is contributing to the issue? Guess I'll turn off a bunch of those
> options and try again.

OK, with a bunch of debug turned off my image boots.

Now to find the culprit.

Current diff between original config and working config:

20d19
< CONFIG_CONSTRUCTORS=y
328d326
< CONFIG_GENERIC_CSUM=y
337d334
< CONFIG_KASAN_SHADOW_OFFSET=0xdffffc0000000000
858a856
> CONFIG_VMAP_STACK=y
10938,10940d10935
< CONFIG_STACKDEPOT=y
< CONFIG_STACKDEPOT_ALWAYS_INIT=y
< CONFIG_STACKDEPOT_MAX_FRAMES=64
10996,10997d10990
< CONFIG_ARCH_WANT_FRAME_POINTERS=y
< CONFIG_FRAME_POINTER=y
10999d10991
< CONFIG_STACK_VALIDATION=y
11040a11033
> # CONFIG_KCSAN is not set
11056,11057c11049
< CONFIG_SLUB_DEBUG=y
< # CONFIG_SLUB_DEBUG_ON is not set
---
> # CONFIG_SLUB_DEBUG is not set
11060c11052
< CONFIG_PAGE_POISONING=y
---
> # CONFIG_PAGE_POISONING is not set
11064c11056
< CONFIG_DEBUG_WX=y
---
> # CONFIG_DEBUG_WX is not set
11066d11057
< CONFIG_PTDUMP_CORE=y
11069,11072c11060
< CONFIG_DEBUG_KMEMLEAK=y
< CONFIG_DEBUG_KMEMLEAK_MEM_POOL_SIZE=16000
< # CONFIG_DEBUG_KMEMLEAK_DEFAULT_OFF is not set
< CONFIG_DEBUG_KMEMLEAK_AUTO_SCAN=y
---
> # CONFIG_DEBUG_KMEMLEAK is not set
11074,11081c11062
< CONFIG_DEBUG_OBJECTS=y
< # CONFIG_DEBUG_OBJECTS_SELFTEST is not set
< # CONFIG_DEBUG_OBJECTS_FREE is not set
< CONFIG_DEBUG_OBJECTS_TIMERS=y
< CONFIG_DEBUG_OBJECTS_WORK=y
< CONFIG_DEBUG_OBJECTS_RCU_HEAD=y
< CONFIG_DEBUG_OBJECTS_PERCPU_COUNTER=y
< CONFIG_DEBUG_OBJECTS_ENABLE_DEFAULT=1
---
> # CONFIG_DEBUG_OBJECTS is not set
11084c11065
< CONFIG_SCHED_STACK_END_CHECK=y
---
> # CONFIG_SCHED_STACK_END_CHECK is not set
11091c11072
< CONFIG_MEMORY_NOTIFIER_ERROR_INJECT=m
---
> # CONFIG_MEMORY_NOTIFIER_ERROR_INJECT is not set
11099,11107c11080
< CONFIG_KASAN=y
< CONFIG_CC_HAS_KASAN_MEMINTRINSIC_PREFIX=y
< CONFIG_KASAN_GENERIC=y
< # CONFIG_KASAN_OUTLINE is not set
< CONFIG_KASAN_INLINE=y
< CONFIG_KASAN_STACK=y
< # CONFIG_KASAN_VMALLOC is not set
< # CONFIG_KASAN_MODULE_TEST is not set
< # CONFIG_KASAN_EXTRA_INFO is not set
---
> # CONFIG_KASAN is not set
11109,11114c11082
< CONFIG_KFENCE=y
< CONFIG_KFENCE_SAMPLE_INTERVAL=0
< CONFIG_KFENCE_NUM_OBJECTS=255
< # CONFIG_KFENCE_DEFERRABLE is not set
< # CONFIG_KFENCE_STATIC_KEYS is not set
< CONFIG_KFENCE_STRESS_TEST_FAULTS=0
---
> # CONFIG_KFENCE is not set
11126,11128c11094
< CONFIG_LOCKUP_DETECTOR=y
< CONFIG_SOFTLOCKUP_DETECTOR=y
< # CONFIG_BOOTPARAM_SOFTLOCKUP_PANIC is not set
---
> # CONFIG_SOFTLOCKUP_DETECTOR is not set
11130,11135c11096
< CONFIG_HARDLOCKUP_DETECTOR=y
< # CONFIG_HARDLOCKUP_DETECTOR_PREFER_BUDDY is not set
< CONFIG_HARDLOCKUP_DETECTOR_PERF=y
< # CONFIG_HARDLOCKUP_DETECTOR_BUDDY is not set
< # CONFIG_HARDLOCKUP_DETECTOR_ARCH is not set
< CONFIG_HARDLOCKUP_DETECTOR_COUNTS_HRTIMER=y
---
> # CONFIG_HARDLOCKUP_DETECTOR is not set
11137,11140c11098
< # CONFIG_BOOTPARAM_HARDLOCKUP_PANIC is not set
< CONFIG_DETECT_HUNG_TASK=y
< CONFIG_DEFAULT_HUNG_TASK_TIMEOUT=120
< # CONFIG_BOOTPARAM_HUNG_TASK_PANIC is not set
---
> # CONFIG_DETECT_HUNG_TASK is not set
11149c11107
< CONFIG_SCHED_DEBUG=y
---
> # CONFIG_SCHED_DEBUG is not set
11151c11109
< CONFIG_SCHEDSTATS=y
---
> # CONFIG_SCHEDSTATS is not set
11161,11162c11119
< CONFIG_PROVE_LOCKING=y
< # CONFIG_PROVE_RAW_LOCK_NESTING is not set
---
> # CONFIG_PROVE_LOCKING is not set
11164,11176c11121,11126
< CONFIG_DEBUG_RT_MUTEXES=y
< CONFIG_DEBUG_SPINLOCK=y
< CONFIG_DEBUG_MUTEXES=y
< CONFIG_DEBUG_WW_MUTEX_SLOWPATH=y
< CONFIG_DEBUG_RWSEMS=y
< CONFIG_DEBUG_LOCK_ALLOC=y
< CONFIG_LOCKDEP=y
< CONFIG_LOCKDEP_BITS=15
< CONFIG_LOCKDEP_CHAINS_BITS=16
< CONFIG_LOCKDEP_STACK_TRACE_BITS=19
< CONFIG_LOCKDEP_STACK_TRACE_HASH_BITS=14
< CONFIG_LOCKDEP_CIRCULAR_QUEUE_BITS=12
< # CONFIG_DEBUG_LOCKDEP is not set
---
> # CONFIG_DEBUG_RT_MUTEXES is not set
> # CONFIG_DEBUG_SPINLOCK is not set
> # CONFIG_DEBUG_MUTEXES is not set
> # CONFIG_DEBUG_WW_MUTEX_SLOWPATH is not set
> # CONFIG_DEBUG_RWSEMS is not set
> # CONFIG_DEBUG_LOCK_ALLOC is not set
11185,11186d11134
< CONFIG_TRACE_IRQFLAGS=y
< CONFIG_TRACE_IRQFLAGS_NMI=y
11192d11139
< # CONFIG_DEBUG_KOBJECT_RELEASE is not set
11208d11154
< CONFIG_PROVE_RCU=y
11248d11193
< CONFIG_PREEMPTIRQ_TRACEPOINTS=y
11327d11271
< # CONFIG_SAMPLE_KMEMLEAK is not set
11337d11280
< CONFIG_EARLY_PRINTK_USB=y
11339,11341c11282
< CONFIG_EARLY_PRINTK=y
< CONFIG_EARLY_PRINTK_DBGP=y
< CONFIG_EARLY_PRINTK_USB_XDBC=y
---
> # CONFIG_EARLY_PRINTK is not set
11347,11348c11288,11289
< # CONFIG_IO_DELAY_0X80 is not set
< CONFIG_IO_DELAY_0XED=y
---
> CONFIG_IO_DELAY_0X80=y
> # CONFIG_IO_DELAY_0XED is not set
11355,11358c11296,11300
< CONFIG_X86_DEBUG_FPU=y
< CONFIG_PUNIT_ATOM_DEBUG=m
< # CONFIG_UNWINDER_ORC is not set
< CONFIG_UNWINDER_FRAME_POINTER=y
---
> # CONFIG_X86_DEBUG_FPU is not set
> # CONFIG_PUNIT_ATOM_DEBUG is not set
> CONFIG_UNWINDER_ORC=y
> # CONFIG_UNWINDER_FRAME_POINTER is not set
> # CONFIG_UNWINDER_GUESS is not set