[disasm] Refactor to make future state tracking easier