[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH 07/16] tcg: Add TCG_OPF_NOT_PRESENT if TCG_TARGET_HA
From: |
Richard Henderson |
Subject: |
[Qemu-devel] [PATCH 07/16] tcg: Add TCG_OPF_NOT_PRESENT if TCG_TARGET_HAS_foo is negative |
Date: |
Sat, 18 May 2019 12:01:48 -0700 |
If INDEX_op_foo is always expanded by tcg_expand_vec_op, then
there may be no reasonable set of constraints to return from
tcg_target_op_def for that opcode.
Let TCG_TARGET_HAS_foo be specified as -1 in that case. Thus a
boolean test for TCG_TARGET_HAS_foo is true, but we will not
assert within process_op_defs when no constraints are specified.
Compare this with tcg_can_emit_vec_op, which already uses this
tri-state indication.
Signed-off-by: Richard Henderson <address@hidden>
---
tcg/tcg-opc.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tcg/tcg-opc.h b/tcg/tcg-opc.h
index c7d971fa3d..242d608e6d 100644
--- a/tcg/tcg-opc.h
+++ b/tcg/tcg-opc.h
@@ -35,7 +35,7 @@ DEF(call, 0, 0, 3, TCG_OPF_CALL_CLOBBER | TCG_OPF_NOT_PRESENT)
DEF(br, 0, 0, 1, TCG_OPF_BB_END)
-#define IMPL(X) (__builtin_constant_p(X) && !(X) ? TCG_OPF_NOT_PRESENT : 0)
+#define IMPL(X) (__builtin_constant_p(X) && (X) <= 0 ? TCG_OPF_NOT_PRESENT : 0)
#if TCG_TARGET_REG_BITS == 32
# define IMPL64 TCG_OPF_64BIT | TCG_OPF_NOT_PRESENT
#else
--
2.17.1
- [Qemu-devel] [PATCH 00/16] tcg: misc gvec improvments, Richard Henderson, 2019/05/18
- [Qemu-devel] [PATCH 11/16] tcg/aarch64: Support vector bitwise select value, Richard Henderson, 2019/05/18
- [Qemu-devel] [PATCH 07/16] tcg: Add TCG_OPF_NOT_PRESENT if TCG_TARGET_HAS_foo is negative,
Richard Henderson <=
- [Qemu-devel] [PATCH 16/16] tcg/i386: Use MOVDQA for TCG_TYPE_V128 load/store, Richard Henderson, 2019/05/18
- [Qemu-devel] [PATCH 15/16] tcg/aarch64: Allow immediates for vector ORR and BIC, Richard Henderson, 2019/05/18
- [Qemu-devel] [PATCH 12/16] tcg/aarch64: Split up is_fimm, Richard Henderson, 2019/05/18
- [Qemu-devel] [PATCH 14/16] tcg/aarch64: Build vector immediates with two insns, Richard Henderson, 2019/05/18
- [Qemu-devel] [PATCH 10/16] tcg/i386: Use umin/umax in expanding unsigned compare, Richard Henderson, 2019/05/18
- [Qemu-devel] [PATCH 13/16] tcg/aarch64: Use MVNI in tcg_out_dupi_vec, Richard Henderson, 2019/05/18
- [Qemu-devel] [PATCH 09/16] tcg/i386: Remove expansion for missing minmax, Richard Henderson, 2019/05/18
- [Qemu-devel] [PATCH 05/16] tcg: Introduce do_op3_nofail for vector expansion, Richard Henderson, 2019/05/18
- [Qemu-devel] [PATCH 08/16] tcg/i386: Support vector comparison select value, Richard Henderson, 2019/05/18
- [Qemu-devel] [PATCH 04/16] tcg: Add support for vector compare select, Richard Henderson, 2019/05/18