subject

Example 1 .data
var1 BYTE 10
var2 BYTE 20
var3 BYTE 30
.code
mov esi, OFFSET var2
mov edi, OFFSET var1
cmpsb
ja L1
jb L2
je L3
5.To which label will the program jump in Example 1?
a. L1
b. L2
c. L3
d. cannot be determined from the information given

6.In Example 1, where will ESI point after the CMPSB instruction executes?
a. at var1
b. at var2
c. at var3
d. cannot be determined from the information given

7.If var1 and var2 were changed to type SWORD in Example 1, what change(s) would have to be made to the instructions in the code segment?
a. change CMPSB to CMPSW
b. change CMPSB to CMPSD
c. change JA to JG, and change JB to JL
d. none of the above
Example 2
1: .data
2: str1 BYTE "1324A2342424",0
3: .code
4: mov edi, OFFSET str1
5: mov al,'A'
6: cld
7: repne scasb
8: mov bl,[edi]

8.In Example 2, assume that str1 is located at offset 00040010h. What will be the value of EDI after line 7 executes?
a. 00040010h
b. 00040013h
c. 00040014h
d. 00040015h
9.In Example 2, if we change line 6 to "std", what value will be moved to BL after line 8 executes?
a. ASCII code of "4"
b. ASCII code of "A"
c. ASCII code of "2"
d. cannot be determined
10. In Example 2, if we change line 7 to "repe scasb", what value will be moved to BL after line 8 executes?
a. ASCII code of "3"
b. ASCII code of "A"
c. ASCII code of "2"
d. cannot be determined
11.Which letter choice contains instructions that will fill all elements of arrayW with h?
arrayW WORD 50 DUP(?)
a.
mov ax,0h
mov edi, OFFSET arrayW
mov ecx, SIZEOF arrayW
cld
rep stosb
b.
mov ax,0h
mov edi, OFFSET arrayW
mov ecx, LENGTHOF arrayW
cld
rep stosw
c.
mov ax,0h
mov esi, OFFSET arrayW
mov ecx, SIZEOF arrayW
std
rep stosw
d.
mov ax,0h
mov esi, OFFSET arrayW
mov ecx, LENGTHOF arrayW
cld
repz stos
Example 3
1: .data
2: str1 BYTE "AAAX",0
3: str2 BYTE 10 DUP(0FFh)
4: .code
5: mov edi,0
6: L1: mov al,[str1+edi]
7: cmp al,0
8: je L2
9: mov [str2+edi],al
10: inc edi
11: jmp L1
12: L2:
After Example 3 executes, what value will be stored at offset [str2+4]?
a. 0FFh
b. ASCII code of "X"
c. 00h
d. cannot be determined
13. In Example 3, if we changed lines 7, 8, and 9 to the following, what value would be stored at offset [str2+4] after the loop finished?
7: mov [str2+edi],al
8: cmp al,0
9: je L2
a. 0FFh,
b. ASCII code of "X"
c. 00h
d. cannot be determined

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 23.06.2019 05:20
Which operating system is a version of linux?
Answers: 1
question
Computers and Technology, 23.06.2019 07:00
To produce a starlight effect in her photograph, lina should choose the filter for her camera.
Answers: 1
question
Computers and Technology, 23.06.2019 21:30
Which of the following includes the three primary network access technologies? dsl, cable modem, broadband lan, wan, man voip, uc, iptv tcp/ip, ftp, dhcp
Answers: 2
question
Computers and Technology, 23.06.2019 21:30
Enzo’s balance sheet for the month of july is shown. enzo’s balance sheet (july 2013) assets liabilities cash $600 credit card $4,000 investments $500 student loan $2,500 house $120,000 mortgage $80,000 car $6,000 car loan $2,000 total $127,100 total $88,500 which expression finds enzo’s net worth?
Answers: 1
You know the right answer?
Example 1 .data
var1 BYTE 10
var2 BYTE 20
var3 BYTE 30
.code
mov esi,...
Questions
question
Mathematics, 28.04.2021 18:20
question
History, 28.04.2021 18:20
question
Mathematics, 28.04.2021 18:20
question
Social Studies, 28.04.2021 18:20
Questions on the website: 13722362