size_t has different width on 32- and 64-bit architecture, but the
computation to floor to power of two assumed it is 64-bit, which can cause an
integer overflow. In this patch, architecture detection is added so that the
operation for 64-bit size_t. Thank Luke for reporting the issue.
Details
Details
- Reviewers
jdoerfert lbenes - Commits
- rG3091ed099f2f: [OpenMP] Fixed a potential integer overflow
Diff Detail
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
Comment Actions
LGTM.
Though, now that D89426 landed we could also call the LLVM ADT method for this ;)