[v6,19/50] target/alpha: Avoid translate_init unless tcg_enabled

Message ID 20171016172609.23422-20-richard.henderson@linaro.org
State New
Headers show
Series
  • tcg tb_lock removal
Related show

Commit Message

Richard Henderson Oct. 16, 2017, 5:25 p.m.
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>

---
 target/alpha/cpu.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

-- 
2.13.6

Comments

Emilio G. Cota Oct. 17, 2017, 11:27 p.m. | #1
On Mon, Oct 16, 2017 at 10:25:38 -0700, Richard Henderson wrote:
> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>

> ---

>  target/alpha/cpu.c | 4 +++-

>  1 file changed, 3 insertions(+), 1 deletion(-)

> 

> diff --git a/target/alpha/cpu.c b/target/alpha/cpu.c

> index b8a21f4e01..b52ebd7356 100644

> --- a/target/alpha/cpu.c

> +++ b/target/alpha/cpu.c

> @@ -260,7 +260,9 @@ static void alpha_cpu_initfn(Object *obj)

>      cs->env_ptr = env;

>      tlb_flush(cs);

>  

> -    alpha_translate_init();

> +    if (tcg_enabled()) {

> +        alpha_translate_init();

> +    }


This change is undone/superseded by the next patch (patch 20).

I'd just drop it.

		E.

Patch

diff --git a/target/alpha/cpu.c b/target/alpha/cpu.c
index b8a21f4e01..b52ebd7356 100644
--- a/target/alpha/cpu.c
+++ b/target/alpha/cpu.c
@@ -260,7 +260,9 @@  static void alpha_cpu_initfn(Object *obj)
     cs->env_ptr = env;
     tlb_flush(cs);
 
-    alpha_translate_init();
+    if (tcg_enabled()) {
+        alpha_translate_init();
+    }
 
     env->lock_addr = -1;
 #if defined(CONFIG_USER_ONLY)