Department of Computer Science University of San Francisco


Computer Science 315-01
Computer Architecture
Spring 2012

MWF 11:45-12:50, HR 535



Announcements


Professor: Peter Pacheco
Office: Harney 540
Phone: 422-6630
Email: domain: cs.usfca.edu, user: peter
Office Hours: MF 2-3, W 1-2 and by appointment

TA: Shah El-Rahman
Email: domain: cs.usfca.edu, user: snelrahman
Office Hours: MW 10:30-11:30, F 5-6, Tuesdays before a homework assignment is due 9-10 in HR 530 or HR 535

Class mailing list: From the email account that you want to use for class email, you should send an email to user cs315+subscribe in the domain cs.usfca.edu. Once your subscription is approved, you'll receive class announcements, and you can post messages by sending email to user cs315 in the domain cs.usfca.edu.

Course Syllabus (Here's a PDF Version.)


Homework Assignments


Examples

  1. A MIPS program to read two ints, add them, and print the results
  2. A MIPS program to read an int, determine whether it's nonnegative, and print the result
  3. A C program with a for loop
  4. A MIPS assembly language translation of the C program with a for loop
  5. Another MIPS assembly language translation of the C program with a for loop
  6. Yet another MIPS assembly language translation of the C program with a for loop
  7. A C program with a while loop
  8. A MIPS assembly language translation of the C program with a while loop
  9. A MIPS assembly language program with a function that prompts for and reads an int
  10. A MIPS assembly language program with functions read an int and print an int
  11. A C program that sorts a list of ints using selection sort
  12. A MIPS program that reads and prints a list of ints
  13. A MIPS program that uses selection sort to sort a list of ints
  14. A C program that uses a dynamically allocated array and selection sort to sort a list of ints
  15. A MIPS program that uses the sbrk system call to allocate storage for a list and then uses selection sort to sort the list
  16. A MIPS program that ``dynamically allocates'' stack storage for a list and then uses selection sort to sort the list
  17. An example showing how the product register is used.
  18. An example showing how the division algorithm works. This version shifts the divisor n bits and executes n+1 iterations.
  19. Another example showing how the division algorithm works. This version shifts the divisor n-1 bits and executes n iterations.
  20. An example showing how reordering can improve pipeline performance.
  21. An example showing how to do loop unrolling. Here's the original assembly code.
  22. Another loop example


Other Information

  1. Brief Introduction to Subversion
  2. David Patterson's article, ``The Trouble with Multicore''
  3. MIPS Reference Data (the ``Green Sheet'') (Copyright 2009 by Elsevier, Inc.)
  4. Summary of some MIPS instructions (Copyright 2009 by Elsevier, Inc.)
  5. SPIM system services (Copyright 2009 by Elsevier, Inc.)
  6. The SPIM Simulator website
  7. A MIPS tutorial. This site has a table with the codes for I/O in SPIM.
  8. A patched version of the MARS simulator
  9. A C program that converts a number from one base to two others
  10. A short table of values in different bases
  11. A list of possible topics for the first midterm
  12. A key to the first midterm.
  13. A corrected version of the linker example on pp. 143--145.
  14. Web page with Prof. Cruse's lecture notes and x86 examples
  15. A plot showing the growth in transistor count versus year.
  16. A list of possible topics for the second midterm
  17. A key to the second midterm
  18. A list of topics covered since the second midterm.



Peter Pacheco 2012-05-09