Download presentation
Presentation is loading. Please wait.
Published byHandoko Hartanto Modified over 5 years ago
1
CS-401 Computer Architecture & Assembly Language Programming
Lecture-31 Multitasking
2
Lets revise the last lecture
3
Multitasking/Multithreading
4
Thread Initialization
CS:IP = thread entry point SS:SP = next free stack Flags = 0x0200 AX,BX,CX,DX,SI,DI,BP,ES = don’t care DS = depends upon registration mechanism
5
Thread Initialization
mov si,[nextpcb] mov cl,9 shl si,cl add si,256*2+stack mov ax,[bp+4] sub si,2 mov [si],ax
6
Thread Initialization
mov si,[nextpcb] 3 mov cl,9 shl si,cl add si,256*2+stack mov ax,[bp+4] sub si,2 mov [si],ax
7
Thread Initialization
mov si,[nextpcb] mov cl,9 shl si,cl add si,256*2+stack mov ax,[bp+4] sub si,2 mov [si],ax
8
Thread Initialization
mov si,[nextpcb] mov cl,9 shl si,cl add si,256*2+stack mov ax,[bp+4] sub si,2 mov [si],ax SI SI
9
Thread Initialization
mov ax,[pcb+28] mov [pcb+bx+28],ax mov ax,[nextpcb] mov [pcb+28],ax
10
Thread Initialization
mov ax,[pcb+28] mov [pcb+bx+28],ax mov ax,[nextpcb] mov [pcb+28],ax PCB 0 PCB 1
11
Thread Initialization
mov ax,[pcb+28] mov [pcb+bx+28],ax mov ax,[nextpcb] mov [pcb+28],ax PCB 0 PCB 1
12
Thread Initialization
mov ax,[pcb+28] mov [pcb+bx+28],ax mov ax,[nextpcb] mov [pcb+28],ax PCB 0 PCB 1
13
Thread Initialization
mov ax,[pcb+28] mov [pcb+bx+28],ax mov ax,[nextpcb] mov [pcb+28],ax PCB 0 PCB 1 PCB 2
14
Thread Initialization
mov ax,[pcb+28] mov [pcb+bx+28],ax mov ax,[nextpcb] mov [pcb+28],ax PCB 0 PCB 1 PCB 2
15
Thread Initialization
mov ax,[pcb+28] mov [pcb+bx+28],ax mov ax,[nextpcb] mov [pcb+28],ax PCB 0 PCB 1 PCB 2
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.