aboutsummaryrefslogtreecommitdiff
path: root/lib/Support/Unix/Unix.h
diff options
context:
space:
mode:
authorChandler Carruth <chandlerc@gmail.com>2012-11-30 09:34:29 +0000
committerChandler Carruth <chandlerc@gmail.com>2012-11-30 09:34:29 +0000
commit66ea2f99867ffc8606737199e359516fd1cfc67c (patch)
tree0feab8c92f080884cd3c3823f59a57144a287c82 /lib/Support/Unix/Unix.h
parent06ec7211c17a4b45a943c36e0fb3d6715aa2453d (diff)
Fix non-determinism introduced in r168970 and pointed out by Duncan.
We're iterating over a non-deterministically ordered container looking for two saturating flags. To do this correctly, we have to saturate both, and only stop looping if both saturate to their final value. Otherwise, which flag we see first changes the result. This is also a micro-optimization of the previous version as now we don't go into the (possibly expensive) test logic once the first violation of either constraint is detected. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168989 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Support/Unix/Unix.h')
0 files changed, 0 insertions, 0 deletions