SPP_MIPS_Translator

所属分类:机器翻译
开发工具:C++
文件大小:1562KB
下载次数:0
上传日期:2022-06-14 11:20:54
上 传 者sh-1993
说明:  将MAVN(高级MIPS汇编程序)汇编语言转换为MIPS 32位汇编语言的程序。它创造了...
(Program that translates MAVN(Higher level MIPS assembler) assembly language to MIPS 32bit assembly language. It creates zero-byte files.)

文件列表:
LICENSE (1071, 2022-06-14)
doc (0, 2022-06-14)
doc\DokumentacijaKlasa (0, 2022-06-14)
doc\DokumentacijaKlasa\class_liveness_analysis.png (472, 2022-06-14)
doc\DokumentacijaKlasa\class_my_file_handler.png (458, 2022-06-14)
doc\DokumentacijaKlasa\class_program_data.png (477, 2022-06-14)
doc\DokumentacijaKlasa\class_resource_allocation.png (474, 2022-06-14)
doc\DokumentacijaKlasa\class_symbol_table.png (473, 2022-06-14)
doc\DokumentacijaKlasa\class_syntax_analysis.png (469, 2022-06-14)
doc\DokumentacijaKlasa\class_visitor.png (1143, 2022-06-14)
doc\DokumentacijaKlasa\refman.rtf (313453, 2022-06-14)
doc\DokumentacijaKlasa\struct_no_more_spills_possible.png (583, 2022-06-14)
doc\HTML_NAPOMENA.txt (44, 2022-06-14)
doc\MIPS-instructions.pdf (140733, 2022-06-14)
doc\htmlDokumentacija (0, 2022-06-14)
doc\htmlDokumentacija\_constants_8h.html (19223, 2022-06-14)
doc\htmlDokumentacija\_constants_8h.js (1299, 2022-06-14)
doc\htmlDokumentacija\_constants_8h__dep__incl.dot (7398, 2022-06-14)
doc\htmlDokumentacija\_constants_8h_source.html (15924, 2022-06-14)
doc\htmlDokumentacija\_finite_state_machine_8cpp.html (4273, 2022-06-14)
doc\htmlDokumentacija\_finite_state_machine_8cpp__incl.dot (2621, 2022-06-14)
doc\htmlDokumentacija\_finite_state_machine_8cpp_source.html (48437, 2022-06-14)
doc\htmlDokumentacija\_finite_state_machine_8h.html (6315, 2022-06-14)
doc\htmlDokumentacija\_finite_state_machine_8h.js (226, 2022-06-14)
doc\htmlDokumentacija\_finite_state_machine_8h__dep__incl.dot (2194, 2022-06-14)
doc\htmlDokumentacija\_finite_state_machine_8h__incl.dot (2164, 2022-06-14)
doc\htmlDokumentacija\_finite_state_machine_8h_source.html (12608, 2022-06-14)
doc\htmlDokumentacija\_i_r_8cpp.html (8031, 2022-06-14)
doc\htmlDokumentacija\_i_r_8cpp.js (181, 2022-06-14)
doc\htmlDokumentacija\_i_r_8cpp__incl.dot (2358, 2022-06-14)
doc\htmlDokumentacija\_i_r_8cpp_source.html (110619, 2022-06-14)
doc\htmlDokumentacija\_i_r_8h.html (12358, 2022-06-14)
doc\htmlDokumentacija\_i_r_8h.js (648, 2022-06-14)
doc\htmlDokumentacija\_i_r_8h__dep__incl.dot (4030, 2022-06-14)
doc\htmlDokumentacija\_i_r_8h__incl.dot (2136, 2022-06-14)
doc\htmlDokumentacija\_i_r_8h_source.html (64846, 2022-06-14)
doc\htmlDokumentacija\_lexical_analysis_8cpp.html (4532, 2022-06-14)
... ...

# SPP_MIPS_Compiler The program that translates MAVN(Higher level MIPS assembler) assembly language to MIPS 32bit assembly language. All the generated files are zero-byte files. ## Implementation details - Implemented using the visitor design pattern, - In each phase of the compilation process new algorithm visits the symbol table that contains the relevant data. - Special logic was implemented to allow the compiler to optimize programs so only two registers are used. - Lexical analysis - Finite state machine - Syntax analysis - Recursive descent - Semantic analysis - Liveness analysis - Graph coloring register allocation - Renumber: discover live range information in the source program. - Build: build the interference graph. - Coalesce: merge the live ranges of non-interfering variables related by copy instructions. - Spill cost: compute the spill cost of each variable. This assesses the impact of mapping a variable to memory on the speed of the final program. - Simplify: construct an ordering of the nodes in the inferences graph - Spill Code: insert spill instructions, i.e loads and stores to commute values between registers and memory. - Select: assign a register to each variable. - Assembly instructions code generation - All generated programs are zero-byte files - All the code is encoded and placed in the name of the files - File system sees these files as if they have zero bytes
compiler-phases

Ilustration 1 - Phases of the compilation process.

graph-coloring-register-allocation

Ilustration 2 - Graph coloring register allocation.


近期下载者

相关文件


收藏者