[flow] more work on IR

- adds instruction cloning
- adds IR for NOP VM-instruction
- fixes bug in optimization
flow: code cleanup