[OpenMP][FIX] Disabled optimizations have to be made known
authorJohannes Doerfert <johannes@jdoerfert.de>
Tue, 10 Aug 2021 18:24:34 +0000 (13:24 -0500)
committerJohannes Doerfert <johannes@jdoerfert.de>
Wed, 11 Aug 2021 05:49:53 +0000 (00:49 -0500)
commite0c5d83a927382f50169a579e07e14fa0aebe335
tree76c2d0d0485fb396eb84fcc2de853c8096e5ea37
parenta8ae41fb518768fcc385b31fa1b16b20817cc1e7
[OpenMP][FIX] Disabled optimizations have to be made known

To avoid simplification with wrong constants we need to make sure we
know that we won't perform specific optimizations based on the users
request. The non-SPMDzation and non-CustomStateMachine flags did only
prevent the final transformation but allowed to value simplification
to go ahead.

Differential Revision: https://reviews.llvm.org/D107862
llvm/lib/Transforms/IPO/OpenMPOpt.cpp
llvm/test/Transforms/OpenMP/spmdization.ll