From 5d04f23bdf3f99c3c4c731e1897a760f067a34e0 Mon Sep 17 00:00:00 2001 From: aurel32 Date: Sat, 3 Jan 2009 12:36:05 +0000 Subject: [PATCH] tcg: remove tcg_global_reg2_new_hack() This patch removes the unused tcg_global_reg2_new_hack() function, which was added in r4438 to work around a register shortage problem regarding dyngen. The only ever user of this function was removed in r4577. Signed-off-by: Stuart Brady Signed-off-by: Aurelien Jarno git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6150 c046a42c-6fe2-441c-8c8c-71466251a162 --- tcg/tcg.c | 37 ------------------------------------- tcg/tcg.h | 2 -- 2 files changed, 39 deletions(-) diff --git a/tcg/tcg.c b/tcg/tcg.c index 35ca05a..21b69fe 100644 --- a/tcg/tcg.c +++ b/tcg/tcg.c @@ -313,43 +313,6 @@ TCGv_i64 tcg_global_reg_new_i64(int reg, const char *name) return MAKE_TCGV_I64(idx); } -#if TCG_TARGET_REG_BITS == 32 -/* temporary hack to avoid register shortage for tcg_qemu_st64() */ -TCGv_i64 tcg_global_reg2_new_hack(TCGType type, int reg1, int reg2, - const char *name) -{ - TCGContext *s = &tcg_ctx; - TCGTemp *ts; - int idx; - char buf[64]; - - if (type != TCG_TYPE_I64) - tcg_abort(); - idx = s->nb_globals; - tcg_temp_alloc(s, s->nb_globals + 2); - ts = &s->temps[s->nb_globals]; - ts->base_type = type; - ts->type = TCG_TYPE_I32; - ts->fixed_reg = 1; - ts->reg = reg1; - pstrcpy(buf, sizeof(buf), name); - pstrcat(buf, sizeof(buf), "_0"); - ts->name = strdup(buf); - - ts++; - ts->base_type = type; - ts->type = TCG_TYPE_I32; - ts->fixed_reg = 1; - ts->reg = reg2; - pstrcpy(buf, sizeof(buf), name); - pstrcat(buf, sizeof(buf), "_1"); - ts->name = strdup(buf); - - s->nb_globals += 2; - return MAKE_TCGV_I64(idx); -} -#endif - static inline int tcg_global_mem_new_internal(TCGType type, int reg, tcg_target_long offset, const char *name) diff --git a/tcg/tcg.h b/tcg/tcg.h index 08c7bcc..e83073b 100644 --- a/tcg/tcg.h +++ b/tcg/tcg.h @@ -319,8 +319,6 @@ int tcg_gen_code_search_pc(TCGContext *s, uint8_t *gen_code_buf, long offset); void tcg_set_frame(TCGContext *s, int reg, tcg_target_long start, tcg_target_long size); -TCGv_i64 tcg_global_reg2_new_hack(TCGType type, int reg1, int reg2, - const char *name); TCGv_i32 tcg_global_reg_new_i32(int reg, const char *name); TCGv_i32 tcg_global_mem_new_i32(int reg, tcg_target_long offset, -- 2.7.4