mcts: size the arenas for 12 edges per node (was 8)
In the graph almost every node gets expanded, so it holds about 20 edges per node in middlegames, and with 8 the edge arena filled first (hashfull 965 at 5 s from startpos against 661 for main). Collections over the 16 bench positions at 5 s, Hash 64 (local, one noisy run): 8 edges per node gave 67, 12 gave 53, 16 gave 51 and 20 gave 57; 16 already moves collections into the endgames, which fill the node arena first. The bench is unchanged: it never fills the arenas. Checked: zero warnings; VERIFY build: `verify` (a)-(d), the VERIFY searches of plan section 6 with forced GC at Hash 1 and 2, the reuse sequence at Hash 64, Hash 1 and from the 960 start, and the go nodes 1/2, go depth 1 smoke positions. Bench: 764208 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
95e49098ec
commit
0a9bb4072c
1 file changed
+9
-9
+9
-9
@@ -71,15 +71,15 @@ u16 position_check(const Position& pos);
|
|||||||
// check, about 80 bits.
|
// check, about 80 bits.
|
||||||
class Tree {
|
class Tree {
|
||||||
public:
|
public:
|
||||||
// Edges per node the arenas are sized for: the edge arena gets 128 of
|
// Edges per node the arenas are sized for: the edge arena gets 192 of
|
||||||
// every 160 bytes, the node arena 32. Measured in step 1 of the MCGS plan
|
// every 224 bytes, the node arena 32 (plus the table). In the graph
|
||||||
// (docs/mcgs-log.md, edges per visited node): 13 on average in 5 s
|
// almost every node gets expanded, so it holds about 20 edges per node
|
||||||
// searches without collections, 19-21 in middlegames, 3.6-5.5 in simple
|
// in middlegames (step 1: 18 per distinct position without collections),
|
||||||
// endgames, and 3-9 right after collections (pruned nodes keep their node
|
// and with 8 the edge arena filled first. Collections over the 16 bench
|
||||||
// but lose their edges). Over the 16 bench positions at 5 s and Hash 64,
|
// positions at 5 s and Hash 64 (local, one noisy run): 8 edges gave 67,
|
||||||
// 8 gave 184 collections (main: 200), as few as 13 did, without 13's
|
// 12 gave 53, 16 gave 51 and 20 gave 57; 16 already moves collections into
|
||||||
// 2-3x more collections in the endgames (which fill the node arena first).
|
// the endgames, which fill the node arena first.
|
||||||
static constexpr size_t EDGES_PER_NODE = 8;
|
static constexpr size_t EDGES_PER_NODE = 12;
|
||||||
|
|
||||||
// Splits `bytes` between the node arena, the edge arena and the table.
|
// Splits `bytes` between the node arena, the edge arena and the table.
|
||||||
void resize_bytes(size_t bytes);
|
void resize_bytes(size_t bytes);
|
||||||
|
|||||||
Reference in new issue
Block a user