diff options
| author | Max Kazantsev <max.kazantsev@azul.com> | 2018-08-15 05:55:43 +0000 |
|---|---|---|
| committer | Max Kazantsev <max.kazantsev@azul.com> | 2018-08-15 05:55:43 +0000 |
| commit | 530b8d1c3d6a316b1e7c33471a38bc4d7dfb56dd (patch) | |
| tree | 990e1367a3e312731d101bc692f3ed608105ee5d /llvm/lib/Transforms/Scalar/LoopIdiomRecognize.cpp | |
| parent | df58dd84182a78ac48e1199ca95e9ecbab9db1ea (diff) | |
| download | bcm5719-llvm-530b8d1c3d6a316b1e7c33471a38bc4d7dfb56dd.tar.gz bcm5719-llvm-530b8d1c3d6a316b1e7c33471a38bc4d7dfb56dd.zip | |
[NFC] Refactoring of LoopSafetyInfo, step 1
Turn structure into class, encapsulate methods, add clarifying comments.
Differential Revision: https://reviews.llvm.org/D50693
Reviewed By: reames
llvm-svn: 339752
Diffstat (limited to 'llvm/lib/Transforms/Scalar/LoopIdiomRecognize.cpp')
| -rw-r--r-- | llvm/lib/Transforms/Scalar/LoopIdiomRecognize.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/Transforms/Scalar/LoopIdiomRecognize.cpp b/llvm/lib/Transforms/Scalar/LoopIdiomRecognize.cpp index 653948717fb..880cbc3db88 100644 --- a/llvm/lib/Transforms/Scalar/LoopIdiomRecognize.cpp +++ b/llvm/lib/Transforms/Scalar/LoopIdiomRecognize.cpp @@ -320,8 +320,8 @@ bool LoopIdiomRecognize::runOnCountableLoop() { // The following transforms hoist stores/memsets into the loop pre-header. // Give up if the loop has instructions may throw. LoopSafetyInfo SafetyInfo; - computeLoopSafetyInfo(&SafetyInfo, CurLoop); - if (SafetyInfo.MayThrow) + SafetyInfo.computeLoopSafetyInfo(CurLoop); + if (SafetyInfo.anyBlockMayThrow()) return MadeChange; // Scan all the blocks in the loop that are not in subloops. |

