你给的信息有误,是mno-red-zone!
英语的介绍是:
What is the 'red-zone'?
The red-zone is a feature described in the x86-64 ABI.
It is a 128 byte long region located directly below the stack pointer. This region is free-for-use for the compiler without the requirement to notify the application / the os or any running interrupt handler.
For user applications there is no issue as interrupts and other kernel related code won't interfere with the user stack. In your kernel however things can get ugly especially so if you have nested interrupts and no red-zone support. Imagine running inside your interrupt handler gcc puts some data inside the red zone a nested interrupt occurs and clobbers the red-zone or vice versa.
To get around this the red-zone can be disabled by passing -mno-red-zone to GCC.
x86_64-elf-gcc $CFLAGS -mno-red-zone ...
就是为了保护一个128byte区域的编译特性,防止各种原因破坏其中的数据,一般在编译内核时都需要打开,编译一般的用户程序可以不打开。