Compiler Refactor

Compiler.cpp and Compiler.h now depends on machine.h and not each
individual machine. This removes machines as dependencies for testing
the compiler. Compiler also got a slight refactor to help localize
common code.