问题
I want a source code of a simple compiler to optimize by interchanging the code for delayed branches for my assignment.
I read the is there a simple compiler for a small language question and found several good compilers.
But optimization has done for almost all of them and some links are dead. Can someone recommend me a simple compiler for a small language that is not implemented optimization for delayed branches.
回答1:
You might try: cucu: a compiler you can understand
It is a simple C compiler, less than 700 lines of code. I found it well written and easy to follow.
来源:https://stackoverflow.com/questions/15688113/simple-compiler-for-optimization-purposes