Build a separate libsupc++ for the kernel with correct flags.
Kernel mode code on x86_64 needs to be built with -mno-red-zone as interrupts would corrupt the red zone if it were in use. However, the kernel is linked with libsupc++, which was not compiled with -mno-red-zone. If an interrupt occurred in libsupc++ code the red zone would get corrupted. This was causing random panics, particularly under heavy system load. Therefore, on x86_64 a separate build of libsupc++ with -mno-red-zone is now done for the kernel to use. Note: this commit will require a rerun of configure and rebuild of cross tools.
This commit is contained in:
@@ -1035,6 +1035,8 @@ if $(TARGET_PLATFORM) = haiku {
|
||||
TARGET_GCC_LIBGCC = $(HAIKU_GCC_LIBGCC) ;
|
||||
TARGET_GCC_LIBGCC_OBJECTS = $(HAIKU_GCC_LIBGCC_OBJECTS) ;
|
||||
|
||||
TARGET_KERNEL_LIBGCC = $(HAIKU_KERNEL_LIBGCC) ;
|
||||
TARGET_KERNEL_LIBSUPC++ = $(HAIKU_KERNEL_LIBSUPC++) ;
|
||||
TARGET_BOOT_LIBGCC = $(HAIKU_BOOT_LIBGCC) ;
|
||||
TARGET_BOOT_LIBSUPC++ = $(HAIKU_BOOT_LIBSUPC++) ;
|
||||
|
||||
@@ -1054,6 +1056,8 @@ if $(TARGET_PLATFORM) = haiku {
|
||||
TARGET_GCC_LIBGCC = ;
|
||||
TARGET_GCC_LIBGCC_OBJECTS = ;
|
||||
|
||||
TARGET_KERNEL_LIBGCC = ;
|
||||
TARGET_KERNEL_LIBSUPC++ = ;
|
||||
TARGET_BOOT_LIBGCC = ;
|
||||
TARGET_BOOT_LIBSUPC++ = ;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user