1
0
Fork 0
mirror of https://github.com/sockspls/badfish synced 2025-04-30 00:33:09 +00:00
BadFish/src
Joona Kiiski fefb27bab4 Speed up max_piece_type()
Write code in the way that allows compiler to perform loop unrolling.

My measurement (32 cycles each):

Orig:

Time (Mean: 2466.59375, Trimmed mean: 2464.25, Std: 12.6869487803348)
Nodes (Mean: 4294458, Trimmed mean: 4294458, Std: 0)
Speed (Mean: 1741.09247987678, Trimmed mean: 1742.72879715475, Std: 8.93612608292678)

Time (Mean: 2470.15625, Trimmed mean: 2468.75, Std: 12.7484581610433)
Nodes (Mean: 4294458, Trimmed mean: 4294458, Std: 0)
Speed (Mean: 1738.58176151341, Trimmed mean: 1739.54618465403, Std: 8.95585822316946)

Mod:

Time (Mean: 2449.90625, Trimmed mean: 2445.9375, Std: 12.1000116635508)
Nodes (Mean: 4294458, Trimmed mean: 4294458, Std: 0)
Speed (Mean: 1752.94829372932, Trimmed mean: 1755.75934908231, Std: 8.61478453124504)

Time (Mean: 2442.78125, Trimmed mean: 2441.1875, Std: 8.17839157228837)
Nodes (Mean: 4294458, Trimmed mean: 4294458, Std: 0)
Speed (Mean: 1758.03872783803, Trimmed mean: 1759.16825356261, Std: 5.81131316346191)

No functional change
2014-10-27 20:25:57 +00:00
..
benchmark.cpp Retire notation.h 2014-10-26 19:39:56 +00:00
bitbase.cpp Fix a warning with MSVC in 'analyze' mode 2014-06-14 12:46:58 +02:00
bitboard.cpp Small code style reformatting 2014-07-29 06:52:32 +08:00
bitboard.h Trivial code style fixes 2014-09-30 09:05:20 +02:00
bitcount.h Use compiler intrinsic instead of assembly for popcnt 2014-07-03 18:22:53 +08:00
endgame.cpp Revert back KBPsK to latest Gary's version 2014-05-04 09:34:22 +02:00
endgame.h Simplify pawnless endgame evaluation 2014-01-18 17:22:54 +01:00
evaluate.cpp Speed up max_piece_type() 2014-10-27 20:25:57 +00:00
evaluate.h Small renaming in Tracing 2014-06-09 05:30:18 +09:00
main.cpp Rename ucioption.h to uci.h 2014-10-26 19:39:46 +00:00
Makefile Retire notation.cpp 2014-10-26 19:40:13 +00:00
material.cpp Move game_phase() to Position 2014-06-20 23:44:46 +02:00
material.h Move game_phase() to Position 2014-06-20 23:44:46 +02:00
misc.cpp Retire struct Log 2014-09-16 21:13:50 +01:00
misc.h Retire struct Log 2014-09-16 21:13:50 +01:00
movegen.cpp Minor stuff scattered around 2014-04-28 17:07:43 +02:00
movegen.h Update copyright year 2014-01-02 01:49:18 +01:00
movepick.cpp Fix issues detected by Coverity Scan 2014-04-26 09:33:50 +02:00
movepick.h Sync some common names 2014-04-06 11:26:12 +02:00
pawns.cpp Tune PawnsFileSpan 2014-10-27 11:48:44 +00:00
pawns.h Further streamline connected pawn evaluation 2014-10-12 20:03:49 +01:00
platform.h Update copyright year 2014-01-02 01:49:18 +01:00
position.cpp Final UCI helpers renaming 2014-10-26 19:40:04 +00:00
position.h Reformat and rename hash_after_move() 2014-10-04 10:36:29 +01:00
psqtab.h Remove RookOn7th and merge values into psqt 2014-04-24 08:53:46 +02:00
rkiss.h Move magic random to RKISS 2014-02-12 14:47:36 +01:00
search.cpp Improve compatibility with Shredder Classic GUI 2014-10-27 11:07:35 +00:00
search.h Rework perft implementation 2014-08-09 13:00:59 +08:00
thread.cpp Rename ucioption.h to uci.h 2014-10-26 19:39:46 +00:00
thread.h Retire FakeSplit 2014-07-09 07:19:06 +08:00
timeman.cpp Rename ucioption.h to uci.h 2014-10-26 19:39:46 +00:00
timeman.h Fix Intel compiler warnings 2014-04-27 12:02:36 +02:00
tt.cpp Fix some warnings with Intel C++ compiler 2014-10-12 20:34:54 +01:00
tt.h Convert TT depth to int8_t 2014-10-01 20:51:32 +01:00
types.h Move ONE_PLY to be 1 instead of 2: search() 2014-09-29 15:17:12 +02:00
uci.cpp Fix an obscure gcc warning 2014-10-26 19:40:20 +00:00
uci.h Retire notation.cpp 2014-10-26 19:40:13 +00:00
ucioption.cpp Rename ucioption.h to uci.h 2014-10-26 19:39:46 +00:00