]> git.sesse.net Git - stockfish/commitdiff
Retire RootNode template
authorlucasart <lucas.braesch@gmail.com>
Mon, 18 Jan 2016 22:20:16 +0000 (22:20 +0000)
committerJoona Kiiski <joona@zoox.com>
Mon, 18 Jan 2016 22:21:42 +0000 (22:21 +0000)
There is no reason to compile 3 different copies of search(). PV nodes are on
the cold path, and PvNode is a template parameter, so there is no cost in
computing:

const bool RootNode = PvNode && (ss-1)->ply == 0;

And this simplifies code a tiny bit as well.

Speed impact is negligible on my machine (i7-3770k, linux 4.2, gcc 5.2):

            nps   +/-
test    2378605  3118
master  2383128  2793
diff      -4523  2746

Bench: 7751425

No functional change.

Resolves #568


No differences found