100 likes | 271 Views
Computer Organization & Assembly Language. Lecture # 9 By Muhammad Jafer. Quiz (15-15). What is pipelining. How inlet Implemented pipelining Calculate Physical Address for each instructions. What will be the value of AX, AH, AL, IP & CS after executing the last instruction. STACK.
E N D
Computer Organization & Assembly Language Lecture # 9 By Muhammad Jafer
Quiz (15-15) • What is pipelining. How inlet Implemented pipelining • Calculate Physical Address for each instructions. • What will be the value of AX, AH, AL, IP & CS after executing the last instruction
STACK • Temporary memory for Processors • Stored in RAM • Importance & alternate of Register-Register Design • Every Register can be stored except SS&SP • Logical Addresses VS Physical Addresses • SS:SP • Overlapping • Intel Architecture Stack • Increments and then add • Show & decrement • Stack Pointer
Flag Registers • Conditional Flags • CF • PF • AF • ZF • SF • OF • Control Flags • TF • IF • DF
X86 Addressing Modes • Register Address Mode • MOV BX,DX • Immediate Mode • MOV AX,2550H • Direct Mode • MOV AX,[2550] • Register Indirect Addressing Mode • MOV AL,[BX] • Based Relative Addressing Mode • MOV CX,[BX]+10 • Based Index Addressing Mode • MOV CX,[BX][DX]+10 • Segment Overrides • MOV AL,[BX]
Chapter Review • The x86 PC Assembly Language, Design & Interfacing by Muhammad Ali Mazidi, Janice GillispieMazidi & Danny Causey • Chapter # 1 • The Stack • Flag Registers • X86 Addressing Modes
Assembly Program Concepts • [label:] mnemonic [operands] [;comments] • Mnemoics can be directives • Directive give direction to assembler • Assembly Program • Model Definition • Segment Definition • .STACK • .DATA • .CODE
MODEL DEFINITION • .MODEL SMALL • How much space is required • MEDIUM • >64k for memory • COMPACT • >64k for data • LARGE • >64k for both but one at a time • HUGE • >64k for both at same time • TINY • >COM File concepts (Will not be used in this course)
Segmentation DEFINITION • Can work with only one segment. • Good programing practices • .STACK 64k • .DATA • [label/Name] [length] [values] • DATA1 DB 55H • DATA2 DW ? • .CODE • MOVE DS,@DATA
Chapter Review • The x86 PC Assembly Language, Design & Interfacing by Muhammad Ali Mazidi, Janice GillispieMazidi & Danny Causey • Chapter # 2 • Directives & A Sample Program