diff --git a/.github/workflows/pr_perf_blocks_exec.yaml b/.github/workflows/pr_perf_blocks_exec.yaml index 869ae7370a5..57ca4011740 100644 --- a/.github/workflows/pr_perf_blocks_exec.yaml +++ b/.github/workflows/pr_perf_blocks_exec.yaml @@ -66,7 +66,7 @@ jobs: - name: Install Hyperfine uses: taiki-e/install-action@v2 with: - tool: hyperfine@1.16 + tool: hyperfine@1.20 - name: Fetch base binary uses: actions/cache/restore@v3 diff --git a/crates/storage/store.rs b/crates/storage/store.rs index 1b2263fb6e9..70e67df3349 100644 --- a/crates/storage/store.rs +++ b/crates/storage/store.rs @@ -2382,6 +2382,15 @@ fn apply_trie_updates( storage_updates, } = trie_update; + if parent_state_root == child_state_root { + // if roots match it means the block doesn't change the state, thus we + // avoid emitting a diff layer + result_sender + .send(Ok(())) + .map_err(|_| StoreError::LockError)?; + return Ok(()); + } + // Phase 1: update the in-memory diff-layers only, then notify block production. let new_layer = storage_updates .into_iter()