aboutsummaryrefslogtreecommitdiff
path: root/clang/unittests/Tooling/RefactoringTest.cpp
diff options
context:
space:
mode:
authorFlorian Hahn <florian.hahn@arm.com>2017-07-31 09:00:52 +0000
committerFlorian Hahn <florian.hahn@arm.com>2017-07-31 09:00:52 +0000
commit4284049dcc3ddf9cf30f110007641596de4b265c (patch)
tree403a9b67b6b058556bccc93177ba702ccc5663ce /clang/unittests/Tooling/RefactoringTest.cpp
parentb169d56dc36ada9aa137763fa50056790513ee7a (diff)
downloadllvm-4284049dcc3ddf9cf30f110007641596de4b265c.zip
llvm-4284049dcc3ddf9cf30f110007641596de4b265c.tar.gz
llvm-4284049dcc3ddf9cf30f110007641596de4b265c.tar.bz2
[LoopInterchange] Do not interchange loops with function calls.
Summary: Without any information about the called function, we cannot be sure that it is safe to interchange loops which contain function calls. For example there could be dependences that prevent interchanging between accesses in the called function and the loops. Even functions without any parameters could cause problems, as they could access memory using global pointers. For now, I think it is only safe to interchange loops with calls marked as readnone. With this patch, the LLVM test suite passes with `-O3 -mllvm -enable-loopinterchange` and LoopInterchangeProfitability::isProfitable returning true for all loops. check-llvm and check-clang also pass when bootstrapped in a similar fashion, although only 3 loops got interchanged. Reviewers: karthikthecool, blitz.opensource, hfinkel, mcrosier, mkuper Reviewed By: mcrosier Subscribers: mzolotukhin, llvm-commits Differential Revision: https://reviews.llvm.org/D35489 llvm-svn: 309547
Diffstat (limited to 'clang/unittests/Tooling/RefactoringTest.cpp')
0 files changed, 0 insertions, 0 deletions