Question

a)in what format are negative numbers stored in the Marie architecture? b)how does the decimal (base...

a)in what format are negative numbers stored in the Marie architecture?
b)how does the decimal (base 10) number -12 appear in the MARIEsim memory display?
c)the Marie instruction format has a 4-bit opcode,leaving the room for a 12-bit operand. what limit does this place on instructions and addressable memory in MARIE?

0 0
Add a comment Improve this question Transcribed image text
Answer #1

a)

For 32 bit DWORD the integer range is from –2147483648 to 2147483647 or in hex -0x80000000 to 0x7FFFFFFF.

So the number -1 is present like 0xFFFFFFFF. (Like counter underflow)

If the high (31) bit is set then the number is negative. To make positive number from negative (negation) you must make compement of number and add 1.

Example:

0xFFFFFFFE //-2
xor 0xFFFFFFFF //binary complement
---------------
0x00000001 //result of complement
+ 0x00000001 //add 1
---------------
0x00000002 //Result of negation is 2


b)

.MODEL SMALL
.STACK 100H

.DATA
PROMPT_1 DB 'Enter a Decimal number (-32767 to 32767) : $'
PROMPT_2 DB 0DH,0AH,'The given Decimal number is : $'
ILLEGAL DB 0DH,0AH,'Illegal character. Try again : $'

.CODE
MAIN PROC
MOV AX, @DATA ; initialize DS
MOV DS, AX

LEA DX, PROMPT_1 ; load and display the string PROMPT_1
MOV AH, 9
INT 21H

CALL DECIMAL_INPUT ; call the procedure DECIMAL_INPUT

LEA DX, PROMPT_2 ; load and display the string PROMPT_2
MOV AH, 9
INT 21H

CALL DECIMAL_OUTPUT ; call the procedure DECIMAL_OUTPUT

MOV AH, 4CH ; return control to DOS
INT 21H
MAIN ENDP

Add a comment
Know the answer?
Add Answer to:
a)in what format are negative numbers stored in the Marie architecture? b)how does the decimal (base...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • The unsigned decimal value (1,036)(base 10) is to be stored as a 16-bit word in memory....

    The unsigned decimal value (1,036)(base 10) is to be stored as a 16-bit word in memory. a. Show the 16-bit unsigned binary representation of (1,036)(base 10). b. Show the 4-digit unsigned hexadecimal representation of (1,036)(base 10). c. The unsigned binary value of part (a) should be stored using two bytes of a byte-addressable memory at locations 400 and 401. Specify the hexadecimal value in each byte for a “big endian” instruction set architecture. Give your answer by showing a table.

  • For questions 3-4, provide the full MARIE RTN (register transfer notation) for these new MARIE operations....

    For questions 3-4, provide the full MARIE RTN (register transfer notation) for these new MARIE operations. Your answer should include the fetch, decode, operand fetch (if necessary), execution and store result (if necessary) stages. When you see X in these instructions, this is a main memory address (the last 12 bits of the 16-bit instruction) – refer to this as IR[11..0) and not X in your RTN. 3) AutoIncrLoad X - the autoincrement addressing mode is used to access a...

  • 5) True or False. HALT is actually a TRAP instruction. Using operate type instructions only place the value 45 in RI . 6) 7) True or False. In a Von Neumann machine data and instructions both resi...

    5) True or False. HALT is actually a TRAP instruction. Using operate type instructions only place the value 45 in RI . 6) 7) True or False. In a Von Neumann machine data and instructions both reside in memory. What is the opcode for GETC in LC-3. 8) (i)True or False. In LC-3 all memory can be accessed with 16 bits. G) Give the decimal value for this 2's complement bit pattern: 111111110001 (k) Give the decimal number 119 as...

  • 26. The is a group of bits that tells the computer to perform a specific operation...

    26. The is a group of bits that tells the computer to perform a specific operation A). program counter B). Opcode C). register D). microoperation 27. A condition called occurs in unsigned binary representation of a number when the result of an arithmetic operation is outside the range of allowable precision for the given number of bits. A). underflow B). 2's complement C). overflow D) bitwise complement 28. An iteration of the fetch-decode-execute cycle includes which of the following events?...

  • 6 - What decimal number does the bit pattern 0xC0B00000 represent if it is: • [2...

    6 - What decimal number does the bit pattern 0xC0B00000 represent if it is: • [2 pts] A two's complement integer? • [2 pts] An unsigned integer? • [2 pts] A floating point number assuming the IEE 754 single precision format 7 - Perform the following calculations assuming that the values are 8-bit decimal integers stored in two's complement format. Be sure to consider the possibility of overflow. • [2 pts] 10101010 + 00110011 • [2 pts] 10101010 – 00110011...

  • Given the interpretation and the word(s), tell what characters or decimal numbers are stored in main memory by the desig...

    Given the interpretation and the word(s), tell what characters or decimal numbers are stored in main memory by the designated word(s). We assume our computer uses 8 bits for characters and 16 bits for binary integers: (show your work) Word I 1011 0010 0010 0000 Word II 0100 1001 0101 0010 1) Binary Integer - Word I 2) Character (ASCII) – Word II _____________________________________________________________________________________________________________________________________________________ For the following problems, assume that our computer uses 16 bits for binary integers. Find the...

  • 5 Exercises Now that everything is working you can try the following exercises. To complete them you will need to refer...

    5 Exercises Now that everything is working you can try the following exercises. To complete them you will need to refer to the documentation in Appendix A- The MiteASM Assembler and Appendix B - The MiteFPGA Processor. Write an assembly language program for an over counter for a cricket umpire. This should display a count on the 7-segment display. The count should increase by 1 when button 0 is 1. pressed. It should reset to 0 when button 1 is...

  • There is an example below Now that everything is working you can try the following exercises. To complete them you wi...

    There is an example below Now that everything is working you can try the following exercises. To complete them you will need to refer to the documentation in Appendix A The MiteASM Assembler and Appendix B The MiteFPGA Processor. Write an assembly language program for an over counter for a cricket umpire. This should 1. display a count on the 7-segment display. The count should increase by 1 when button 0 is pressed. It should reset to 0 when button...

  • To write a C program (not C++) that converts numbers between Decimal and IEEE-754 format and...

    To write a C program (not C++) that converts numbers between Decimal and IEEE-754 format and vice versa. Inputs: Number in Decimal format (including special case of 0) Number in IEEE-754 format (including special cases) Output: Equivalent number in IEEE-754 format Equivalent number in Decimal Specification: The program converts a number based on choosing from a menu of choices, where each choice calls the appropriate procedure, where the choices are: Decimal to IEEE-754 conversion IEEE-754 to Decimal conversion Quit program...

  • Group Project 1 The Micro-1 Processor Simulation <Micro-1 Computer> Here's the organization of a computer equipped...

    Group Project 1 The Micro-1 Processor Simulation <Micro-1 Computer> Here's the organization of a computer equipped with a Micro-1 processor Memory contains an array of integer cells: int cell[] = new int[CAP]; where CAP is the capacity of memory. Initially this is set to 256. Internally, the Micro-1 processor is equipped with eight 32-bit data/address registers and two 32 bit control registers: PC, the program counter, contains the address of the next instruction to execute. IR, the instruction register, contains...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT