Skip to content

Commit b30ca37

Browse files
authored
Merge pull request #804 from subspace/update-batch-size
Decrease batch size of writing the commitments
2 parents 49ef16d + f55ed25 commit b30ca37

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

crates/subspace-farmer/src/commitments.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,8 @@ use tracing::trace;
2222
/// Number of pieces to read at once during commitments creation (16MiB)
2323
const PLOT_READ_BATCH_SIZE: u64 = (16 * 1024 * 1024 / PIECE_SIZE) as u64;
2424
const PIECE_OFFSET_SIZE: usize = mem::size_of::<PieceOffset>();
25-
/// Number of commitments to store in memory before writing as a batch to disk (16MiB)
26-
const TAGS_WRITE_BATCH_SIZE: usize = 16 * 1024 * 1024 / (TAG_SIZE + PIECE_OFFSET_SIZE);
25+
/// Number of commitments to store in memory before writing as a batch to disk (4MiB)
26+
const TAGS_WRITE_BATCH_SIZE: usize = 4 * 1024 * 1024 / (TAG_SIZE + PIECE_OFFSET_SIZE);
2727

2828
#[derive(Debug, Error)]
2929
pub enum CommitmentError {

0 commit comments

Comments
 (0)