cpu.c (19da5d125842e56f115873a4af06d59559db9bb6) | cpu.c (3c13b0ffe76057e93e007bedbad3cc556146e3ed) |
---|---|
1/* 2 * QEMU HPPA CPU 3 * 4 * Copyright (c) 2016 Richard Henderson <rth@twiddle.net> 5 * 6 * This library is free software; you can redistribute it and/or 7 * modify it under the terms of the GNU Lesser General Public 8 * License as published by the Free Software Foundation; either --- 18 unchanged lines hidden (view full) --- 27#include "exec/exec-all.h" 28#include "fpu/softfloat.h" 29#include "tcg/tcg.h" 30 31static void hppa_cpu_set_pc(CPUState *cs, vaddr value) 32{ 33 HPPACPU *cpu = HPPA_CPU(cs); 34 | 1/* 2 * QEMU HPPA CPU 3 * 4 * Copyright (c) 2016 Richard Henderson <rth@twiddle.net> 5 * 6 * This library is free software; you can redistribute it and/or 7 * modify it under the terms of the GNU Lesser General Public 8 * License as published by the Free Software Foundation; either --- 18 unchanged lines hidden (view full) --- 27#include "exec/exec-all.h" 28#include "fpu/softfloat.h" 29#include "tcg/tcg.h" 30 31static void hppa_cpu_set_pc(CPUState *cs, vaddr value) 32{ 33 HPPACPU *cpu = HPPA_CPU(cs); 34 |
35#ifdef CONFIG_USER_ONLY 36 value |= PRIV_USER; 37#endif |
|
35 cpu->env.iaoq_f = value; 36 cpu->env.iaoq_b = value + 4; 37} 38 39static vaddr hppa_cpu_get_pc(CPUState *cs) 40{ 41 CPUHPPAState *env = cpu_env(cs); 42 --- 45 unchanged lines hidden (view full) --- 88static void hppa_cpu_synchronize_from_tb(CPUState *cs, 89 const TranslationBlock *tb) 90{ 91 HPPACPU *cpu = HPPA_CPU(cs); 92 93 tcg_debug_assert(!tcg_cflags_has(cs, CF_PCREL)); 94 95#ifdef CONFIG_USER_ONLY | 38 cpu->env.iaoq_f = value; 39 cpu->env.iaoq_b = value + 4; 40} 41 42static vaddr hppa_cpu_get_pc(CPUState *cs) 43{ 44 CPUHPPAState *env = cpu_env(cs); 45 --- 45 unchanged lines hidden (view full) --- 91static void hppa_cpu_synchronize_from_tb(CPUState *cs, 92 const TranslationBlock *tb) 93{ 94 HPPACPU *cpu = HPPA_CPU(cs); 95 96 tcg_debug_assert(!tcg_cflags_has(cs, CF_PCREL)); 97 98#ifdef CONFIG_USER_ONLY |
96 cpu->env.iaoq_f = tb->pc; 97 cpu->env.iaoq_b = tb->cs_base; | 99 cpu->env.iaoq_f = tb->pc | PRIV_USER; 100 cpu->env.iaoq_b = tb->cs_base | PRIV_USER; |
98#else 99 /* Recover the IAOQ values from the GVA + PRIV. */ 100 uint32_t priv = (tb->flags >> TB_FLAG_PRIV_SHIFT) & 3; 101 target_ulong cs_base = tb->cs_base; 102 target_ulong iasq_f = cs_base & ~0xffffffffull; 103 int32_t diff = cs_base; 104 105 cpu->env.iasq_f = iasq_f; --- 179 unchanged lines hidden --- | 101#else 102 /* Recover the IAOQ values from the GVA + PRIV. */ 103 uint32_t priv = (tb->flags >> TB_FLAG_PRIV_SHIFT) & 3; 104 target_ulong cs_base = tb->cs_base; 105 target_ulong iasq_f = cs_base & ~0xffffffffull; 106 int32_t diff = cs_base; 107 108 cpu->env.iasq_f = iasq_f; --- 179 unchanged lines hidden --- |