Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Showing
1 changed file
with
15 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
43682d0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I notice that now we get a (bogus) "uninitialized" warning for
value
in line 785, at least with mingw on Windows.Obviously we never use
value
uninitialized, however are we ok with having this warning?43682d0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it bogus ? I can't see where it is initialized. I could be wrong that's a big file.
43682d0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Before it was if(depth !=5) ... if(depth==5) so it was ok but now it is if(depth>5) if(depth ==5 ) so you could reach || value>= rbeta without having initialized it in the previous if, if depth < 5.
43682d0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
besides, the comment "// If the first search was skipped or was performed and held, perform
// the regular search." is invalid too, it should be if(depth >5) ... if(depth <=5) if we want to use inequalities
43682d0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Hanamuke
ProbCut is only done for depth >= 5 * ONE_PLY, which is why we never use the value uninitialized as it stands.
43682d0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No warning here. It also passed both checks, AppVeyor and Travis CI.
43682d0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@joergoster
Are you on Linux? Because I only get a warning on Windows. Note that there is a thread in the forum about this compiler warning too.
43682d0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is a warning in the appveyor and travis builds, i checked. But i can't blame gcc to not notice it is initialized on all paths. Changing if(depth==5) to if(depth<=5) would probably fix the warning, but it's no big deal really.
43682d0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jerrydonaldwatson Yes, Linux only.
43682d0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
gcc 7.0 seem to produce a warning too, in the travis CI build
43682d0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@snicolet Do we want to suppress this silly warning and revert the change in the ProbCut code?
43682d0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Warning fixed in d42e633, thanks.