All of lore.kernel.org
 help / color / mirror / Atom feed
From: Leon Alrae <leon.alrae@imgtec.com>
To: Aurelien Jarno <aurelien@aurel32.net>
Cc: yongbok.kim@imgtec.com, cristian.cuna@imgtec.com, qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH 13/21] target-mips: add Compact Branches
Date: Tue, 3 Jun 2014 10:29:45 +0100	[thread overview]
Message-ID: <538D9589.1080609@imgtec.com> (raw)
In-Reply-To: <20140602191612.GA4278@ohm.rr44.fr>

On 02/06/14 20:16, Aurelien Jarno wrote:
>> -    case OPC_DADDI:
>> +    case OPC_DADDI: /* OPC_BNVC, OPC_BNEZALC, OPC_BNEC */
>> +        if (ctx->insn_flags & ISA_MIPS32R6) {
>> +            /* OPC_BNVC, OPC_BNEZALC, OPC_BNEC */
>> +            gen_compute_compact_branch(ctx, op, rs, rt, imm << 2);
>> +        } else {
>> +            /* OPC_DADDI */
>> +            check_insn(ctx, ISA_MIPS3);
>> +            check_mips_64(ctx);
>> +            gen_arith_imm(ctx, op, rt, rs, imm);
>> +        }
>> +        break;
>>      case OPC_DADDIU:
>>          check_insn(ctx, ISA_MIPS3);
>>          check_mips_64(ctx);
>>          gen_arith_imm(ctx, op, rt, rs, imm);
>>          break;
>> +#else
>> +    case OPC_BNVC: /* OPC_BNEZALC, OPC_BNEC */
>> +        if (ctx->insn_flags & ISA_MIPS32R6) {
>> +            gen_compute_compact_branch(ctx, op, rs, rt, imm << 2);
>> +        } else {
>> +            MIPS_INVAL("major opcode");
>> +            generate_exception(ctx, EXCP_RI);
>> +        }
>> +        break;
> 
> Why is that introduced only in the MIPS32 case, but not in the MIPS64
> case.
Do you mean BNVC, BNEZALC and BNEC instructions? They are introduced in
MIPS64 as well, you'll find them in OPC_DADDI case. OPC_DADDI was
removed in R6 and its encoding has been reused for those instructions.



There's quite a number of good findings. Thanks for the comments and
suggestions.

Leon

  reply	other threads:[~2014-06-03  9:30 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1401461279-59617-1-git-send-email-leon.alrae@imgtec.com>
     [not found] ` <1401461279-59617-12-git-send-email-leon.alrae@imgtec.com>
     [not found]   ` <20140530224101.GA12523@ohm.rr44.fr>
2014-06-02  8:52     ` [Qemu-devel] [PATCH 11/21] target-mips: Status.UX/SX/KX enable 32-bit address wrapping Leon Alrae
     [not found] ` <1401461279-59617-2-git-send-email-leon.alrae@imgtec.com>
     [not found]   ` <20140530164346.GA2766@ohm.rr44.fr>
2014-06-02  9:49     ` [Qemu-devel] [PATCH 01/21] target-mips: introduce MIPS64R6 ISA and a new generic CPU Leon Alrae
     [not found] ` <1401461279-59617-3-git-send-email-leon.alrae@imgtec.com>
     [not found]   ` <20140530164348.GA4065@ohm.rr44.fr>
2014-06-02 10:03     ` [Qemu-devel] [PATCH 02/21] target-mips: signal RI Exception on instructions removed in R6 Maciej W. Rozycki
     [not found] ` <1401461279-59617-14-git-send-email-leon.alrae@imgtec.com>
2014-06-02 19:16   ` [Qemu-devel] [PATCH 13/21] target-mips: add Compact Branches Aurelien Jarno
2014-06-03  9:29     ` Leon Alrae [this message]
2014-06-03 19:49       ` Aurelien Jarno

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=538D9589.1080609@imgtec.com \
    --to=leon.alrae@imgtec.com \
    --cc=aurelien@aurel32.net \
    --cc=cristian.cuna@imgtec.com \
    --cc=qemu-devel@nongnu.org \
    --cc=yongbok.kim@imgtec.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.