Hi,

Am 2013-09-04 11:04, schrieb Andreas Färber:
On part 11, rth said for alpha that using CPUAlphaState in
DisasContext was bad
and that the relevant fields should be copied into DisasContext
instead; a few
targets still have an env field though and use it for register access and
cpu_abort(), so I have just changed the type for now and call upon
maintainers
to review whether they want to do different changes.

Is there a preferred way to abort translation, if for example, the translator finds an unknown opcode? I guess there should be some kind of exception. But speaking of lm32, the real CPU, does not handle such a situation, instead the behavior is just undefined. Also, the emulation is mainly used for developing, not for hosting applications with security in mind.

For the lm32 target, i would copy the required fields (only information about the chosen cpu model) into the DisasContext as suggested. But then i will still need the CPUState for the cpu_abort() call.

--
michael

Reply via email to