From 30b47998262642be54da5acf03dfca31af4d93f7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alonso=20Gonz=C3=A1lez?= Date: Mon, 15 Jan 2024 15:54:25 +0100 Subject: [PATCH] Fix simulation for jumpdest analysis (#1467) --- evm/src/generation/mod.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/evm/src/generation/mod.rs b/evm/src/generation/mod.rs index e14de9b98a..c8f2dac10d 100644 --- a/evm/src/generation/mod.rs +++ b/evm/src/generation/mod.rs @@ -365,7 +365,9 @@ fn simulate_cpu_between_labels_and_get_user_jumps( loop { // skip jumpdest table validations in simulations - if state.registers.program_counter == KERNEL.global_labels["jumpdest_analysis"] { + if state.registers.is_kernel + && state.registers.program_counter == KERNEL.global_labels["jumpdest_analysis"] + { state.registers.program_counter = KERNEL.global_labels["jumpdest_analysis_end"] } let pc = state.registers.program_counter;