From 4e6ab09f30c4e39b9fbc291dfdfb342830e631f0 Mon Sep 17 00:00:00 2001 From: Wenyong Huang Date: Fri, 8 Jul 2022 19:53:29 +0800 Subject: [PATCH] change the threshold --- core/iwasm/fast-jit/cg/x86-64/jit_codegen_x86_64.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/core/iwasm/fast-jit/cg/x86-64/jit_codegen_x86_64.cpp b/core/iwasm/fast-jit/cg/x86-64/jit_codegen_x86_64.cpp index 7e3f6acbf..c37f89991 100644 --- a/core/iwasm/fast-jit/cg/x86-64/jit_codegen_x86_64.cpp +++ b/core/iwasm/fast-jit/cg/x86-64/jit_codegen_x86_64.cpp @@ -5453,7 +5453,7 @@ lookupswitch_r(JitCompContext *cc, x86::Assembler &a, bh_list *jmp_info_list, int32 label_dst = 0; char *stream; - if (opnd->match_pairs_num < 5) { + if (opnd->match_pairs_num < 10) { /* For small count of branches, it is better to compare the key with branch value and jump one by one */ for (i = 0; i < opnd->match_pairs_num; i++) { @@ -5472,7 +5472,6 @@ lookupswitch_r(JitCompContext *cc, x86::Assembler &a, bh_list *jmp_info_list, imm.setValue(INT32_MAX); a.je(imm); - a.nop(); } if (opnd->default_target) {