MikeB wrote:petero2 wrote:MikeB wrote:Found a bug introduced in Hawkeye 1.02. Not sure how it much hurt , but a bug is a bug.
It may be complier compiler related, not too much difference with icc, more of difference with gcc - related to missing brackets.
Can you explain what this bug fix is supposed to do? According to the git repository the bug fix looks like this:
Code: Select all
if (DTZ_table[0].key1 != key && DTZ_table[0].key2 != key)
{
for (i = 1; i < DTZ_ENTRIES; i++)
- ///mfb
+ ///mfb fix
+ {
if (DTZ_table[i].key1 == key || DTZ_table[i].key2 == key) break;
- ///mfb
+ }
if (i < DTZ_ENTRIES)
{
struct DTZTableEntry table_entry = DTZ_table[i];
As far as I can tell these added brackets will make no difference at all unless the C compiler is buggy.
That might be true but i suggest compile with very aggressive options
I did but as expected there is no difference in the generated executable code:
Code: Select all
git checkout 365521be37063e4233a3a45ae833a6f4e91d49bd
g++ -DNDEBUG -Os -msse4.2 -mpopcnt -fno-exceptions -fno-rtti -Wno-parentheses -O3 -S tbprobe.cpp
mv tbprobe.s tbprobe.s_old
git checkout 7fb5383d57e63b19bf5c22dc67848fc75778c74c
g++ -DNDEBUG -Os -msse4.2 -mpopcnt -fno-exceptions -fno-rtti -Wno-parentheses -O3 -S tbprobe.cpp
mv tbprobe.s tbprobe.s_new
diff tbprobe.s_{old,new}
The diff command produces no output since the two compiled versions are identical.
MikeB wrote:and then have the engines play each other and let us know what you get.
No need for that since the executables are identical.
MikeB wrote:In my tests I got a 99% los after 200 games so it did matter but - but may be specific to my hardware, my OS or my compiler - who knows I go by the results and the results speak for themselves.
I can see two possible explanations.
1. There is some problem in your test environment or your result was a statistical anomaly.
2. Your compiler is buggy.
If your compiler really generates different object code for the two source code versions, you should upgrade it to the latest version, or if you are already running the latest version, you should report the compiler bug to the compiler vendor.
I think explanation 1 is more likely to be true.