use BlockGasLimit instead of residual for partitioning
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
This commit is contained in:
parent
28fe602a9b
commit
8eff3a25f9
@ -104,13 +104,12 @@ func (mp *MessagePool) selectMessagesOptimal(curTs, ts *types.TipSet, tq float64
|
||||
}
|
||||
|
||||
// 3. Parition chains into blocks (without trimming)
|
||||
// we use the residual gas limit from the priority message selection as those message
|
||||
// will be unconditionally included
|
||||
residualGasLimit := gasLimit
|
||||
// we use the full blockGasLimit (as opposed to the residual gas limit from the
|
||||
// priority message selection) as we have to account for what other miners are doing
|
||||
nextChain := 0
|
||||
partitions := make([][]*msgChain, MaxBlocks)
|
||||
for i := 0; i < MaxBlocks && nextChain < len(chains); i++ {
|
||||
gasLimit := residualGasLimit
|
||||
gasLimit := int64(build.BlockGasLimit)
|
||||
for nextChain < len(chains) {
|
||||
chain := chains[nextChain]
|
||||
partitions[i] = append(partitions[i], chain)
|
||||
|
Loading…
Reference in New Issue
Block a user