Docsity

The MAX PLUS Software, The Decoder, The Assembler Programs - Notes | CS 350, Study Guides, Projects, Research of Programming Languages

Toggle sidebar
bg1
Problems faced:
Thanks to the members of team and the fact that we emphasized on testing and
optimization, we didn't have serious problems with the design and logic of the hardware
components.
The MAX PLUS Software:
All of us were relatively new to this software package and sometimes we faced technical
problems with it. For example it was very easy to ruin the ".scf " simulation file so that
won't work at all and the only solution would be to start a new project. Or, once, we set
extended the simulation time to 10 seconds and the system crashed. We had some
problems with the ability to name the inputs and outputs of the different components, but
then we discovered to wire component that fixed this problem. There were some small
issues with this software but by using the built-in help system and resources from the
web, those issues were easily resolved. Especially, we had hard time to combine the
assembler and the final design of CPU.
The Decoder:
The one thing that required thorough thinking was the decoder. First we built the truth
table for all the inputs and outputs. Then, having in mind the structure of the different
types of operations and using Don't Cares, we redid the table. From it, we generated the
Boolean expressions and optimized them as much as possible with De Morgan's Laws
and similar techniques. Due to this optimization we could reduce the number of gates
needed to implement the decoder with almost 35%.
The Assembler programs:
Once put all together, it was really hard to do any kind of debugging of the CPU and see
where was the cause of a particular problem if such occurred. That's why we had to make
sure out assembly code for the two algorithms of multiplication worked perfect before
test it with our CPU. Two-pass assembler created using C++ language. The assembler
converts instructions into the format that can be directly downloaded into the ROM and
RAM. The assembler is using registers $1, $2, $3, and $4 that correspond to registers 00,
01, 10, and 11 correspondingly. Algorithm the Assembler program is using to output the
results into .mif files: at the beginning assembler is reading the labels that are located
either in text or the data segment of the MIPS program. Each label has its own name,
position (address) and the location (text or data segment). Whenever the program reads
labels, it stores them in the apvector of labels.
After the program is done reading the labels, it is ready to output the data segment of the
MIPS program in binary format to the file RAM.mif. Therefore, it parses the data
segment of the MIPS program, converts decimal numbers to binary and outputs the result
pf2

Partial preview of the text

Download The MAX PLUS Software, The Decoder, The Assembler Programs - Notes | CS 350 and more Study Guides, Projects, Research Programming Languages in PDF only on Docsity!

Problems faced:

Thanks to the members of team and the fact that we emphasized on testing and optimization, we didn't have serious problems with the design and logic of the hardware components. The MAX PLUS Software : All of us were relatively new to this software package and sometimes we faced technical problems with it. For example it was very easy to ruin the ".scf " simulation file so that won't work at all and the only solution would be to start a new project. Or, once, we set extended the simulation time to 10 seconds and the system crashed. We had some problems with the ability to name the inputs and outputs of the different components, but then we discovered to wire component that fixed this problem. There were some small issues with this software but by using the built-in help system and resources from the web, those issues were easily resolved. Especially, we had hard time to combine the assembler and the final design of CPU. The Decoder: The one thing that required thorough thinking was the decoder. First we built the truth table for all the inputs and outputs. Then, having in mind the structure of the different types of operations and using Don't Cares, we redid the table. From it, we generated the Boolean expressions and optimized them as much as possible with De Morgan's Laws and similar techniques. Due to this optimization we could reduce the number of gates needed to implement the decoder with almost 35%. The Assembler programs : Once put all together, it was really hard to do any kind of debugging of the CPU and see where was the cause of a particular problem if such occurred. That's why we had to make sure out assembly code for the two algorithms of multiplication worked perfect before test it with our CPU. Two-pass assembler created using C++ language. The assembler converts instructions into the format that can be directly downloaded into the ROM and RAM. The assembler is using registers $1, $2, $3, and $4 that correspond to registers 00, 01, 10, and 11 correspondingly. Algorithm the Assembler program is using to output the results into .mif files: at the beginning assembler is reading the labels that are located either in text or the data segment of the MIPS program. Each label has its own name, position (address) and the location (text or data segment). Whenever the program reads labels, it stores them in the apvector of labels. After the program is done reading the labels, it is ready to output the data segment of the MIPS program in binary format to the file RAM.mif. Therefore, it parses the data segment of the MIPS program, converts decimal numbers to binary and outputs the result

to RAM.mif with decimal addresses and binary data. During the next step, the program is parsing the text segment of the program. It substitutes instructions with correct binary representation given in the table "IIT Eight-bit RISC" and substitutes labels with addresses produced in the first step. The result is outputted to the file ROM.mif with decimal addresses and binary data.