flang-compiler / f18

F18 is a front-end for Fortran intended to replace the existing front-end in the Flang compiler
230 stars 48 forks source link

[OpenMP] Avoid abort when collapse clause value is negative #1098

Closed clementval closed 4 years ago

clementval commented 4 years ago

If the value in the collapse close is negative f18 abort without the correct error message. This PR change the size_t in name resolution to a int64_t and check appropriately for negative or zero before the privatization of induction variable. The correct error is then catch by the OpenMP structure check.

clementval commented 4 years ago

Thanks for the review @ichoyjx

clementval commented 4 years ago

@ichoyjx I close the Pull Request since the repo as move to the llvm monorepo. I'll open a new one in phabricator.