Exam 3

Ace your homework & exams now with Quizwiz!

In the following instruction sequence, show the changed values of AL where indicated, in hexadecimal: mov al,9Ch not al

63h

What will be the hexadecimal value of AL after these instructions execute? mov al,3Ch or al,82h

BEh

Which answer choice shows the correct values of the Carry, Zero, and Sign flags after the following instructions execute? mov al,00110011b test al,2

CF = 0, ZF = 0, SF = 0

What will be the value of ECX when the following sequence of instructions has executed? push 5 push 10 pop ebx pop eax pop ecx

Cannot be determined

The USES operator, coupled with the PROC directive, lets you list the names of all registers modified within a procedure that you want the values changed after the RET.

False

The XOR instruction can be used to generate the two's complement of an integer.

False

The XOR means as long as one value is 1 the resulting value is also 1.

False

The NOT instruction inverts all of the bits in an operand.

True

The PUSHAD instruction pushes all the 32-bit general-purpose registers on the stack.

True

The Parity flag indicates whether the lowest byte of a destination operand has an even number of 1 bits.

True

What will be the value of EAX when the following sequence of instructions has executed? Push 5 push 10 pop ebx pop eax

5

What will be the hexadecimal value of AL after these instructions execute? mov al,0CFh and al,2Bh

0Bh

Which of the following code sequences assigns the value 10h to EBX? There may be multiple answers.

1 and 4

In the following instruction sequence, show the changed values of AL where indicated, in binary: mov al,00111100b or al, 82h

1011 1110

What will be the value of EAX when the following sequence of instructions has executed? push 5 push 10 push 20 pop eax

20

Use the following data for this question. All values are signed: .data val1 SDWORD ? val2 SDWORD ? Which selection correctly implements the following pseudocode? while( int2 >= int1 ) { add ebx,2 if( ebx > int2) mov ebx,0 else mov ebx,int1 }

3rd option on the test

What will be the hexadecimal value of AL after these instructions execute? mov al,94h xor al,37h

A3h

The AND and OR always clear the Sign and Overflow flags.

False

The AND and TEST perform exactly the same operations.

False

The ESP register always points to the next available position (NAP) where a new value will be pushed on the stack

False

The PUSH instruction copies a value from the stack to an operand before decrementing the stack pointer

False

The RET instruction pops the value pointed to by EBP off the stack into the instruction pointer..

False

The TEST instruction always alters the destination operand.

False

The destination operand of the OR instruction cannot be a memory operand.

False

Which of the following are true about the PUSH instruction?

It decrements the stack pointer (by 2 or 4) and copies the operand into the stack at the location pointed to by the stack pointer

A link library contains procedures that have already been assembled into object code.

True

A nested procedure call occurs when a called procedure calls another procedure before the first procedure returns

True

ANDing an operand with 1 sets the zero flag if the operand was originally an even number.

True

For any two integers n and m, ((n XOR m) XOR m) produces n

True

In a finite-state machine, transitions between states usually occur when a new value has been read from input.

True

In a stack, the first value pushed on a stack is the last one to be removed.

True

The AND and OR always clear the Carry and Overflow flags

True

The RET instruction pops the stack into the instruction pointer

True

When the POP instruction executes, the ESP register is incremented after the value it points to is copied from the stack.

True

Which of the following CALL instructions writes the contents of EAX to standard output as a signed decimal integer? call WriteInt call WriteInteger call WriteDec call WriteHex

call WriteInt

Which of the following code sequences assigns the value 10h to EBX? (The following question may have more than one correct answer. Mark all correct)

mov edx,20h push edx mov ecx,10h push ecx pop ebx pop edx push 30h push 10h push 20h pop edx pop ebx pop eax 1 and 2 above ( Correct Answer)


Related study sets

Environmental Science Quizzes part 2

View Set

Chapter 12 - Financial Statement Analysis

View Set

GEOG_3153_Quiz 03-the American Conservation Movement to 1914

View Set