summaryrefslogtreecommitdiffstats
path: root/llvm/unittests/IR/BasicBlockTest.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Remove unnecessary double-assignment triggering -Wsequence-point.Daniel Jasper2017-05-261-1/+1
| | | | llvm-svn: 303974
* [IR] Add an iterator and range accessor for the PHI nodes of a basicChandler Carruth2017-05-261-0/+75
block. This allows writing much more natural and readable range based for loops directly over the PHI nodes. It also takes advantage of the same tricks for terminating the sequence as the hand coded versions. I've replaced one example of this mostly to showcase the difference and I've added a unit test to make sure the facilities really work the way they're intended. I want to use this inside of SimpleLoopUnswitch but it seems generally nice. Differential Revision: https://reviews.llvm.org/D33533 llvm-svn: 303964
OpenPOWER on IntegriCloud