A compiler for the simple-programming-language SPL, translating source code all the way to Eco32-Assembly. Built as the Compilerbau practicum at THM.
The compiler runs through the classic phases: a JFlex scanner tokenizes the source, a CUP parser builds the abstract syntax tree, symbol tables are constructed and the program is checked semantically, variables are allocated with a stack layout per procedure, and the code generator emits Eco32-Assembly, which then runs on the accompanying toolchain of assembler, linker and simulator. Verified against a suite of runtime test programs, among them Ackermann, GCD, N-Queens, Game of Life and Sierpinski, plus dedicated syntax-error tests.
