aboutsummaryrefslogtreecommitdiff
path: root/target
diff options
context:
space:
mode:
authorRichard Henderson <richard.henderson@linaro.org>2017-10-19 20:27:27 -0700
committerRichard Henderson <richard.henderson@linaro.org>2017-10-24 21:50:15 +0200
commit11f4e8f8bfaa2caaab24bef6bbbb8a0205015119 (patch)
treecaba868b4e1e6ad63f86de37e9ade1754ee3063b /target
parentdc41aa7d34989b552efe712ffe184236216f960b (diff)
tcg: Remove TCGV_EQUAL*
When we used structures for TCGv_*, we needed a macro in order to perform a comparison. Now that we use pointers, this is just clutter. Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org> Reviewed-by: Emilio G. Cota <cota@braap.org> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Diffstat (limited to 'target')
-rw-r--r--target/cris/translate.c6
-rw-r--r--target/i386/translate.c6
-rw-r--r--target/m68k/translate.c2
-rw-r--r--target/ppc/translate.c4
4 files changed, 9 insertions, 9 deletions
diff --git a/target/cris/translate.c b/target/cris/translate.c
index 38a999e6f1..55a9202777 100644
--- a/target/cris/translate.c
+++ b/target/cris/translate.c
@@ -839,7 +839,7 @@ static void cris_alu(DisasContext *dc, int op,
}
tcg_gen_or_tl(d, d, tmp);
}
- if (!TCGV_EQUAL(tmp, d)) {
+ if (tmp != d) {
tcg_temp_free(tmp);
}
}
@@ -1162,7 +1162,7 @@ static inline void t_gen_sext(TCGv d, TCGv s, int size)
tcg_gen_ext8s_i32(d, s);
} else if (size == 2) {
tcg_gen_ext16s_i32(d, s);
- } else if (!TCGV_EQUAL(d, s)) {
+ } else {
tcg_gen_mov_tl(d, s);
}
}
@@ -1173,7 +1173,7 @@ static inline void t_gen_zext(TCGv d, TCGv s, int size)
tcg_gen_ext8u_i32(d, s);
} else if (size == 2) {
tcg_gen_ext16u_i32(d, s);
- } else if (!TCGV_EQUAL(d, s)) {
+ } else {
tcg_gen_mov_tl(d, s);
}
}
diff --git a/target/i386/translate.c b/target/i386/translate.c
index 5f24a2de3c..d6697f721c 100644
--- a/target/i386/translate.c
+++ b/target/i386/translate.c
@@ -742,7 +742,7 @@ static CCPrepare gen_prepare_eflags_c(DisasContext *s, TCGv reg)
size = s->cc_op - CC_OP_SUBB;
t1 = gen_ext_tl(cpu_tmp0, cpu_cc_src, size, false);
/* If no temporary was used, be careful not to alias t1 and t0. */
- t0 = TCGV_EQUAL(t1, cpu_cc_src) ? cpu_tmp0 : reg;
+ t0 = t1 == cpu_cc_src ? cpu_tmp0 : reg;
tcg_gen_mov_tl(t0, cpu_cc_srcT);
gen_extu(size, t0);
goto add_sub;
@@ -951,7 +951,7 @@ static CCPrepare gen_prepare_cc(DisasContext *s, int b, TCGv reg)
break;
case JCC_L:
gen_compute_eflags(s);
- if (TCGV_EQUAL(reg, cpu_cc_src)) {
+ if (reg == cpu_cc_src) {
reg = cpu_tmp0;
}
tcg_gen_shri_tl(reg, cpu_cc_src, 4); /* CC_O -> CC_S */
@@ -962,7 +962,7 @@ static CCPrepare gen_prepare_cc(DisasContext *s, int b, TCGv reg)
default:
case JCC_LE:
gen_compute_eflags(s);
- if (TCGV_EQUAL(reg, cpu_cc_src)) {
+ if (reg == cpu_cc_src) {
reg = cpu_tmp0;
}
tcg_gen_shri_tl(reg, cpu_cc_src, 4); /* CC_O -> CC_S */
diff --git a/target/m68k/translate.c b/target/m68k/translate.c
index d738f32f9c..63b1552669 100644
--- a/target/m68k/translate.c
+++ b/target/m68k/translate.c
@@ -58,7 +58,7 @@ static TCGv_i64 cpu_macc[4];
#define QREG_SP get_areg(s, 7)
static TCGv NULL_QREG;
-#define IS_NULL_QREG(t) (TCGV_EQUAL(t, NULL_QREG))
+#define IS_NULL_QREG(t) (t == NULL_QREG)
/* Used to distinguish stores from bad addressing modes. */
static TCGv store_dummy;
diff --git a/target/ppc/translate.c b/target/ppc/translate.c
index a81ff69d75..616cf8f50e 100644
--- a/target/ppc/translate.c
+++ b/target/ppc/translate.c
@@ -902,7 +902,7 @@ static inline void gen_op_arith_add(DisasContext *ctx, TCGv ret, TCGv arg1,
gen_set_Rc0(ctx, t0);
}
- if (!TCGV_EQUAL(t0, ret)) {
+ if (t0 != ret) {
tcg_gen_mov_tl(ret, t0);
tcg_temp_free(t0);
}
@@ -1438,7 +1438,7 @@ static inline void gen_op_arith_subf(DisasContext *ctx, TCGv ret, TCGv arg1,
gen_set_Rc0(ctx, t0);
}
- if (!TCGV_EQUAL(t0, ret)) {
+ if (t0 != ret) {
tcg_gen_mov_tl(ret, t0);
tcg_temp_free(t0);
}