أسئلة أسمبلي اختر
أسئلة أسمبلي اختر
أسئلة أسمبلي اختر
a.15
b.None of these
c.200
d.30
e.2r50
f.25
2- Considering that the code for AX=00, CX=10,[BX]=100, [xxxx]=110,
constant=111 add=101 and sub=100 ,
What is the corresponding machine code for the instruction: Add CX,AX ?
a.10100010
b.10101000
c.10110000
d.10100100
3- In control bus, the following read and write line signals are valid except ---------
b.None of these
a.60CAA
b.60CCA
c.60CBA
d.60BAA
e.None of these
5- System Bus Contains:
c.Address Bus
d.None of these
e.Control Bus
f.Data Bus
a.16 bits
b.36 bits
c.25 bits
d.26 bits
7- Consider the following information, DS=2FACH , and IP=7E33H, calculate the data
address, and then select the correct answer:
a.812DB
b.ADDE0
c.378F3
d.ADDE
8- Memory address refers to the successive memory words and the machine is called as .......
a.Word addressable
c.None of these
d.Bit addressable
e.Byte addressable
9- Assume that AX = 254, and the following instruction ADD AX, 1; then the flag register
CF= and AF will be
a.None of these
a.4B5E0H
b.271CCH
c.4B5EH
d.271DCH
11- If a, b, and c are 8-bit numbers (defined with db directive), Choose one of
assembly code equivalent to a = a*b%c
a.
mov AX,a
mul b
div c
mov a,AX
b.
mov AL,a
div c
Mul b
mov a,AL
c.
mov AL,a
mul b
div c
mov a,AL
d.
mov AL,a
mul b
div c
mov a,AH
12- If AL contains +124 and you add 3 to AL, the Overflow flag will be set.
a.False
b.True
13- The PROC directive marks the beginning of a procedure WHILE the END directive marks
the termination of the procedure.
a.False
b.True
14- An identifier in assembly language may contain other characters besides letters and
digits
a.False
b.True
a.Direct
b.Register
c.Indirect
d.Constant
e.None of these
c.None of these
a.‘R’
b.‘s’
c.None of these
d.‘53’
e.‘r’
f.‘S’
18- Set when carry out of bit 3 in the destination operand
b.Parity flag
c.Carry flag
d.Overflow flag
19- if AX contains decimal -2 and BX contains decimal 2 then after the execution of
instructions: CMP AX, BX JA label
b.None of these
a.signal Bus
b.instruction Bus
c.control Bus
d.status Bus
21- Clock cycle is another name for machine cycle.
a.TRUE
b.FALSE
22- For accessing 16-bit (word) data at the address [200BAH] from Main
Memory (even Bank, odd Bank) , What will be the values of A0 and BHE?
(NOTE: IF the ACCESSING NEEDS TWO MEMORY BUS CYCLE, identify the
state of A0 and BHE at first cycle)
23- ___________________ points at the segment containing the currently executing machine
instructions.
a.ES
b.CS
c.SS
d.DS
24- Which of the following will terminate a program and return to MS-DOS:
a.
mov ax, 4c00h
int 21h
b.None of these
c.
mov ax, 9h
int 22h
d.
mov ax, 4c00h
int 20h
e.
mov dx, 4c00h
int 21h
25- The control unit (CU) coordinates the order in which computer instructions are executed.
a.FALSE
b.TRUE
26- You have given the following code, what will be then Ah=…………. And Al=…………
c.None of these
27- Set when carry out of sign bit is not equal to carry in to sign bit
a.Carry flag
b.Parity flag
d.Overflow flag
28- ___________________ describes what the computer does and deals with high-level design
issues.
a.Computer Design
b.Computer Structure
c.Computer Architecture
d.Computer Organization
29- BHE of 8086 microprocessor signal is used to select the___________
b.I/O
d.cache memory
30- Each wire in a bus can transfer ______________bit(s) of information.
a.one
b.two
c.many
d.three
31- A set of wires that exchanges the data between the computer components
a.FALSE
b.TRUE
32- _________________ into which the CPU will automatically load the result of a ALU
operations.
a.Accumlator Register
b.Data Register
c.Base Register
d.Code Register
33- BP register points to the top of the stack segment.
True
False
34- Assume that the value in bl 127, which of the following subtract 11 from bl register (note:
the zero bit is the right most bit)
a.None of these
a.Stack segment
b.code segment
c.IP
d.data segment
36- What will be the segment for each of the following instruction: mov byte [bL+si+0x0100],
10; Segment is
b.SS
c.None of these
d.DS
e.ES
f.CS
37- Which one of the following Assembly statements can be used to invert the bits # 1, 2, 4,
6 in the CL register and the other bits are unchanged. Note that the rightmost bit is bit#
0.
a.XOR CL,01010110B
b.OR CL,10101001B
c.OR CL,01010110B
d.XOR CL,10101001B
38- When the operand of DIV instruction is of 8 bits then reminder will be stored in
a.BL
b.BH
c.CL
d.None of these
e.AH
f.AL
g.CH
39- Choose one of the assembly code that equivalent to the following while-loop structure:
While(AX < 10 ){
BX= BX + AX;
AX= AX + 2;
}
a.
loop1:CMP AX, 10
Jae outloop
Add BX,AX
Add AX,2
JMP loop1
outloop:
b.
loop1:CMP AX, 10
Jb outloop
Add BX,AX
Add AX,2
JMP loop1
outloop:
c.
loop1:CMP AX, 10
Add BX,AX
Add AX,2
Jb loop1
outlopp:
d.
CMP AX, 10
loop1: Jae outloop
Add BX,AX
Add AX,2
jmp loop1
outloop:
a.flag register
b.CX register
c.IP register
d.AX register
41- How many times does this loop?
L1: MOV CX, 4
DEC CX
Loop L1
a.4
b.3
c.2
a.
mov ah,02h
mov dh,12
mov dl,20
int 21h
b.
mov ah,02h
mov dh,12
mov dl,20
int 10h
c.
mov ah,02h
mov ch,12
mov cl,20
int 10h
d.
mov ah,02h
mov ch,12
mov cl,20
int 21h
43- Choose one of the assembly code that equivalent for the following if-else construct:
IF(AX<BX)
AX=AX+2;
ELSE IF(AX>BX)
AX=AX+1;
ELSE
AX=AX-1;
a.
CMP AX, BX
JE L1
JL L2
INC AX
JMP ENDIF
L1: DEC AX
JMP ENDIF
L2: ADD AX, 2
ENDIF:
b.
CMP AX, BX
JE L1
JG L2
INC AX
JMP ENDIF
L1: DEC AX
JMP ENDIF
L2: ADD AX, 2
ENDIF:
c.
CMP AX, BX
JG L1
JL L2
INC AX
L1: DEC AX
JMP ENDIF
L2: ADD AX, 2
ENDIF:
d.
CMP AX, BX
JE L1
JG L2
INC AX
L1: DEC AX
L2: ADD AX, 2
ENDIF:
44- Choose one of high-level if-else construct that is equivalent to the following code:
Cmp AX,3
Jae next
Cmp Bx,2
Jae next
Mov CX,1
Jmp endif_st
next:
mov CX,0
Endif_st:
a.
b.
c.
d.
b.DH = Upper row number, DL = Left column number, CH = Lower row number, CL = Right
column number
c.CH = Upper row number, CL = Left column number, DH = Lower row number, DL = Right
column number
d.BH = Upper row number, BL = Left column number, DH = Lower row number, DL = Right
column number
47- Given the followin psudo code:
Ax =DX;
if(AX is odd)
AX= Ax+2 ;
else
AX = A+1;
Complete the blanks in the following Assembly code to be equivalent to the given (psudo
code) high-level code.
mov Ax,Dx
mov cl,2
Div cl
cmp ______,0
_____ next
add Ax,2
jmp endif
next: add ax,1
endif:
a.
AH
je
b.
AH
jne
c.
AL
je
d.
AL
jne
48- Which of the following will display a string whose address is in the dx register:
a.
mov ah, 9h
int 22h
b.None of these
c.
mov ah, 2h
int 20h
d.
mov ah, 9h
int 21h
e.
mov ah, 0h
int 21h