Bookmark and Share

Front Back
What is an assembler?
A utility program that converts source code programs from assembly language into machine language.
What are a few representative types of applicatons built with Assembly Language Applications?
1) Business applicaton for single platform
2) Hardware device driver
3) Business applicaton for multiple platforms
4) Embedded systems & computer games
What are the Specific Machine levels?
Level 5 - High Level Languages
Level 4 - Assembly Language
Level 3 - Operating System
Level 2 - Instruction Set Architecture
Level 1 - Microarchitecture
Level 0 - Digital Logic
What is the definition of Assembly Languge?
1) Level - 4
2) Instructions that have a one-to-one correspondence to machine language
3) Calls functions written at the operating system level (level 30
4) Programs are translated into machine language ( level 2)
What is an Instruction Set Architecture?
1) Level 2

2) Also Known as conventional machine language

3) executed by level 1 program
What are the standard sizes for integer storage and their bits?
Byte = 8 bits

Word = 16 bits

DoubleWord = 32 bits

QuadWord = 64 bits
What are the ranges for the following Integers? Byte; Word; DoubleWord; QuadWord
Byte = 0 to (2^8 - 1)
Word = 0 to (2^16 - 1)
DoubleWord = 0 to (2^32 - 1)
QuadWord = 0 to (2^64 - 1)
What are the ranges for the following Signed Integers? Byte; Word; DoubleWord; QuadWord
Byte = -2^7 to (-2^7 - 1) 
Word = -2^15 to (-2^15 - 1) 
DoubleWord = -2^31 to (-2^31 - 1) 
QuadWord = -2^63 to (-2^63 - 1)
What is the truth table for Boolean AND operator?
X     Y     X ^Y
F    F      F

F    T      F

T    F      F

T    T      T
What is the Truth Table for boolean OR operator?
X    Y    X V Y

F   F     F

F   T     T

T   F     T

T   T     T
What is a Basic Microcomputer Design?
1) clock synchronizes CPU operations

2) control unit (CU) coordinates sequence of execution steps

3) ALU performs arithmetic and bitwise processing
What is the instruction execution cycle?
1) Fetch

2) Decode

3) Fetch operands

4) Execute

5) Store output
Define a Mulit-Stage Pipeline.
1) Pipelining makes it possible for processor to execute instructions in paralles

2) instruction execution divided into discrete stages

3) More efficient use of cycles, greater throughput of instructions.
What is the number of cycles for n amount of pipelined execution stages?
K + (n - 1)

k = states

n = numer of required cycles
What is a Wasted cycle in a pipelined execution?
k + (2n -1)

k = states

n = number of required cycles
What do you understand about the superscalar architecture?
A superscalar processor has multiple execution pipelines.

K + n

k = states

n = number of required cycles
State the four steps in a simplified memory read cycle.
1) address placed on address bus

2) Read Line (RD) set low

3) CPU waits one cycle for memorey to respond

4) Read Line (RD) goes to 1, indicating that the data is on the data bus
What is Cache Memory?
1) High-speed expensice static RAM both inside and outside the CPU

a)Level-1 cache: inside the CPU

b) level-2 cache: outside the CPU

2)Cache hit: when data to be read is already in cache memory

3) Cache miss: when data to be read is not in cache memory
What do you understand about Multitasking?
1) OS can run multiple programs at the same time

2) Multiple threads of execution within the same program

3) Scheduler utility assigns a fiven amount of CPU time to each running program

4) Rapid switching of tasks

a) gives illusion that all lprograms are running at once

b) the processor must support task switching
Name the General Purpose Registers.
1) EAX - extended accumulator

2) ECX - extended Loop counter

3) ESP - extended stack pointer

4) ESI, EDI - index registers

5) EBP - extended frame pointer(stack)
Name the segment registers.
1) CS - code segment

2) DS - data segment

3) SS - stack segment

4) ES, FS, GS - additional segments
State the 6 Status Flags.
1) CF- Carry Flag; unsigned arithmetic out of range

2) OF - Overflow Flag; signed arithmetic out of range

3) SF - Sign Flag; result is negative

