[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 07/19] target/ppc: Move REQUIRE_ALTIVEC/VECTOR to translate.c
From: |
Luis Pires |
Subject: |
[PATCH 07/19] target/ppc: Move REQUIRE_ALTIVEC/VECTOR to translate.c |
Date: |
Tue, 24 Aug 2021 11:27:18 -0300 |
From: Bruno Larsen <bruno.larsen@eldorado.org.br>
Move REQUIRE_ALTIVEC to translate.c and rename it to REQUIRE_VECTOR.
Signed-off-by: Bruno Larsen <bruno.larsen@eldorado.org.br>
Signed-off-by: Matheus Ferst <matheus.ferst@eldorado.org.br>
Signed-off-by: Fernando Valle <fernando.valle@eldorado.org.br>
Signed-off-by: Luis Pires <luis.pires@eldorado.org.br>
---
target/ppc/translate.c | 8 ++++++++
target/ppc/translate/vector-impl.c.inc | 10 +---------
2 files changed, 9 insertions(+), 9 deletions(-)
diff --git a/target/ppc/translate.c b/target/ppc/translate.c
index 171b216e17..4749ecdaa9 100644
--- a/target/ppc/translate.c
+++ b/target/ppc/translate.c
@@ -7453,6 +7453,14 @@ static int times_4(DisasContext *ctx, int x)
# define REQUIRE_64BIT(CTX) REQUIRE_INSNS_FLAGS(CTX, 64B)
#endif
+#define REQUIRE_VECTOR(CTX) \
+ do { \
+ if (unlikely(!(CTX)->altivec_enabled)) { \
+ gen_exception((CTX), POWERPC_EXCP_VPU); \
+ return true; \
+ } \
+ } while (0)
+
/*
* Helpers for implementing sets of trans_* functions.
* Defer the implementation of NAME to FUNC, with optional extra arguments.
diff --git a/target/ppc/translate/vector-impl.c.inc
b/target/ppc/translate/vector-impl.c.inc
index 117ce9b137..197e903337 100644
--- a/target/ppc/translate/vector-impl.c.inc
+++ b/target/ppc/translate/vector-impl.c.inc
@@ -17,20 +17,12 @@
* License along with this library; if not, see <http://www.gnu.org/licenses/>.
*/
-#define REQUIRE_ALTIVEC(CTX) \
- do { \
- if (unlikely(!(CTX)->altivec_enabled)) { \
- gen_exception((CTX), POWERPC_EXCP_VPU); \
- return true; \
- } \
- } while (0)
-
static bool trans_VCFUGED(DisasContext *ctx, arg_VX *a)
{
TCGv_i64 tgt, src, mask;
REQUIRE_INSNS_FLAGS2(ctx, ISA310);
- REQUIRE_ALTIVEC(ctx);
+ REQUIRE_VECTOR(ctx);
tgt = tcg_temp_new_i64();
src = tcg_temp_new_i64();
--
2.25.1
- [PATCH 00/19] target/ppc: DFP instructions using decodetree, Luis Pires, 2021/08/24
- [PATCH 01/19] host-utils: Fix overflow detection in divu128(), Luis Pires, 2021/08/24
- [PATCH 02/19] host-utils: move abs64() to host-utils, Luis Pires, 2021/08/24
- [PATCH 03/19] host-utils: move checks out of divu128/divs128, Luis Pires, 2021/08/24
- [PATCH 04/19] host-utils: add 128-bit quotient support to divu128/divs128, Luis Pires, 2021/08/24
- [PATCH 05/19] host-utils: add unit tests for divu128/divs128, Luis Pires, 2021/08/24
- [PATCH 06/19] libdecnumber: introduce decNumberFrom[U]Int128, Luis Pires, 2021/08/24
- [PATCH 07/19] target/ppc: Move REQUIRE_ALTIVEC/VECTOR to translate.c,
Luis Pires <=
- [PATCH 08/19] target/ppc: Introduce REQUIRE_FPU, Luis Pires, 2021/08/24
- [PATCH 09/19] target/ppc: Implement DCFFIXQQ, Luis Pires, 2021/08/24
- [PATCH 10/19] host-utils: Introduce mulu128, Luis Pires, 2021/08/24
- [PATCH 11/19] libdecnumber: Introduce decNumberIntegralToInt128, Luis Pires, 2021/08/24
- [PATCH 12/19] target/ppc: Implement DCTFIXQQ, Luis Pires, 2021/08/24
- [PATCH 13/19] target/ppc: Move dtstdc[q]/dtstdg[q] to decodetree, Luis Pires, 2021/08/24
- [PATCH 14/19] target/ppc: Move d{add, sub, mul, div, iex}[q] to decodetree, Luis Pires, 2021/08/24