summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--tcg/tcg.c1
-rw-r--r--tcg/tcg.h3
2 files changed, 3 insertions, 1 deletions
diff --git a/tcg/tcg.c b/tcg/tcg.c
index 30f3aef..6b27d7b 100644
--- a/tcg/tcg.c
+++ b/tcg/tcg.c
@@ -89,6 +89,7 @@ TCGOpDef tcg_op_defs[] = {
#include "tcg-opc.h"
#undef DEF
};
+const size_t tcg_op_defs_max = ARRAY_SIZE(tcg_op_defs);
static TCGRegSet tcg_target_available_regs[2];
static TCGRegSet tcg_target_call_clobber_regs;
diff --git a/tcg/tcg.h b/tcg/tcg.h
index ca48075..755a8b3 100644
--- a/tcg/tcg.h
+++ b/tcg/tcg.h
@@ -525,7 +525,8 @@ typedef struct TCGOpDef {
} TCGOpDef;
extern TCGOpDef tcg_op_defs[];
-
+extern const size_t tcg_op_defs_max;
+
typedef struct TCGTargetOpDef {
TCGOpcode op;
const char *args_ct_str[TCG_MAX_OP_ARGS];
OpenPOWER on IntegriCloud