Create a assembly language subroutine mulsum that takes an

Assignment Help Assembly Language
Reference no: EM13346706

Create a assembly language subroutine MULSUM that takes an array named A containing n bytes of positive numbers, and fills two arrays, array B containing n words and array C containing n long words as given:

Sum = 0;

for(i = 0; i<n; i++)
   Sum = A[i] + Sum;
   if(Sum is an EVEN number) then

         B[i] = Sum;
 else
C[i] = Sum * A[i];
 end if
end for

In computing the expression Sum * A[i] you are NOT allowed to use the MULTU, or MULTS instructions, therefore, you are to find another way to evaluate this expression. This program passes all the required parameters to subroutine MULSUM by pushing them on stack.

a) Write the main program

b) Write the subroutine MULSUM

c) Show the stack frame for entire program and clearly label SP at different stages of program.

Reference no: EM13346706

Questions Cloud

A the rising stock market implies an increase in wealth at : a the rising stock market implies an increase in wealth at least as measured on paper. if we assume that some of this
A when the bank of canada sells the government bonds to a : a when the bank of canada sells the government bonds to a commercial bank the commercial bank experiences a decline in
Mountain man brewing company bringing the brand to light : mountain man brewing company bringing the brand to light case to complete a formal written case analysis.analysis will
Design and modelling of adsorption chromatography based on : design and modelling of adsorption chromatography based on isotherm dataadsorption systems are most commonly set-up as
Create a assembly language subroutine mulsum that takes an : create a assembly language subroutine mulsum that takes an array named a containing n bytes of positive numbers and
Create the following graph which contains a piecewise : create the following graph which contains a piecewise function where a line exists in the first interval a parabola in
Question 1the naca 4412 airfoil has a mean camber line : question 1the naca 4412 airfoil has a mean camber line given byby using thin airfoil theory calculatea. its zero-lift
1 write a short technical report on one of the subsequent : 1. write a short technical report on one of the subsequent digital communication techniques-a. frequency division
Create the main window shown here you may use any layout : create the main window shown here. you may use any layout manager or you may lay the components out manually.when a

Reviews

Write a Review

Assembly Language Questions & Answers

  Create simple 8-bit alu using add-subtract-shift functions

Create a simple 8-bit ALU. Requirements:The eight functions that you will implement are: add, subtract, and, or, shift left logical, less than, shift right logical.

  Write a mips assembly language program

Write a MIPS assembly language program that prompts for a user to enter a series of floating point numbers and calls read_float to read in numbers and store them in an array. Then the program should display the array content on the console window. Th..

  Write two (2) arm assembly language subroutines

Write two (2) ARM assembly language subroutines, called output_char and read_char

  Program that converts the temperature

Write a program that converts the temperature F in Farenheit to C in Celsius using C = (F-32)*5/9. For ease of programming you can display the result in fractions

  Write a function in linux assembly

Write a function in Linux assembly

  Register address machine

Express the statement X= (A*B)-(C*D)-E in the assembly language of each of 0- memory address machine, 3-register address machine with 3 registers R1,R2,R3, and 2-memory-register-address machine with three registers R1,R2, R3. Your solution should use..

  Write a nonrecursive version of the factorial procedure

(Nonrecursive Factorial) Write a nonrecursive version of the Factorial procedure (Section 8.3.2) that uses a loop. (A VideoNote for this exercise is posted on the Web site.) Write a short program that interactively tests your Factorial procedure.

  Design a simple digital clock

Design a simple digital clock

  Bios interrupt int 21 to read current system time

Write a program in assembly language which uses BIOS interrupt INT 21 to read current system time and displays it on the top-left corner of the screen.

  Multiply by using shift and add instructions

How does real time PCR work to quantify the initial amount of the DNA template? How should the method be modified to quantify the initial amount of RNA template extracted from tissue or cells?

  Program that prints your full name on the screen

write an assembly language program that prints your full name on the screen

  Create a assembly language subroutine

Create a assembly language subroutine MULSUM that takes an array named A containing n bytes of positive numbers, and fills two arrays, array B containing n words and array C containing n long words

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