Question
Write an assembly language program with five procedures using Y86. The program should have an input array, defined at the top of the program, with
Write an assembly language program with five procedures using Y86. The program should have an input array, defined at the top of the program, with an indeterminate number of values (but no more than 25), which appear in unsorted order. The program will need a Main procedure, a Count procedure,to determine the number of values in the input array, a Min procedure, to find the minimum value in the array, a Max procedure, to find the maximum value in the array, and a Reverse procedure, which will write the values in the input array to output in reverse order.
You are required to define the following at the top of your program:
(1) An input array label, Array; put thislabel at address 0x300.
(2) The actual array values(see below forsample input)
(3) A label at the end of the input array, Done, with no data value (that is, the label only)
(4) A label for a second array, RArray; put this label at address 0x400
(5) An output label, Output; put thislabel at address 0x500
(6) A stack label, Stack, at a high enough addressso that the stack will not grow into the output data, the input data, or the code; put thislabel at address 0xf00.
(7) Use rdx and rdi
Please make it so I can copy and paste the code. Thank you.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started