toc.asm.svn-base

来自「德国Erlangen大学教学操作系统源码。」· SVN-BASE 代码 · 共 67 行

SVN-BASE
67
字号
;******************************************************************************;* Betriebssysteme                                                            *;*----------------------------------------------------------------------------*;*                                                                            *;*                               T O C . A S M                                *;*                                                                            *;*----------------------------------------------------------------------------*;*;******************************************************************************%include "machine/toc.inc"; EXPORTIERTE FUNKTIONEN[GLOBAL toc_switch][GLOBAL toc_go]; IMPLEMENTIERUNG DER FUNKTIONEN[SECTION .text]; TOC_GO : Startet den ersten Prozess ueberhaupt.;; C Prototyp: void toc_go (struct toc* regs);toc_go:; lesen alle register aus regs	mov	eax, [esp+4]	mov	ebx, [eax]	mov	esi, [eax+4]	mov	edi, [eax+8]	mov	ebp, [eax+12]	mov	esp, [eax+16]	ret	; TOC_SWITCH : Prozessumschaltung. Der aktuelle Registersatz wird     ;              gesichert und der Registersatz des neuen "thread of control";              wird in den Prozessor eingelesen.  ;; C Prototyp: void toc_switch (struct toc* regs_now,;                              struct toc* reg_then);toc_switch:; speichern alle register ins regs_now	mov	eax, [esp+4]	mov	[eax], ebx	mov	[eax+4], esi	mov	[eax+8], edi	mov	[eax+12], ebp	mov	[eax+16], esp	; lesen alle register aus reg_then	mov	eax, [esp+8]	mov	ebx, [eax]	mov	esi, [eax+4]	mov	edi, [eax+8]	mov	ebp, [eax+12]	mov	esp, [eax+16]	ret	

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?