user333: I am learning artificial intelligence and chess programming. I want to analyze the architecture and read the code of existing chess engines. But I am confused between multiple choices. There are several free chess engines available, for example: 

Crafty 
GNU Chess
Stockfish
IPPOLIT
Fruit 2.1
(Add your chess engine here)

I am wondering which chess engine is most efficient in terms of CPU cycles used.
For example, if Crafty achieves 3300 ELO by thinking for 30 seconds on each move, and GNU chess achieves 2500 ELO by thinking 1 second on each move, I would consider GNU Chess to be more efficient.
So which engine is most efficient? What would lead me to choose one over another?

user825: First, the definition in the question doesn't make much sense. @johnwbyrd is correct, the 'most efficient' chess engine chess engine should be the best performing engine at any time control.
In general, the stronger the engine is the more efficient the computing resources are utilised. This is expected because a chess engine is really a fast calculator of chess moves. The more (and accurate) moves it can think, the better it becomes.
A strong chess engine such as Stockfish is a brilliant example of applying computer optimisation. For example, let's take a look at how the hash table is implemented in Stockfish: 
class TranspositionTable

  static const int CacheLineSize = 64;
  static const int ClusterSize = 3;

This definition is telling us the size of a cluster in the hash table should be evenly divided by the size of a cache line. It is a very clever optimization because it ensures no extra CPU cycle would be needed as each data transfer can only be done for each line block.
There're many other optimisation examples, such as lazy evaluation in a loop, making sure the threads have work to do etc etc.
So, you see, a popular engine like Stockfish is highly optimised. The source code has been studied thoughtfully. I have every reason to believe Stockfish is the most optimised and efficient chess engine. 

user5702: For many years, nearly all professional chess programmers have tested code changes by running many blitz games to see whether their changes have improved engine performance.  Here's a paper describing a genetic programming technique across many blitz games.  Stockfish programmers follow this same method in conjunction with Fishtest.
Stockfish programmers typically test proposed changes by running many fast games with tight time controls.  If the proposed changes show a benefit, then the change is submitted for testing at tournament time controls.
Stockfish is not unique in this regard.  Nearly all professional or semi-professional engines were tuned at blitz time controls first, and then at tournament controls.
So, in short, because of the way that most chess engines are tuned, I personally feel your supposition is incorrect -- I feel it is more likely that the "most efficient" chess engine will be the best performing engine at any time control.
tl:dr; use Stockfish
EDIT: Not sure why my answer is getting downvoted here.  As further evidence that what I'm saying is correct, please check out the CCRL 40/4 and the CCRL 40/40 automated ratings lists.  If you compare the two lists you will see that the strongest performers in the 40/40 list are almost exactly the same strongest performers in the 40/4 list.  And there is no engine that has an incredible performance jump at tournament vs. blitz controls -- they all typically remain within about 50 ELO of their blitz ratings at long time controls.  To me, that is clear evidence of a critical connection between blitz engine "efficiency" and tournament engine "efficiency".
If you want a toy engine to hack on, here is my Superpawn engine.

user70: If I were going to do this, I'd choose Stockfish, Fruit 2.1, and Crafty for no reason other than their high quality is proven.  Then I'd compare and contrast the techniques, algorithms, and choices made by each.
These aren't easy programs; it would be a lot of work to gain a true understanding.

user142: This is not a direct answer to your question — but because you're interested in Java, check out this link, which has a UCI compatible engine written in Java. Browsing through the code it looked quite readable. It loses to Crafty and Stockfish regularly, but that is to be expected — they usually looked ~4 ply deeper because of the speed difference.
I think it will suit your needs as a fairly strong engine that runs on Java, if only to review the code.

333: <p>I am learning artificial intelligence and chess programming. I want to analyze the architecture and read the code of existing chess engines. But I am confused between multiple choices. There are several free chess engines available, for example: </p>

<ul>
<li>Crafty </li>
<li>GNU Chess</li>
<li>Stockfish</li>
<li>IPPOLIT</li>
<li>Fruit 2.1</li>
<li>(Add your chess engine here)</li>
</ul>

<p>I am wondering which chess engine is most efficient in terms of CPU cycles used.
For example, if Crafty achieves 3300 ELO by thinking for 30 seconds on each move, and GNU chess achieves 2500 ELO by thinking 1 second on each move, I would consider GNU Chess to be more efficient.</p>

