qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v2 06/15] target/m68k: Fix address argument for EXCP_CHK


From: Laurent Vivier
Subject: Re: [PATCH v2 06/15] target/m68k: Fix address argument for EXCP_CHK
Date: Fri, 3 Dec 2021 15:58:12 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.3.0

Le 03/12/2021 à 15:29, Richard Henderson a écrit :
On 12/3/21 6:27 AM, Laurent Vivier wrote:
Le 02/12/2021 à 21:48, Richard Henderson a écrit :
According to the M68040 Users Manual, section 8.4.3,
Six word stack frame (format 2), CHK, CHK2 (and others)
are supposed to record the next insn in PC and the
address of the trapping instruction in ADDRESS.

Create a raise_exception_format2 function to centralize recording
of the trapping pc in mmu.ar, plus advancing to the next insn.

It's weird to use mmu.ar as the field is used for MMU exceptions.

Should I rename the field to "excp_addr" or something?


No, I'm wondering if we shoud move it or duplicate it. It's not clear. I think we can keep it like this and later do a cleanup.

But I think you should add a comment in CPUM68KState next to ar to point out that it is also used to store address of CHK/CHK2/DIV/TRAP/....

Thanks,
Laurent



reply via email to

[Prev in Thread] Current Thread [Next in Thread]