Computer Organization and Architecture

Assembly Language Optimization Assignment

Due: Monday, November 3

This assignment extends the study of optimization begun in lab on Optimization of Assembly Language Code. In that lab, the optimizer of the compiler produced smaller and better assembly language code than the basic compiler. However, additional savings are possible by eliminating unnecessary intermediate variables and by using registers more efficiently.

Implement these changes to yield a more efficient program that prints the table. To get started, copy the Pascal or C program from that lab to your account, generate an assembly listings using the appropriate pc or gcc command, and edit the resulting file to include your improvements.

After you have improved the assembly program (table.s), you may run the result by assembling, linking, and executing the finished program. See the Assembly Language Says 'Hi' material for more details.

Turn in your programs following the format identified in the C programming lab.

This document is available on the World Wide Web as

created October 1, 1997
last revised October28, 1997