<p>So which engine is most efficient? What would lead me to choose one over another?</p>
 825: <p>First, the definition in the question doesn't make much sense. @johnwbyrd is correct, the 'most efficient' chess engine chess engine should be the best performing engine at any time control.</p>

<p>In general, the stronger the engine is the more efficient the computing resources are utilised. This is expected because a chess engine is really a fast calculator of chess moves. The more (and accurate) moves it can think, the better it becomes.</p>

<p>A strong chess engine such as Stockfish is a brilliant example of applying computer optimisation. For example, let's take a look at how the hash table is implemented in Stockfish: </p>

<pre><code>class TranspositionTable

  static const int CacheLineSize = 64;
  static const int ClusterSize = 3;
</code></pre>

<p>This definition is telling us the size of a cluster in the hash table should be evenly divided by the size of a cache line. It is a very clever optimization because it ensures no extra CPU cycle would be needed as each data transfer can only be done for each line block.</p>

<p>There're many other optimisation examples, such as lazy evaluation in a loop, making sure the threads have work to do etc etc.</p>

<p>So, you see, a popular engine like Stockfish is highly optimised. The source code has been studied thoughtfully. I have every reason to believe Stockfish is the most optimised and efficient chess engine. </p>
 5702: <p>For many years, nearly all professional chess programmers have tested code changes <a href="https://chessprogramming.wikispaces.com/Texel%27s+Tuning+Method" rel="noreferrer">by running many blitz games</a> to see whether their changes have improved engine performance.  <a href="http://www.genetic-programming.org/hc2014/David-Paper.pdf" rel="noreferrer">Here's a paper</a> describing a genetic programming technique across many blitz games.  Stockfish programmers follow this same method in conjunction with <a href="http://tests.stockfishchess.org/tests" rel="noreferrer">Fishtest</a>.</p>

<p>Stockfish programmers typically test proposed changes by running many fast games with tight time controls.  If the proposed changes show a benefit, then the change is submitted for testing at tournament time controls.</p>

<p>Stockfish is not unique in this regard.  Nearly all professional or semi-professional engines were tuned at blitz time controls first, and then at tournament controls.</p>

<p>So, in short, because of the way that most chess engines are tuned, I personally feel your supposition is incorrect -- I feel it is more likely that the "most efficient" chess engine will be the best performing engine at any time control.</p>

<p>tl:dr; <a href="https://stockfishchess.org/" rel="noreferrer">use Stockfish</a></p>

<p>EDIT: Not sure why my answer is getting downvoted here.  As further evidence that what I'm saying is correct, please check out the <a href="http://www.computerchess.org.uk/ccrl/404/" rel="noreferrer">CCRL 40/4</a> and the <a href="http://www.computerchess.org.uk/ccrl/4040/" rel="noreferrer">CCRL 40/40</a> automated ratings lists.  If you compare the two lists you will see that the strongest performers in the 40/40 list are almost exactly the same strongest performers in the 40/4 list.  And there is no engine that has an incredible performance jump at tournament vs. blitz controls -- they all typically remain within about 50 ELO of their blitz ratings at long time controls.  To me, that is clear evidence of a critical connection between blitz engine "efficiency" and tournament engine "efficiency".</p>

<p>If you want a toy engine to hack on, here is my <a href="http://chess.johnbyrd.org" rel="noreferrer">Superpawn</a> engine.</p>
 70: <p>If I were going to do this, I'd choose Stockfish, Fruit 2.1, and Crafty for no reason other than their high quality is proven.  Then I'd compare and contrast the techniques, algorithms, and choices made by each.</p>

<p>These aren't easy programs; it would be a lot of work to gain a true understanding.</p>
 142: <p>This is not a direct answer to your question — but because you're interested in Java, check out <a href="http://code.google.com/p/magnumchess/" rel="nofollow noreferrer">this link</a>, which has a UCI compatible engine written in Java. Browsing through the code it looked quite readable. It loses to Crafty and Stockfish regularly, but that is to be expected — they usually looked ~4 ply deeper because of the speed difference.</p>

<p>I think it will suit your needs as a fairly strong engine that runs on Java, if only to review the code.</p>
