Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

2. (5 pts) Write a working Assembly macro code labeled 'add2' that is called from your main' routine and uses the register passing parameter technique.

image text in transcribed
2. (5 pts) Write a working Assembly macro code labeled 'add2' that is called from your main' routine and uses the "register passing" parameter technique. Your 'main' routine should: a. pass two parameters (x,y) into the macro 1 of 3 b. store the macro resul into a memory location labeled 'sum:'. The macro 'add2' does the following: a. accepts two parameters "REG1 and REG2" b. Adds REG1 and REG 2 and stores the result in REG3 c. Returns to your 'main' routine. See Section B.6 begin macro fill in macro code here> .endmacro main: .org 2048 fill in main code used to call the macro and store the macro's results into memory here org OxOffe 256 x: : 128 sum: (0 en 2. (5 pts) Write a working Assembly macro code labeled 'add2' that is called from your main' routine and uses the "register passing" parameter technique. Your 'main' routine should: a. pass two parameters (x,y) into the macro 1 of 3 b. store the macro resul into a memory location labeled 'sum:'. The macro 'add2' does the following: a. accepts two parameters "REG1 and REG2" b. Adds REG1 and REG 2 and stores the result in REG3 c. Returns to your 'main' routine. See Section B.6 begin macro fill in macro code here> .endmacro main: .org 2048 fill in main code used to call the macro and store the macro's results into memory here org OxOffe 256 x: : 128 sum: (0 en

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Machine Learning And Knowledge Discovery In Databases European Conference Ecml Pkdd 2014 Nancy France September 15 19 2014 Proceedings Part I Lnai 8724

Authors: Toon Calders ,Floriana Esposito ,Eyke Hullermeier ,Rosa Meo

2014th Edition

3662448475, 978-3662448472

More Books

Students also viewed these Databases questions

Question

18. If you have power, then people will dislike and fear you.

Answered: 1 week ago