MIPS Assembler

When we introduced MIPS Assembly Language (Section 3), we discussed the MIPS assembler, a tool that converts each assembly instruction to its corresponding machine instruction. In this sec- tion, we discuss what it takes to implement such a tool.

An assembler must make sense of each line in the assembly language program and determine that there are no syntax errors or violations of Assembly Language rules. This is the Analysis stage. Once the assembler has determined that the input is a legal program, the Synthesis stage generates the output, the equivalent MIPS Machine Language program.

Analysis

Synthesis