Exam 2 Assembly Flashcards
(41 cards)
The instruction SHL and SHR can be used on signed integers for bit shifting and preserve the sign
False
The instruction MUL preforms unsigned integer multiplication ad accepts 1,2, or 3 operands
False
The INC instructions takes a maximum of _operands
One
When using MASM, the first operand is the _____ operand
Destination
Symbolic constants can be used in MASM in lieu of variables when you have certain values in a program that never changes
True
Strings are stored as DWORD arrays
False, strings are stored as byte
The current location symbol in MASM is the dollar sign
True
A semi colon is used for single-line comments
True
The EQU directive can be used with the____ to determine the length of a string
Dollar sign
To get the address of an operand in MASM you can use the offset directive with the LEA instruction
False
Strings need to be null -terminated by using the literal value 0 as the last byte in MASM/NASM
True
The_____ directive is used to declare a 32 bit signed integer variable in MASM
sdword
IDIV can accept 1,2, or 3 operands
False
Labels must be followed___by
Colon
The instruction CWD converts the value in AX into DX:AX
True
In MASM to add a new line in a string it is represented by the____hexadecimal values
0dh, 0ah
___ are assembler specific commands that allow you todo many things, such as define variables, indicate memory segments, ad so on
Directive
A variable that contains a memory address is an example of___addressing
Indirect
When using QWORD value as an operand for the MUL instruction, the result will be stored in____
rdx:rax
The IDIV instruction can accept___operands
One operand
The NEG instructions changes a value from positive to negative by converting it into its____representation
Two’s complement
An array is a collection of data spaced equally memory addresses based on the data type and is aliased to the first element
True
Aligned data to ___ memory address can help the processor access data faster
Even address
Preforming division with DIV using a 32-bit divided implies that the dividend must be stored in___
Edx:eax