On 23/06/2024 20:47, Richard Henderson wrote:

On 6/23/24 04:57, Mark Cave-Ayland wrote:
+G_NORETURN void m68k_cpu_do_unaligned_access(CPUState *cs, vaddr addr,
+                                             MMUAccessType access_type,
+                                             int mmu_idx, uintptr_t retaddr)
+{
+    CPUM68KState *env = cpu_env(cs);
+
+    raise_exception(env, EXCP_ADDRESS);
+}

Surely the address gets stored in the exception frame somewhere?
r~

Well. There is already some logic there for EXCP_ADDRESS in m68k_interrupt_all() so I thought this would just work as-is, but upon closer reading of older CPU datasheets it appears there are at least 2 different stack frame formats for CPUs before the 68040.

It looks like I'll have to do a bit more research before posting a v2.


ATB,

Mark.


Reply via email to