On 07/03/2011 02:42 AM, Blue Swirl wrote:
>  }
> 
> -void QEMU_NORETURN do_unassigned_access(target_phys_addr_t addr, int 
> is_write,
> -                                        int is_exec, int unused, int size)
> +void QEMU_NORETURN cpu_unassigned_access(CPUState *env1,
> +                                         target_phys_addr_t addr, int 
> is_write,
> +                                         int is_exec, int unused, int size)
>  {
> +    CPUState *saved_env;
> +
> +    saved_env = env;
> +    env = env1;
>      env->trap_arg0 = addr;
>      env->trap_arg1 = is_write;
>      dynamic_excp(EXCP_MCHK, 0);
> +    env = saved_env;
>  }

For Alpha and MIPS, these functions always throw an exception exiting
the cpu loop.  There's no point in saving the old value of ENV.

It's Sparc and Microblaze that only sometimes throw the exception.


r~

Reply via email to