Perform arithmetic computation, Engineering Mathematics

Assignment Help:

a.) Give a short sequence of machine instructions for the task "Add the contents of memory location A to those of memory location B, and place the answer in location C". You have available the following instructions:

Load Ri, LOC

Store Ri, LOC

which are the only instructions to transfer data between the memory and the general purpose registers. After operands have been loaded from memory into processor registers, arithmetic computation can be performed, using the instructions:

ADD Ri, Rj, Rk

SUB Ri, Rj, Rk

where i, j, k need not be distinct. Do not change the content of either location A or B.

b.) Suppose now that you have Move and Add instructions available with the formats:

Move LOC1, LOC2

ADD LOC1, LOC2

These instructions move or add a copy of the operand at the second location to the first location, overwriting the original operand at the first location. Either or both of the operands can be in the memory or the general purpose registers. Is it possible to use fewer instructions of these types to accomplish the task of part (a)? If yes, give the sequence.


Related Discussions:- Perform arithmetic computation

Bad Illustration, There is an illustration of a diesel engine sixteen cylin...

There is an illustration of a diesel engine sixteen cylinder that is supposed to be four-cycle, however GM never made engines of that size that were not two-cycle. The four valves

Diffusion equation, the solution of diffusion equation by using separation ...

the solution of diffusion equation by using separation of variables

Sinusoidal trigonometrical function, The displacement x meters of a mass fr...

The displacement x meters of a mass from a fixed point about which it is oscillating is given by x=2.3cos?10pt+4.2sin?10pt where t is the time in seconds Express the displaceme

Estimate lowest and highest byte memory, What are the lowest and highest a...

What are the lowest and highest addresses in a 2 20 byte memory in which a four-byte word is the smallest addressable unit?

Beta gamma functions, integral dx/root of sinx using beta and gamma functio...

integral dx/root of sinx using beta and gamma functions

Calculate the heat transfer coefficient , A house wall may be approximated ...

A house wall may be approximated as two 1.2 cm layers of fiber insulating board, a 8 cm layer of loosely packed asbestos, and 10 cm layer of common brick. Assuming convective heat

Conclusion of the argument, State each of the following arguments in abstra...

State each of the following arguments in abstract form. Recognize the premises and the conclusion of the argument. Then test whether the argument is valid or invalid. Describe how

Does the adverse reaction of nausea, The table summarizes results from a cl...

The table summarizes results from a clinical trial (based on data from Pfizer, Inc). Use a 0.05 significance level to test the claim that experiencing nausea is independent of whet

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd