ECE3724/CS3124 – Microprocessors I Spring, 2002Test #1 Rework1. Perform the following operations giving the final result as an 8-bit hex representation. Also determine which flags will be set. Give the flag result as a four-bit value where 1 means the flag is set and 0 means cleared. Write the flag settings in the following order – V(Overflow), N(negative), C(Carry), Z(Zero). $6F $FF $ 93+ $4D +$01 +$F2 Answer $ Answer $ Answer $ Flags Flags Flags 2. Assume the memory contents below And the following register contents:DS: 137E, CS: 1390, SS: 1392, ES: 1393, AX: 0137, BX: 010E, BP: 000A, SP: 000F, SI: 0003Give the final value of AX. Assume that before each instruction, the registers equal the values above.a) mov ax, bx ___________________b) mov ax, [bx +5] _______________c) mov ax, [BP] _________________d) mov ax, [010A] _______________e) mov ax, 010A ________________f) mov ax, [SP] _________________g) mov ah, bl ___________________3. For the register contents of the previous problem, what 20-bit physical address would be used to access data referenced by the SI register.4. Draw a block of data that could be accessed using 24 address lines. Write the beginning addresses(assume 0) and the ending addresses that would be accessible (write the values in hex). How many bytes can be accessed? _________ Also mark off a block that could be used for an 8086 DOS code segment (beginning at 0). Show the ending address for this block (in hex). How many Hex digits does it take to represent this segment block? __________5. Why does the 8086 use segment registers and offset registers to indicate a physical address?6. What are the six virtual machine levels? At what level of hardware would one find the specifications for the registers and the ALU?_________________________ At what level are the mnemonic instructions for assembly language defined?_________________________7. Draw a diagram of the three main parts of a computer. Place on the diagram the three buses. Assuming there are 64M of memory, correctly label the width of the associated bus. If each memory location is 1 bytewide, correctly label the width of the associated bus. If 4 different values are needed to distinguish betweenI/O reads and writes and memory reads and writes, correctly label the width of the associated bus.8.What allows the 8086 processor to have pipelining? What is pipelining? How does it work? Why is it more efficient than earlier processor cycles of operation?9. List the steps needed to prepare and execute an assembler program. Include what extensions would be associated with files from each step.10.Give the basic structure on an assembly code instruction. What parts are optional?11. Write an assembly program that converts a string containing lowercase letters to uppercase letters. (A lowercase character can be converted to uppercase by subtracting 32 from its ascii value). Make certain to include all necessary parts of the template including comments. Use the linestring1 db “teststring”,’$’for your data.Use Int 21 function 9 to output the converted string to the screen. Function 9 requires that DS:DX = address of the string.Most of the credit will be for the template being
View Full Document