aboutsummaryrefslogtreecommitdiff
path: root/cpu-exec.c
diff options
context:
space:
mode:
authorAndreas Färber <afaerber@suse.de>2013-08-26 05:39:29 +0200
committerAndreas Färber <afaerber@suse.de>2014-03-13 19:20:46 +0100
commitefee734004c42ba185098086e5185d8a85ed02af (patch)
treec833ce3ecabba6aa1595db4e5312ccd023b639b6 /cpu-exec.c
parent99df7dce8ae81e4a42dac98094ccca3a32dcf8f8 (diff)
downloadqemu-arm-efee734004c42ba185098086e5185d8a85ed02af.tar.gz
cpu: Move icount_extra field from CPU_COMMON to CPUState
Reset it. Signed-off-by: Andreas Färber <afaerber@suse.de>
Diffstat (limited to 'cpu-exec.c')
-rw-r--r--cpu-exec.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/cpu-exec.c b/cpu-exec.c
index 6559d5e922..4a03d83cba 100644
--- a/cpu-exec.c
+++ b/cpu-exec.c
@@ -650,15 +650,15 @@ int cpu_exec(CPUArchState *env)
int insns_left;
tb = (TranslationBlock *)(next_tb & ~TB_EXIT_MASK);
insns_left = env->icount_decr.u32;
- if (env->icount_extra && insns_left >= 0) {
+ if (cpu->icount_extra && insns_left >= 0) {
/* Refill decrementer and continue execution. */
- env->icount_extra += insns_left;
- if (env->icount_extra > 0xffff) {
+ cpu->icount_extra += insns_left;
+ if (cpu->icount_extra > 0xffff) {
insns_left = 0xffff;
} else {
- insns_left = env->icount_extra;
+ insns_left = cpu->icount_extra;
}
- env->icount_extra -= insns_left;
+ cpu->icount_extra -= insns_left;
env->icount_decr.u16.low = insns_left;
} else {
if (insns_left > 0) {