+ // Step 5. Evaluate the position statically
+ // At root we do this only to get reference value for child nodes
+ if (!isCheck)
+ ss[0].eval = evaluate(pos, ei, 0);
+ else
+ ss[0].eval = VALUE_NONE; // HACK because we do not initialize root node
+
+ // Step 6. Razoring (omitted at root)
+ // Step 7. Static null move pruning (omitted at root)
+ // Step 8. Null move search with verification search (omitted at root)
+ // Step 9. Internal iterative deepening (omitted at root)
+
+ // Step extra. Fail low loop
+ // We start with small aspiration window and in case of fail low, we research
+ // with bigger window until we are not failing low anymore.
+ while (1)