-
Notifications
You must be signed in to change notification settings - Fork 9.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: index variable in OpenMP 'for' statement must have signed integr…
…al type
- Loading branch information
Showing
2 changed files
with
2 additions
and
2 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
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
bc7a7ee
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.
264dfb3
#3285
#3475
bc7a7ee
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.
This commit produces a compiler warning:
Why was that change needed? I thought that there was already a solution for MSVC and OpenCL which worked with unsigned integers?
bc7a7ee
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 tried to simplify cmake OpenMP with MSVC + get rid off the warning "overriding '/openmp' with '/openmp:llvm'" and I finished at the stage I need this change to compile tesseract...
Neither MSVC 2019 nor clang 15 produce such a warning with this change so I conder it as safe..
We can revert this as I did not finish this change.
bc7a7ee
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.
Microsoft officially supports the msvc with openmp-llvm runtime combo and tells developers to use it if they need openmp>2.0, which is exactly what we did prior to this commit.
bc7a7ee
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.
As the commit produces two compiler warnings with Linux autoconf builds (regression), it should be either reverted (my favorite), or we need conditional code for MSVC and other compilers.