Нех Address Instruction 100 Load /Load the first number to be doubled 101 Store Temp /Use Temp as a parameter to pass value to 102 Jns Subr /Store return address, jump to procedure 103 Store /Store first number, doubled 104 Load Y /Load the second number to be doubled /Use Temp as a parameter to pass value to /Store return address, jump to procedure 105 Store Temp 106 Jns Subr

Computer Networking: A Top-Down Approach (7th Edition)
7th Edition
ISBN:9780133594140
Author:James Kurose, Keith Ross
Publisher:James Kurose, Keith Ross
Chapter1: Computer Networks And The Internet
Section: Chapter Questions
Problem R1RQ: What is the difference between a host and an end system? List several different types of end...
icon
Related questions
Question
100%

dont post unnecessary answer else sure downvote and also dont post existing answer

Нех
Address
Instruction
100
Load
/Load the first number to be doubled
101
Store
Temp
/Use Temp as a parameter to pass value to Subr
102
Jns
Subr
/Store return address, jump to procedure
103
Store
/Store first number, doubled
104
Load
Y
/Load the second number to be doubled
105
Store
Тemp
/Use Temp as a parameter to pass value to Subr
106
JnS
Subr
/Store return address, jump to procedure
107
Store
Y
/Store second number, doubled
108
Halt
/End program
109
х,
Dec
20
10A
Y,
Dec
48
10B
Temp, Dec
10C
Subr, Hex
/Store return address here
10D
Load
Temp
/Ssubroutine to double numbers
10E
Add
Temp
10F
JumpI
Subr
END
Transcribed Image Text:Нех Address Instruction 100 Load /Load the first number to be doubled 101 Store Temp /Use Temp as a parameter to pass value to Subr 102 Jns Subr /Store return address, jump to procedure 103 Store /Store first number, doubled 104 Load Y /Load the second number to be doubled 105 Store Тemp /Use Temp as a parameter to pass value to Subr 106 JnS Subr /Store return address, jump to procedure 107 Store Y /Store second number, doubled 108 Halt /End program 109 х, Dec 20 10A Y, Dec 48 10B Temp, Dec 10C Subr, Hex /Store return address here 10D Load Temp /Ssubroutine to double numbers 10E Add Temp 10F JumpI Subr END
Please post answer in MARIE
1. Download the MARIE simulator from http://computerscience.jbpub.com/ecoa/2e/student_resources.cfm.
2. From the zip file copy the MarieSim.jar file to another directory (like the Desktop).
3. Run Marie.jar (This can be done on any system with the Java Runtime Environment).
4. Click on File, then Edit. This will bring up the MARIE editor. Type in the code from below. Do not include
the Hex Addresses, but do include the comments. Click on File and Save As to save your Assembly file
(.mas)
5. In the Editor, click on Assemble and then Assemble Current File. Fix any errors in the error list. If there are
no errors, the assembler will create a MARIE executable file (.mex). Back in the simulator, click File and
Load. Select the newly created .mex file. This loads your assembled program. You can now click Run and
Run. You can see if the program ran correctly by examining the memory at the locations X and Y (in this
program that is locations 109 and 10A).
6. If your program did not run correctly, you can debug it by Stepping through the program.
7. Once it works, modify it so that instead of hard coding X and Y in the program, Input a number (call it X)
using the Input instruction. Store the result of doubling Xin Y and then Output Y. This means you only
have to call Subr once.
Transcribed Image Text:Please post answer in MARIE 1. Download the MARIE simulator from http://computerscience.jbpub.com/ecoa/2e/student_resources.cfm. 2. From the zip file copy the MarieSim.jar file to another directory (like the Desktop). 3. Run Marie.jar (This can be done on any system with the Java Runtime Environment). 4. Click on File, then Edit. This will bring up the MARIE editor. Type in the code from below. Do not include the Hex Addresses, but do include the comments. Click on File and Save As to save your Assembly file (.mas) 5. In the Editor, click on Assemble and then Assemble Current File. Fix any errors in the error list. If there are no errors, the assembler will create a MARIE executable file (.mex). Back in the simulator, click File and Load. Select the newly created .mex file. This loads your assembled program. You can now click Run and Run. You can see if the program ran correctly by examining the memory at the locations X and Y (in this program that is locations 109 and 10A). 6. If your program did not run correctly, you can debug it by Stepping through the program. 7. Once it works, modify it so that instead of hard coding X and Y in the program, Input a number (call it X) using the Input instruction. Store the result of doubling Xin Y and then Output Y. This means you only have to call Subr once.
Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 6 steps with 4 images

Blurred answer
Recommended textbooks for you
Computer Networking: A Top-Down Approach (7th Edi…
Computer Networking: A Top-Down Approach (7th Edi…
Computer Engineering
ISBN:
9780133594140
Author:
James Kurose, Keith Ross
Publisher:
PEARSON
Computer Organization and Design MIPS Edition, Fi…
Computer Organization and Design MIPS Edition, Fi…
Computer Engineering
ISBN:
9780124077263
Author:
David A. Patterson, John L. Hennessy
Publisher:
Elsevier Science
Network+ Guide to Networks (MindTap Course List)
Network+ Guide to Networks (MindTap Course List)
Computer Engineering
ISBN:
9781337569330
Author:
Jill West, Tamara Dean, Jean Andrews
Publisher:
Cengage Learning
Concepts of Database Management
Concepts of Database Management
Computer Engineering
ISBN:
9781337093422
Author:
Joy L. Starks, Philip J. Pratt, Mary Z. Last
Publisher:
Cengage Learning
Prelude to Programming
Prelude to Programming
Computer Engineering
ISBN:
9780133750423
Author:
VENIT, Stewart
Publisher:
Pearson Education
Sc Business Data Communications and Networking, T…
Sc Business Data Communications and Networking, T…
Computer Engineering
ISBN:
9781119368830
Author:
FITZGERALD
Publisher:
WILEY