summaryrefslogtreecommitdiff
path: root/target-sparc
diff options
context:
space:
mode:
authorblueswir1 <blueswir1@c046a42c-6fe2-441c-8c8c-71466251a162>2008-03-11 20:59:02 +0000
committerblueswir1 <blueswir1@c046a42c-6fe2-441c-8c8c-71466251a162>2008-03-11 20:59:02 +0000
commitdb4a4ea4eee11c41aae835012ddd9559a055f4ce (patch)
tree66216be03951667780078c0a9599ac56bf2c7818 /target-sparc
parent902b27d0b8d5bfa840eaf389d7cbcc28b57e3fbe (diff)
downloadqemu-db4a4ea4eee11c41aae835012ddd9559a055f4ce.tar.gz
qemu-db4a4ea4eee11c41aae835012ddd9559a055f4ce.tar.bz2
qemu-db4a4ea4eee11c41aae835012ddd9559a055f4ce.zip
Use a TCG global for regwptr
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4038 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'target-sparc')
-rw-r--r--target-sparc/translate.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/target-sparc/translate.c b/target-sparc/translate.c
index 42ddfc4f27..5d63894aa6 100644
--- a/target-sparc/translate.c
+++ b/target-sparc/translate.c
@@ -221,7 +221,6 @@ static inline void gen_movl_reg_TN(int reg, TCGv tn)
else if (reg < 8)
tcg_gen_ld_tl(tn, cpu_env, offsetof(CPUState, gregs[reg]));
else {
- tcg_gen_ld_ptr(cpu_regwptr, cpu_env, offsetof(CPUState, regwptr)); // XXX
tcg_gen_ld_tl(tn, cpu_regwptr, (reg - 8) * sizeof(target_ulong));
}
}
@@ -250,7 +249,6 @@ static inline void gen_movl_TN_reg(int reg, TCGv tn)
else if (reg < 8)
tcg_gen_st_tl(tn, cpu_env, offsetof(CPUState, gregs[reg]));
else {
- tcg_gen_ld_ptr(cpu_regwptr, cpu_env, offsetof(CPUState, regwptr)); // XXX
tcg_gen_st_tl(tn, cpu_regwptr, (reg - 8) * sizeof(target_ulong));
}
}
@@ -4172,7 +4170,6 @@ static inline int gen_intermediate_code_internal(TranslationBlock * tb,
gen_opc_end = gen_opc_buf + OPC_MAX_SIZE;
cpu_tmp0 = tcg_temp_new(TCG_TYPE_TL);
- cpu_regwptr = tcg_temp_new(TCG_TYPE_PTR); // XXX
do {
if (env->nb_breakpoints > 0) {
@@ -4337,6 +4334,9 @@ CPUSPARCState *cpu_sparc_init(const char *cpu_model)
tcg_set_macro_func(&tcg_ctx, tcg_macro_func);
cpu_env = tcg_global_reg_new(TCG_TYPE_PTR, TCG_AREG0, "env");
+ cpu_regwptr = tcg_global_mem_new(TCG_TYPE_PTR, TCG_AREG0,
+ offsetof(CPUState, regwptr),
+ "regwptr");
//#if TARGET_LONG_BITS > HOST_LONG_BITS
#ifdef TARGET_SPARC64
cpu_T[0] = tcg_global_mem_new(TCG_TYPE_TL,