[Qemu-devel] [PULL 09/10] Revert "target/aarch64: optimize indirect branches"

Richard Henderson posted 10 patches 8 years, 4 months ago
[Qemu-devel] [PULL 09/10] Revert "target/aarch64: optimize indirect branches"
Posted by Richard Henderson 8 years, 4 months ago
This reverts commit e75449a346bf558296966a44277bfd93412c6da6.

This patch appears to induce lockups, or maybe livelocks, while
booting a Linux kernel.  The assumption is that there is a bug
elsewhere within QEMU, but reverting the patch allows normal work
to continue in the meantime.

Signed-off-by: Richard Henderson <rth@twiddle.net>
---
 target/arm/translate-a64.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/target/arm/translate-a64.c b/target/arm/translate-a64.c
index 860e279..ab61d96 100644
--- a/target/arm/translate-a64.c
+++ b/target/arm/translate-a64.c
@@ -11367,7 +11367,8 @@ void gen_intermediate_code_a64(ARMCPU *cpu, TranslationBlock *tb)
             gen_a64_set_pc_im(dc->pc);
             /* fall through */
         case DISAS_JUMP:
-            tcg_gen_lookup_and_goto_ptr(cpu_pc);
+            /* indicate that the hash table must be used to find the next TB */
+            tcg_gen_exit_tb(0);
             break;
         case DISAS_TB_JUMP:
         case DISAS_EXC:
-- 
2.9.4


Re: [Qemu-devel] [PULL 09/10] Revert "target/aarch64: optimize indirect branches"
Posted by Philippe Mathieu-Daudé 8 years, 4 months ago
Can this pull wait you test last series sent by Alex Bennée with the 
following patch?

I dont have Alpha images to test on.

"tcg-runtime: short-circuit lookup_tb_ptr on IRQs"

On 06/14/2017 02:23 AM, Richard Henderson wrote:
> This reverts commit e75449a346bf558296966a44277bfd93412c6da6.
>
> This patch appears to induce lockups, or maybe livelocks, while
> booting a Linux kernel.  The assumption is that there is a bug
> elsewhere within QEMU, but reverting the patch allows normal work
> to continue in the meantime.
>
> Signed-off-by: Richard Henderson <rth@twiddle.net>
> ---
>  target/arm/translate-a64.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/target/arm/translate-a64.c b/target/arm/translate-a64.c
> index 860e279..ab61d96 100644
> --- a/target/arm/translate-a64.c
> +++ b/target/arm/translate-a64.c
> @@ -11367,7 +11367,8 @@ void gen_intermediate_code_a64(ARMCPU *cpu, TranslationBlock *tb)
>              gen_a64_set_pc_im(dc->pc);
>              /* fall through */
>          case DISAS_JUMP:
> -            tcg_gen_lookup_and_goto_ptr(cpu_pc);
> +            /* indicate that the hash table must be used to find the next TB */
> +            tcg_gen_exit_tb(0);
>              break;
>          case DISAS_TB_JUMP:
>          case DISAS_EXC:
>