mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-08 10:13:56 -06:00
target/i386: Mark some helpers as noreturn
Any helper that always raises an exception or interrupt, or simply exits to the main loop, can be so marked. Signed-off-by: Richard Henderson <richard.henderson@linaro.org> Reviewed-by: Paolo Bonzini <pbonzini@redhat.com> Message-Id: <20210514151342.384376-35-richard.henderson@linaro.org>
This commit is contained in:
parent
8d6806c7dd
commit
b82055aece
5 changed files with 29 additions and 26 deletions
|
@ -25,12 +25,13 @@
|
|||
#include "exec/helper-proto.h"
|
||||
#include "helper-tcg.h"
|
||||
|
||||
void helper_raise_interrupt(CPUX86State *env, int intno, int next_eip_addend)
|
||||
void QEMU_NORETURN helper_raise_interrupt(CPUX86State *env, int intno,
|
||||
int next_eip_addend)
|
||||
{
|
||||
raise_interrupt(env, intno, 1, 0, next_eip_addend);
|
||||
}
|
||||
|
||||
void helper_raise_exception(CPUX86State *env, int exception_index)
|
||||
void QEMU_NORETURN helper_raise_exception(CPUX86State *env, int exception_index)
|
||||
{
|
||||
raise_exception(env, exception_index);
|
||||
}
|
||||
|
@ -116,24 +117,25 @@ void QEMU_NORETURN raise_interrupt(CPUX86State *env, int intno, int is_int,
|
|||
raise_interrupt2(env, intno, is_int, error_code, next_eip_addend, 0);
|
||||
}
|
||||
|
||||
void raise_exception_err(CPUX86State *env, int exception_index,
|
||||
int error_code)
|
||||
void QEMU_NORETURN raise_exception_err(CPUX86State *env, int exception_index,
|
||||
int error_code)
|
||||
{
|
||||
raise_interrupt2(env, exception_index, 0, error_code, 0, 0);
|
||||
}
|
||||
|
||||
void raise_exception_err_ra(CPUX86State *env, int exception_index,
|
||||
int error_code, uintptr_t retaddr)
|
||||
void QEMU_NORETURN raise_exception_err_ra(CPUX86State *env, int exception_index,
|
||||
int error_code, uintptr_t retaddr)
|
||||
{
|
||||
raise_interrupt2(env, exception_index, 0, error_code, 0, retaddr);
|
||||
}
|
||||
|
||||
void raise_exception(CPUX86State *env, int exception_index)
|
||||
void QEMU_NORETURN raise_exception(CPUX86State *env, int exception_index)
|
||||
{
|
||||
raise_interrupt2(env, exception_index, 0, 0, 0, 0);
|
||||
}
|
||||
|
||||
void raise_exception_ra(CPUX86State *env, int exception_index, uintptr_t retaddr)
|
||||
void QEMU_NORETURN raise_exception_ra(CPUX86State *env, int exception_index,
|
||||
uintptr_t retaddr)
|
||||
{
|
||||
raise_interrupt2(env, exception_index, 0, 0, 0, retaddr);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue