minosproject / minos

Flexible Virtualization Solution for Embedded System
http://minosproject.org
GNU General Public License v2.0
246 stars 93 forks source link

correctly emulate the zero register #45

Closed ghost closed 3 years ago

ghost commented 3 years ago

In a general-purpose register field the value 31 represents either the current stack pointer or the zero register, depending on the instruction and the operand position.

Inspired by https://github.com/xen-project/xen/commit/1d8279231ff8781c013dd1b909edda22f7b57720