Re: [PATCH] target/riscv: do not call GETPC() in check_ret_from_m_mode()

2025-07-21 Thread Nutty Liu
On 7/14/2025 9:37 PM, Daniel Henrique Barboza wrote: > GETPC() should always be called from the top level helper, e.g. the > first helper that is called by the translation code. We stopped doing > that in commit 3157a553ec, and then we introduced problems when > unwinding the exceptions being throw

Re: [PATCH] target/riscv: do not call GETPC() in check_ret_from_m_mode()

2025-07-14 Thread Philippe Mathieu-Daudé
On 14/7/25 15:37, Daniel Henrique Barboza wrote: GETPC() should always be called from the top level helper, e.g. the first helper that is called by the translation code. We stopped doing that in commit 3157a553ec, and then we introduced problems when unwinding the exceptions being thrown by helpe

Re: [PATCH] target/riscv: do not call GETPC() in check_ret_from_m_mode()

2025-07-14 Thread Richard Henderson
On 7/14/25 07:40, Richard Henderson wrote: On 7/14/25 07:37, Daniel Henrique Barboza wrote: GETPC() should always be called from the top level helper, e.g. the first helper that is called by the translation code. We stopped doing that in commit 3157a553ec, and then we introduced problems when un

[PATCH] target/riscv: do not call GETPC() in check_ret_from_m_mode()

2025-07-14 Thread Daniel Henrique Barboza
GETPC() should always be called from the top level helper, e.g. the first helper that is called by the translation code. We stopped doing that in commit 3157a553ec, and then we introduced problems when unwinding the exceptions being thrown by helper_mret(), as reported by [1]. Call GETPC() at the

Re: [PATCH] target/riscv: do not call GETPC() in check_ret_from_m_mode()

2025-07-14 Thread Richard Henderson
On 7/14/25 07:37, Daniel Henrique Barboza wrote: GETPC() should always be called from the top level helper, e.g. the first helper that is called by the translation code. We stopped doing that in commit 3157a553ec, and then we introduced problems when unwinding the exceptions being thrown by helpe