Revision ecf51c9a
b/tcg/ppc/tcg-target.c | ||
---|---|---|
628 | 628 |
|
629 | 629 |
static void tcg_out_qemu_ld (TCGContext *s, const TCGArg *args, int opc) |
630 | 630 |
{ |
631 |
int addr_reg, addr_reg2, data_reg, data_reg2, r0, r1, rbase, bswap;
|
|
631 |
int addr_reg, data_reg, data_reg2, r0, r1, rbase, bswap; |
|
632 | 632 |
#ifdef CONFIG_SOFTMMU |
633 |
int mem_index, s_bits, r2; |
|
633 |
int mem_index, s_bits, r2, addr_reg2;
|
|
634 | 634 |
uint8_t *label_ptr; |
635 | 635 |
#endif |
636 | 636 |
|
... | ... | |
741 | 741 |
|
742 | 742 |
static void tcg_out_qemu_st (TCGContext *s, const TCGArg *args, int opc) |
743 | 743 |
{ |
744 |
int addr_reg, addr_reg2, r0, r1, data_reg, data_reg2, bswap, rbase;
|
|
744 |
int addr_reg, r0, r1, data_reg, data_reg2, bswap, rbase; |
|
745 | 745 |
#ifdef CONFIG_SOFTMMU |
746 |
int mem_index, r2; |
|
746 |
int mem_index, r2, addr_reg2;
|
|
747 | 747 |
uint8_t *label_ptr; |
748 | 748 |
#endif |
749 | 749 |
|
... | ... | |
979 | 979 |
} |
980 | 980 |
#endif |
981 | 981 |
|
982 |
#ifdef CONFIG_SOFTMMU |
|
982 | 983 |
static void emit_ldst_trampoline (TCGContext *s, const void *ptr) |
983 | 984 |
{ |
984 | 985 |
tcg_out32 (s, MFSPR | RT (3) | LR); |
... | ... | |
987 | 988 |
tcg_out_mov (s, TCG_TYPE_I32, 3, TCG_AREG0); |
988 | 989 |
tcg_out_b (s, 0, (tcg_target_long) ptr); |
989 | 990 |
} |
991 |
#endif |
|
990 | 992 |
|
991 | 993 |
static void tcg_target_qemu_prologue (TCGContext *s) |
992 | 994 |
{ |
... | ... | |
1049 | 1051 |
tcg_out32 (s, ADDI | RT (1) | RA (1) | frame_size); |
1050 | 1052 |
tcg_out32 (s, BCLR | BO_ALWAYS); |
1051 | 1053 |
|
1054 |
#ifdef CONFIG_SOFTMMU |
|
1052 | 1055 |
for (i = 0; i < 4; ++i) { |
1053 | 1056 |
ld_trampolines[i] = s->code_ptr; |
1054 | 1057 |
emit_ldst_trampoline (s, qemu_ld_helpers[i]); |
... | ... | |
1056 | 1059 |
st_trampolines[i] = s->code_ptr; |
1057 | 1060 |
emit_ldst_trampoline (s, qemu_st_helpers[i]); |
1058 | 1061 |
} |
1062 |
#endif |
|
1059 | 1063 |
} |
1060 | 1064 |
|
1061 | 1065 |
static void tcg_out_ld (TCGContext *s, TCGType type, TCGReg ret, TCGReg arg1, |
Also available in: Unified diff