[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v2 10/15] target-tricore: Add instructions of SB
From: |
Richard Henderson |
Subject: |
Re: [Qemu-devel] [PATCH v2 10/15] target-tricore: Add instructions of SB opcode format |
Date: |
Tue, 15 Jul 2014 08:31:50 -0700 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.6.0 |
On 07/14/2014 10:41 AM, Bastian Koppelmann wrote:
> +static void gen_compute_branch(DisasContext *ctx, uint32_t opc,
> + int r1, int r2 , int32_t constant , int32_t offset)
> +{
> +
> + switch (opc) {
Watch whitespace, both vertical and horizontal here.
> +/* SB-format jumps */
> + case OPC1_16_SB_J:
> + case OPC1_32_B_J:
> + gen_goto_tb(ctx, 0, ctx->pc + offset * 2);
> + break;
> + case OPC1_16_SB_CALL:
> + gen_helper_1arg(call, ctx->next_pc);
> + gen_goto_tb(ctx, 0, ctx->pc + sextract32(offset, 0, 8) * 2);
Drop the sextract, since we've already done that...
> +/* SB-format */
> + case OPC1_16_SB_CALL:
> + case OPC1_16_SB_J:
> + case OPC1_16_SB_JNZ:
> + case OPC1_16_SB_JZ:
> + address = MASK_OP_SB_DISP8_SEXT(ctx->opcode);
> + gen_compute_branch(ctx, op1, 0, 0, 0, address);
... here.
r~
- [Qemu-devel] [PATCH v2 05/15] target-tricore: Add masks and opcodes for decoding, (continued)
- [Qemu-devel] [PATCH v2 05/15] target-tricore: Add masks and opcodes for decoding, Bastian Koppelmann, 2014/07/14
- [Qemu-devel] [PATCH v2 13/15] target-tricore: Add instructions of SC opcode format, Bastian Koppelmann, 2014/07/14
- [Qemu-devel] [PATCH v2 07/15] target-tricore: Add instructions of SRR opcode format, Bastian Koppelmann, 2014/07/14
- [Qemu-devel] [PATCH v2 09/15] target-tricore: Add instructions of SRRS and SLRO opcode format, Bastian Koppelmann, 2014/07/14
- [Qemu-devel] [PATCH v2 11/15] target-tricore: Add instructions of SBC and SBRN opcode format, Bastian Koppelmann, 2014/07/14
- [Qemu-devel] [PATCH v2 10/15] target-tricore: Add instructions of SB opcode format, Bastian Koppelmann, 2014/07/14
- Re: [Qemu-devel] [PATCH v2 10/15] target-tricore: Add instructions of SB opcode format,
Richard Henderson <=
- [Qemu-devel] [PATCH v2 14/15] target-tricore: Add instructions of SLR, SSRO and SRO opcode format, Bastian Koppelmann, 2014/07/14
- [Qemu-devel] [PATCH v2 08/15] target-tricore: Add instructions of SSR opcode format, Bastian Koppelmann, 2014/07/14
- [Qemu-devel] [PATCH v2 12/15] target-tricore: Add instructions of SBR opcode format, Bastian Koppelmann, 2014/07/14
- [Qemu-devel] [PATCH v2 15/15] target-tricore: Add instructions of SR opcode format, Bastian Koppelmann, 2014/07/14
- [Qemu-devel] [PATCH v2 03/15] target-tricore: Add softmmu support, Bastian Koppelmann, 2014/07/14