mirror of
https://github.com/paradigmxyz/reth.git
synced 2026-04-30 03:01:58 -04:00
perf: remove redundant ommers sealing (#2386)
This commit is contained in:
@@ -584,11 +584,7 @@ mod tests {
|
||||
.map(|block| {
|
||||
(
|
||||
block.hash(),
|
||||
BlockBody {
|
||||
transactions: block.body,
|
||||
ommers: block.ommers.into_iter().map(|header| header.unseal()).collect(),
|
||||
withdrawals: None,
|
||||
},
|
||||
BlockBody { transactions: block.body, ommers: block.ommers, withdrawals: None },
|
||||
)
|
||||
})
|
||||
.collect::<HashMap<_, _>>();
|
||||
|
||||
@@ -165,7 +165,7 @@ where
|
||||
let block = SealedBlock {
|
||||
header: next_header,
|
||||
body: next_body.transactions,
|
||||
ommers: next_body.ommers.into_iter().map(|h| h.seal_slow()).collect(),
|
||||
ommers: next_body.ommers,
|
||||
withdrawals: next_body.withdrawals,
|
||||
};
|
||||
|
||||
|
||||
@@ -24,7 +24,7 @@ pub(crate) fn zip_blocks<'a>(
|
||||
BlockResponse::Full(SealedBlock {
|
||||
header: header.clone(),
|
||||
body: body.transactions,
|
||||
ommers: body.ommers.into_iter().map(|o| o.seal_slow()).collect(),
|
||||
ommers: body.ommers,
|
||||
withdrawals: body.withdrawals,
|
||||
})
|
||||
}
|
||||
|
||||
@@ -28,7 +28,7 @@ pub(crate) fn generate_bodies(
|
||||
block.hash(),
|
||||
BlockBody {
|
||||
transactions: block.body,
|
||||
ommers: block.ommers.into_iter().map(|header| header.unseal()).collect(),
|
||||
ommers: block.ommers,
|
||||
withdrawals: block.withdrawals,
|
||||
},
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user