Presentation is loading. Please wait.

Presentation is loading. Please wait.

CS-401 Computer Architecture & Assembly Language Programming

Similar presentations


Presentation on theme: "CS-401 Computer Architecture & Assembly Language Programming"— Presentation transcript:

1 CS-401 Computer Architecture & Assembly Language Programming
Lecture-21 Software Interrupts

2 Lets revise the last lecture

3 Assignment for the students

4 Interept

5 int n push flags IF < 0 TF < 0 push cs push ip ip < [0:4*n]
cs < [0:4*n+2]

6 iret ip < [ss:sp] sp < sp + 2 cs < [ss:sp] flags < [ss:sp]

7 int/iret Illustration
2000:0100 mov ax,0 2000:0103 mov bx,10 2000:0106 int 0x10 2000:0108 cmp ax,0 2000:010B 3000:0148 mov ax,0 3000: 3000:0148 iret 3000: FLAGS IVT ******* . ******* . stack ******* .

8 int/iret Illustration
2000:0100 mov ax,0 2000:0103 mov bx,10 2000:0106 int 0x10 2000:0108 cmp ax,0 2000:010B 3000:0148 mov ax,0 3000: 3000:0148 iret 3000: FLAGS IVT ******* . ******* . stack ******* .

9 int/iret Illustration
2000:0100 mov ax,0 2000:0103 mov bx,10 2000:0106 int 0x10 2000:0108 cmp ax,0 2000:010B 3000:0148 mov ax,0 3000: 3000:0148 iret 3000: FLAGS IVT ******* . ******* . 0x2000 0x0108 stack ******* .

10 int/iret Illustration
2000:0100 mov ax,0 2000:0103 mov bx,10 2000:0106 int 0x10 2000:0108 cmp ax,0 2000:010B 3000:0148 mov ax,0 3000: 3000:0148 iret 3000: IVT ******* . ******* . stack 0x0108 0x2000 FLAGS ******* .

11 int/iret Illustration
2000:0100 mov ax,0 2000:0103 mov bx,10 2000:0106 int 0x10 2000:0108 cmp ax,0 2000:010B 3000:0148 mov ax,0 3000: 3000:0148 iret 3000: IVT ******* . ******* . stack 0x0108 0x2000 FLAGS ******* .

12 int/iret Illustration
2000:0100 mov ax,0 2000:0103 mov bx,10 2000:0106 int 0x10 2000:0108 cmp ax,0 2000:010B 3000:0148 mov ax,0 3000: 3000:0148 iret 3000: IVT ******* . ******* . stack 0x0108 0x2000 FLAGS ******* .

13 int/iret Illustration
2000:0100 mov ax,0 2000:0103 mov bx,10 2000:0106 int 0x10 2000:0108 cmp ax,0 2000:010B 3000:0148 mov ax,0 3000: 3000:0148 iret 3000: IVT ******* . ******* . stack 0x0108 0x2000 FLAGS ******* .

14 int/iret Illustration
2000:0100 mov ax,0 2000:0103 mov bx,10 2000:0106 int 0x10 2000:0108 cmp ax,0 2000:010B 3000:0148 mov ax,0 3000: 3000:0148 iret 3000: IVT ******* . ******* . stack ******* . 0x0108 0x2000 FLAGS


Download ppt "CS-401 Computer Architecture & Assembly Language Programming"

Similar presentations


Ads by Google