Chess Optimizations

后端 未结 12 745
伪装坚强ぢ
伪装坚强ぢ 2021-01-30 15:03

ok, so i have been working on my chess program for a while and i am beginning to hit a wall. i have done all of the standard optimizations (negascout, iterative deepening, kille

12条回答
  •  暖寄归人
    2021-01-30 15:15

    Profile and benchmark. Theoretical optimizations are great, but unless you are measuring the performance impact of every change you make, you won't know whether your work is improving or worsening the speed of the final code.

    Try to limit the penalty to yourself for trying different algorithms. Make it easy to test various implementations of algorithms against one another. i.e. Make it easy to build a PVS version of your code as well as a NegaScout version.

    Find the hot spots. Refactor. Rewrite in assembly if necessary. Repeat.

提交回复
热议问题