Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

disable in-packet parallel processing for gossip #4838

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion gossip/src/cluster_info.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2294,7 +2294,7 @@ impl ClusterInfo {
return None;
}
}
protocol.par_verify().then(|| {
protocol.verify().then(|| {
stats.packets_received_verified_count.add_relaxed(1);
(packet.meta().socket_addr(), protocol)
})
Expand Down
7 changes: 3 additions & 4 deletions gossip/src/protocol.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ use {
ping_pong::{self, Pong},
},
bincode::serialize,
rayon::prelude::*,
serde::Serialize,
solana_perf::packet::PACKET_DATA_SIZE,
solana_sanitize::{Sanitize, SanitizeError},
Expand Down Expand Up @@ -92,11 +91,11 @@ impl Protocol {

// Returns true if all signatures verify.
#[must_use]
pub(crate) fn par_verify(&self) -> bool {
pub(crate) fn verify(&self) -> bool {
match self {
Self::PullRequest(_, caller) => caller.verify(),
Self::PullResponse(_, data) => data.par_iter().all(CrdsValue::verify),
Self::PushMessage(_, data) => data.par_iter().all(CrdsValue::verify),
Self::PullResponse(_, data) => data.iter().all(CrdsValue::verify),
Self::PushMessage(_, data) => data.iter().all(CrdsValue::verify),
Self::PruneMessage(_, data) => data.verify(),
Self::PingMessage(ping) => ping.verify(),
Self::PongMessage(pong) => pong.verify(),
Expand Down
Loading