Project 1 – EECS 2110
Assembly Language Programming.
Due:
Description:
This project will be done in parts that will increase in complexity. Each portion is to be submitted online separately. In the assembly file for each section you must place a pair of comments identifying yourself and the section that you are working on.
# Name: Jerry Heuring # Project 1: Section 1
Details:
Section 1:
Using the MARS or SPIM simulator develop a program that will evaluate the following expression:
3 * n + n * (n – 1) – 15 where n is stored in a data location and is set to 15. Your program should use the system calls to print the result and to exit the program.
Section 2:
Using the MARS or SPIM simulator develop a program that will implement the following conditional statement.
If ( n is even) { n = n / 2;
} else { n = 3 * n + 1;
} In this case, n is to be input by the user (assume they input a non-negative value), the conditional is performed, and the resulting n is to be output. Again, use the system calls for input, output, and exiting the program. Hint: There is a remainder pseudoinstruction for the MIPS architecture that you can use to determine if the value is even or odd or you can look at bit 0 to determine if the value is even or odd.
Section 3:
You are to take the conditional from the previous section and build a loop around it to find the Collatz sequence. The structure of this would be:
while (n > 1) { If (n is even) {
n = n / 2; } else {
n = 3 * n + 1; } cout << n;
}
Section 4:
You are to write a leaf subprogram that will output the following information: Your Name Your favorite color Your favorite sports team
The main program should call your leaf routine and then exit using the system call.
Section 5:
Write a program with a leaf subprogram that will take two values in $a0 and $a1 and compute their greatest common divisor. The greatest common divisor should be returned in the $v0 register. The main program should input the values for $a0 and $a1 using system calls, call your subprogram, and then output the result using a system call.
Submission:
There are locations for you to submit the assignment available in BlackBoard. You need to upload only the .asm (assembly language) file. There is a different location for EACH section.
- Project 1 – EECS 2110
- Assembly Language Programming.
- Due:
- Description:
- Details:
- Section 1:
- Section 2:
- Section 3:
- Section 4:
- Section 5:
- Submission:
1. Study Questions on Christopher Smart’s “Jubilate Agno”
https://www.poets.org/poetsorg/poem/jubilate-agno-fragment-b-i-will-consider-my-cat-jeoffry
1). At the beginning of the poem, the speaker’s cat is described as the “servant of the Living God.” How, specifically, are the descriptions of the cat that follow this claim meant to make it seem plausible rather than absurd?
2). At least some of the assertions in the poem are absurd. Here’s an example: “For having consider'd God and himself he will consider his neighbor” (19). Within the context of the selection that you’ve been given to read, what might be the function of such an assertion?
3). In what ways might the final two lines of the selection be seen as changing the portrayal of the cat?
2. Study Questions on Gray’s “Elegy Written in a Country Churchyard” and “Ode on a Distant Prospect of Eton College”
https://www.poets.org/poetsorg/poem/elegy-written-country-churchyard
http://www.thomasgray.org/cgi-bin/display.cgi?text=odec
1). In “Elegy Written in a Country Churchyard” what is the difference between the “madding crowd” (l.73) and the people who are buried in the churchyard? How do the previous three stanzas help to explain this difference?
2). Much of “Elegy Written in a Country Churchyard” describes why the people who are buried are unlikely to be remembered. How does the speech of the “hoary headed swain” (ll. 98 116) try to persuade us that the people might be worth remembering?
3). Near the end of “Ode on a Distant Prospect of Eton College,” the speaker says that “Thought would destroy their paradise” (98). What is meant by “paradise” here? In what ways does the poem suggest that “thought” might “destroy” this “paradise”?
3. Study Questions on Goldsmith’s “The Deserted Village”
https://www.poetryfoundation.org/poems-and-poets/poems/detail/44292
1). In l.74, the speaker says “rural mirth and manners are no more.” What does the speaker mean by “rural mirth and manners”? What has caused them to disappear?
2). In ll.137-216, we are given a description of the lives of a preacher and a teacher who lived in the village. How do their lives differ from the lives of the rich described in ll.251-302?
3). Where will the poor residents of the village have to go? What sort of life awaits them there? Why?

Get help from top-rated tutors in any subject.
Efficiently complete your homework and academic assignments by getting help from the experts at homeworkarchive.com