On Wed, May 4, 2011 at 3:59 AM, Max Filippov <jcmvb...@gmail.com> wrote:
> Signed-off-by: Max Filippov <jcmvb...@gmail.com>
> ---
>  target-xtensa/translate.c |   60 
> ++++++++++++++++++++++++++++++++++++++++++++-
>  1 files changed, 59 insertions(+), 1 deletions(-)
>
> diff --git a/target-xtensa/translate.c b/target-xtensa/translate.c
> index faf1adc..d635229 100644
> --- a/target-xtensa/translate.c
> +++ b/target-xtensa/translate.c
> @@ -793,7 +793,65 @@ static void disas_xtensa_insn(DisasContext *dc)
>             break;
>
>         case 2: /*RST2*/
> -            TBD();
> +            if (_OP2 >= 12) {
> +                HAS_OPTION(XTENSA_OPTION_32_BIT_IDIV);
> +                int label = gen_new_label();
> +                tcg_gen_brcondi_i32(TCG_COND_NE, cpu_R[RRR_T], 0, label);
> +                gen_exception_cause(dc, INTEGER_DIVIE_BY_ZERO_CAUSE);

DIVIE?

Reply via email to