4) ZF - Zero Flag; result is a zero

5) AF - Auxiliary Carry; carry from bit 3 to bit 4

6) PF - Parity Flag; sum of 1 bits is an even number
What do you understand about Real-Address mode.
1) Application programs can access any area of memory
What do you understand about Segmented Memory.
Segmented memory addressing: absolute(linear) address is a combination of a 16-bit segment value added to a 16-bit offset
What do you understand about the Protected Mode.
Each program assigned a memory partition which is protected from other programs.
What do you understand about Paging.
1) Divides each segment into blocks called pages

2) Sum of all programs can be larger than physical memory

3) Part of running program is in memory, part is on disk

4) Virtual memory manager(VMM) - OS utility that manages the loading and unloading of pages

4) Page fault - issued by CPU when a page must be loaded from disk
What do you understand about instructions?
1) Assembled into machine code by assembler

2) Executed at runtime by the CPU

3) Parts

a) Label

b) Mnemonic

C) Operand

D) Comment
What do you understand about Labels?
1) Act as place markers

Marks the address(offset) of code         and data

2) Follow identifer rules

3) Data label

Must be unique

4) Code Label

target of jump and loop        instructions
What are Mnemonics?
1) instruction Mnemonics

a) "reminder"

What are Operands?
1) Constant (immediate value)

2) Constant expression

3) register

4) memory (data Label)
What is a Listing File?
1) Contains

a) source code

b) addresses

c) object code (machine language)

d) segment names

e) symbols (variables, procedures, and constants)
What is a Map File?
1) Information about each program segment

a) starting address

b) ending address

c) size

d) segment type
What do you understand about Little Endian Order?
All data types larger than a byte store their individual bytes in reverse order.  The least significant byte occurs at the first(lowest) memory address.
How do you calculate the size of a byte array?
list BYTE 10, 20, 30, 40

ListSize = ($ - list)
How do you calculate the size of a Word Array?
List WORD 1000H, 2000H, 3000h, 4000h

ListSize = ($ - list)/2
How do you calculate the size of a DoubleWord Array?
List DWORD 1, 2, 3, 4

ListSize = ($ - list) /4
What is some advantages and disavantages of Real-Address Mode Programming?
1) enerate 16-bit MS-DOS Programs

2) Advantages

a) enables calling of MS-DOS and        BIOS functions

b) no memory access restrictions

3) Disadvantages

a) must be aware of both segments and offsets

b) Cannont call Win32 functions

c) limited to 640K program memory
What are the three basic types of operands?
1) Immediate - a constant integer

2) Register - the name of a register

3) Memory - reference to a loction inmemory
What do you understand about Direct Memory Operand.
1) A direct memory operand is a nemed reference to storage in memory

2) The named reference (label) is automatically dereferenced by the assembler

mov al, var1


mov al, [var1]
What does the MOVZX instruction do?
When a copy form a smaller value into a larger destination, this instruction fills (extends) the upper half of the destination with zeros.
What does the MOVSX instruction do?
When a copy forma smaller value into a larger destination, in will fill the upper half of the destination with a copy of the source operand''s sign bit.
What does the XCHG instruction do?
Exchanges the values of two operands.  At least one operand must be a register.
What flags are affected by arithmetic?
Zero flag - destination equals zero

Sign flag - destination is negative

Carry flag - unsigned value out of range

Overflow flag - signed value out of range
What does the TYPE operator do?
Returns the size, in bytes, of a single element of a data declaration.
What does the LENGTHOF operator do?
Counts the number of elements in a single data declaration.
What does the SIZEOF operator do?
returns a value that is equivalent to multiplying lengthof by type
What does the Label Directive do?
1) Assigns an alterante label name and type to an existing storage location

2) Label does not allocate any storage of its own

3) Removes the need for the PTR operator
What is a Indirect Operand?
1) An indirect operand holds the address of a variable.
What is your understanding of a Link library?
1) A file containing procedures that have been compiled into machine code

2) Constructed form one or more OBJ files.
What 2 registers are mangaged by the CPU for the runtime stack.
SS(stack segment)

Esp(stack pointer)
x of y cards Next >|