[PATCH] D37097: Set hasSideEffects=0 for PHI and fix passes relying isSafeToMove/hasUnmodeledSideEffects being true for PHI
Quentin Colombet via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Aug 24 10:47:57 PDT 2017
qcolombet added inline comments.
================
Comment at: lib/CodeGen/MachineLICM.cpp:859
bool DontMoveAcrossStore = true;
- if (!I.isSafeToMove(AA, DontMoveAcrossStore))
+ if (I.isPHI() || !I.isSafeToMove(AA, DontMoveAcrossStore))
return false;
----------------
I would rather change isSafeToMove to return false for PHIs.
https://reviews.llvm.org/D37097
More information about the llvm-commits
mailing list