第一篇
尝试着记录学习过程
#include<>
# offset 512, entry point .globl _start _start: # Explicitly enter this as bytes, or the assembler # tries to generate a 3-byte jump here, which causes # everything else to push off to the wrong offset. .byte 0xeb # short (2-byte) jump .byte start_of_setup-1f #第一条指令,这是一条短跳转,接下来到start_of_setup。执行设置堆栈清空setup的bss段等操作,然后跳转到boots/main.c中。 # Jump to C code (should not return) calll main #到C代码去了
浙公网安备 33010602011771号