1. A method for representing a design for a processor, for enabling technology retargeting and optimization, the method comprising: generating a processor specification that specifies the design for the processor, wherein the processor specification is comprised of a plurality of states and a plurality of operators causing state transformations; translating the processor specification into a compiler module of a compiler, wherein the translation transforms a target-independent code generator into a target-dependent program implementation; and transforming the processor specification into an executable simulation of the processor, wherein the simulation predicts a result of executing the compiled programs on a physical embodiment of the processor.