Question: The dot-product computation is discussed in Section 2.12.1. This type of computation can be used in the following signal-processing task. An input signal time sequence
The dot-product computation is discussed in Section 2.12.1. This type of computation can be used in the following signal-processing task. An input signal time sequence IN(0), IN(1), IN(2), IN(3), ..., is processed by a 3-element weight vector (WT(0), WT(1), WT(2)) = (1/8, 1/4, 1/2) to produce an output signal time sequence OUT(0), OUT(1), OUT(2), OUT(3), ..., as follows:
OUT(0) = WT(0) IN(0) + WT(1) IN(1) + WT(2) IN(2)
OUT(1) = WT(0) IN(1) + WT(1) IN(2) + WT(2) IN(3)
OUT(2) = WT(0) IN(2) + WT(1) IN(3) + WT(2) IN(4)
OUT(3) = WT(0) IN(3) + WT(1) IN(4) + WT(2) IN(5) . . .
All signal and weight values are 32-bit signed numbers. The weights, inputs, and outputs, are stored in the memory starting at locations WT, IN, and OUT, respectively. Write a RISC-style program to calculate and store the output values for the first n outputs, where n is stored at location N. Hint: Arithmetic right shifts can be used to do the multiplications
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
