a write short notes on displacement only


(a) Write short notes on displacement only addressing mode.

(b) Explain the formats of a 80-bit floating point number.

(c) Given the following assembly program. Instructions affect the CPU status flags at several stages when the program is run. Show on which lines the flags ZF, CF and OF are triggered to 1.

TITLE Addition and Subtraction

INCLUDE Irvine32.inc

.data
Rval SDWORD ?
Xval SDWORD 26
Yval SDWORD 30
Zval SDWORD 40

.code
main PROC

; INC and DEC
mov ax,1000h
inc ax
dec ax

; Expression: Rval = -Xval + (Yval - Zval)
mov eax,Xval
neg eax
mov ebx,Yval
sub ebx,Zval
add eax,ebx
mov Rval,eax
mov cx,1
sub cx,1
mov ax,0FFFFh
inc ax

mov cx,0
sub cx,1
mov ax,7FFFh
add ax,2

mov al,0FFh
add al,1

mov al,+127
add al,1
mov al,-128
sub al,1
exit
main ENDP
END main

(d) Write a program in assembly to evaluate the sum of all the hexadecimal integer numbers of a 5-element array. Show the registers' contents.

Request for Solution File

Ask an Expert for Answer!!
Computer Engineering: a write short notes on displacement only
Reference No:- TGS0358503

Expected delivery within 24 Hours