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 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

  Write a function in linux assembly

Write a function in Linux assembly

  Analog measurements

Prepare an assembly program for the correctly measures the wind direction

  Design a simple digital clock

Design a simple digital clock

  Write an assembly program

Prepare an Assembly program that reads in a number of cents.

  Write an assembly language program

Write an assembly language program for encrypting alphabates of a string

  Greatest common divisor of integers-masm assembly language

Must be done in MASM assembly language: Greatest common divisor of two integers is largest integer which will evenly divide both integers. GCD algorithm involves integer division in a loop.

  Write assembly program-find right admission price to movie

Write the Assembly program to find correct admission price to movie. Price of admission to a movie is $7 for kids (under 12) and $9 for adults.

  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 assembly program print binary representation-integers

Write the assembly program called hw6_ex1, stored in file hw6_ex1.asm. This program must prompt user to enter signed 32-bit integer. Program must print out binary representation of the integer.

  Allot op-codes and add microcode to microprogram

Allot op-codes and add microcode to microprogram of Mic-1 to implement following instructions which are then included with IJVM instruction set.

  Write mips assembly program to read two non-negative numbers

Write MIPS assembly program to repeatedly read two non-negative integers and print integer product and quotient without using multiplication and division instructions.

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