From dfeb02b451799095b8805cdcb7e46bad68fb46b8 Mon Sep 17 00:00:00 2001 From: nisdas Date: Fri, 17 Mar 2023 16:37:26 +0800 Subject: [PATCH 1/3] fix evaluator --- beacon-chain/sync/batch_verifier.go | 5 +---- config/features/config.go | 6 ------ config/features/deprecated_flags.go | 5 +++++ config/features/flags.go | 5 ----- 4 files changed, 6 insertions(+), 15 deletions(-) diff --git a/beacon-chain/sync/batch_verifier.go b/beacon-chain/sync/batch_verifier.go index b9bf013a9db5..412152e66285 100644 --- a/beacon-chain/sync/batch_verifier.go +++ b/beacon-chain/sync/batch_verifier.go @@ -6,7 +6,6 @@ import ( pubsub "github.com/libp2p/go-libp2p-pubsub" "github.com/pkg/errors" - "github.com/prysmaticlabs/prysm/v3/config/features" "github.com/prysmaticlabs/prysm/v3/crypto/bls" "github.com/prysmaticlabs/prysm/v3/monitoring/tracing" "go.opencensus.io/trace" @@ -90,9 +89,7 @@ func verifyBatch(verifierBatch []*signatureVerifier) { } var verificationErr error - if features.Get().EnableBatchGossipAggregation { - aggSet, verificationErr = performBatchAggregation(aggSet) - } + aggSet, verificationErr = performBatchAggregation(aggSet) if verificationErr == nil { verified, err := aggSet.Verify() switch { diff --git a/config/features/config.go b/config/features/config.go index 975bbcd661f7..ac3a8c2130dd 100644 --- a/config/features/config.go +++ b/config/features/config.go @@ -64,7 +64,6 @@ type Flags struct { EnableVectorizedHTR bool // EnableVectorizedHTR specifies whether the beacon state will use the optimized sha256 routines. DisableForkchoiceDoublyLinkedTree bool // DisableForkChoiceDoublyLinkedTree specifies whether fork choice store will use a doubly linked tree. - EnableBatchGossipAggregation bool // EnableBatchGossipAggregation specifies whether to further aggregate our gossip batches before verifying them. SaveFullExecutionPayloads bool // Save full beacon blocks with execution payloads in the database. EnableStartOptimistic bool // EnableStartOptimistic treats every block as optimistic at startup. @@ -218,11 +217,6 @@ func ConfigureBeaconChain(ctx *cli.Context) error { logEnabled(disableForkChoiceDoublyLinkedTree) cfg.DisableForkchoiceDoublyLinkedTree = true } - cfg.EnableBatchGossipAggregation = true - if ctx.Bool(disableGossipBatchAggregation.Name) { - logDisabled(disableGossipBatchAggregation) - cfg.EnableBatchGossipAggregation = false - } if ctx.Bool(SaveFullExecutionPayloads.Name) { logEnabled(SaveFullExecutionPayloads) cfg.SaveFullExecutionPayloads = true diff --git a/config/features/deprecated_flags.go b/config/features/deprecated_flags.go index 251eb17318c0..d7e0ff5bdbbe 100644 --- a/config/features/deprecated_flags.go +++ b/config/features/deprecated_flags.go @@ -17,12 +17,17 @@ var ( Usage: deprecatedUsage, Hidden: true, } + deprecatedDisableGossipBatchAggregation = &cli.BoolFlag{ + Name: "disable-gossip-batch-aggregation", + Usage: deprecatedUsage, + Hidden: true} ) // Deprecated flags for both the beacon node and validator client. var deprecatedFlags = []cli.Flag{ exampleDeprecatedFeatureFlag, deprecatedDisablePeerScorer, + deprecatedDisableGossipBatchAggregation, } // deprecatedBeaconFlags contains flags that are still used by other components diff --git a/config/features/flags.go b/config/features/flags.go index 02785c35d05a..73614a9fa0ef 100644 --- a/config/features/flags.go +++ b/config/features/flags.go @@ -96,10 +96,6 @@ var ( Name: "disable-forkchoice-doubly-linked-tree", Usage: "Disables the new forkchoice store structure that uses doubly linked trees", } - disableGossipBatchAggregation = &cli.BoolFlag{ - Name: "disable-gossip-batch-aggregation", - Usage: "Disables new methods to further aggregate our gossip batches before verifying them.", - } enableStartupOptimistic = &cli.BoolFlag{ Name: "startup-optimistic", Usage: "Treats every block as optimistically synced at launch. Use with caution", @@ -165,7 +161,6 @@ var BeaconChainFlags = append(deprecatedBeaconFlags, append(deprecatedFlags, []c disableVecHTR, disableReorgLateBlocks, disableForkChoiceDoublyLinkedTree, - disableGossipBatchAggregation, SaveFullExecutionPayloads, enableStartupOptimistic, enableFullSSZDataLogging, From 5cbf7510f95b51db4e02832eab361ebe1f037596 Mon Sep 17 00:00:00 2001 From: nisdas Date: Fri, 17 Mar 2023 16:38:37 +0800 Subject: [PATCH 2/3] fmt --- config/features/deprecated_flags.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/config/features/deprecated_flags.go b/config/features/deprecated_flags.go index d7e0ff5bdbbe..76581ea316d3 100644 --- a/config/features/deprecated_flags.go +++ b/config/features/deprecated_flags.go @@ -20,7 +20,8 @@ var ( deprecatedDisableGossipBatchAggregation = &cli.BoolFlag{ Name: "disable-gossip-batch-aggregation", Usage: deprecatedUsage, - Hidden: true} + Hidden: true, + } ) // Deprecated flags for both the beacon node and validator client. From 1280051138eee2b5122e6fa9a92be0d4f788f9cc Mon Sep 17 00:00:00 2001 From: nisdas Date: Fri, 17 Mar 2023 19:48:39 +0800 Subject: [PATCH 3/3] config --- config/features/config.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/config/features/config.go b/config/features/config.go index dc03fc406052..6a07f4f6ad78 100644 --- a/config/features/config.go +++ b/config/features/config.go @@ -57,8 +57,8 @@ type Flags struct { EnableSlasher bool // Enable slasher in the beacon node runtime. EnableSlashingProtectionPruning bool // EnableSlashingProtectionPruning for the validator client. - SaveFullExecutionPayloads bool // Save full beacon blocks with execution payloads in the database. - EnableStartOptimistic bool // EnableStartOptimistic treats every block as optimistic at startup. + SaveFullExecutionPayloads bool // Save full beacon blocks with execution payloads in the database. + EnableStartOptimistic bool // EnableStartOptimistic treats every block as optimistic at startup. DisableStakinContractCheck bool // Disables check for deposit contract when proposing blocks