|
From: | Richard Henderson |
Subject: | Re: [PATCH 2/3] target/m68k: Implement TRAPcc |
Date: | Tue, 30 Nov 2021 13:34:05 +0100 |
User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.14.0 |
On 11/30/21 12:57 PM, Laurent Vivier wrote:
+DISAS_INSN(trapcc) +{ + /* Consume and discard the immediate operand. */ + switch (extract32(insn, 0, 3)) { + case 2: /* trapcc.w */ + (void)read_im16(env, s); + break; + case 3: /* trapcc.l */ + (void)read_im32(env, s); + break;Do we need to actually read the memory to trigger a fault if needed or can we only increase the PC?
Yes, and to pass the entire instruction to plugins.
+ case 4: /* trapcc (no operand) */ + break; + default: + /* Illegal insn */ + disas_undef(env, s, insn); + return; + } + do_trapcc(s, extract32(insn, 8, 4)); +}Do we need to change something in m68k_interrupt_all()?
Yes, and cpu_loop. Thanks, r~
[Prev in Thread] | Current Thread | [Next in Thread] |