18#ifndef LLVM_IR_INSTITERATOR_H
19#define LLVM_IR_INSTITERATOR_H
32template <
class BB_t,
class BB_i_t,
class BI_t,
class II_t>
class InstIterator {
52 template<
typename A,
typename B,
typename C,
typename D>
54 : BBs(
II.BBs), BB(
II.BB), BI(
II.BI) {}
56 template<
typename A,
typename B,
typename C,
typename D>
58 : BBs(
II.BBs), BB(
II.BB), BI(
II.BI) {}
61 : BBs(&m.getBasicBlockList()), BB(BBs->begin()) {
62 if (BB != BBs->end()) {
69 : BBs(&m.getBasicBlockList()), BB(BBs->end()) {
80 return BB == y.BB && (BB == BBs->end() || BI == y.BI);
96 while (BB == BBs->end() || BI == BB->begin()) {
108 inline void advanceToNextBB() {
111 while (BI == BB->end()) {
113 if (BB == BBs->end())
break;
Expand Atomic instructions
uint64_t IntrinsicInst * II
InstListType::const_iterator const_iterator
InstListType::iterator iterator
Instruction iterators...
BasicBlockListType::iterator iterator
BasicBlockListType::const_iterator const_iterator
InstIterator & operator++()
reference operator*() const
InstIterator & operator--()
InstIterator(const InstIterator< A, B, C, D > &II)
bool operator!=(const InstIterator &y) const
bool operator==(const InstIterator &y) const
InstIterator operator++(int)
std::bidirectional_iterator_tag iterator_category
InstIterator(InstIterator< A, B, C, D > &II)
InstIterator operator--(int)
BIty & getInstructionIterator()
BBIty & getBasicBlockIterator()
pointer operator->() const
A range adaptor for a pair of iterators.
This provides a very simple, boring adaptor for a begin and end iterator into a range type.
This is an optimization pass for GlobalISel generic memory operations.
iterator_range< inst_iterator > inst_range
InstIterator< SymbolTableList< BasicBlock >, Function::iterator, BasicBlock::iterator, Instruction > inst_iterator
inst_iterator inst_begin(Function *F)
iterator_range< const_inst_iterator > const_inst_range
inst_iterator inst_end(Function *F)
InstIterator< const SymbolTableList< BasicBlock >, Function::const_iterator, BasicBlock::const_iterator, const Instruction > const_inst_iterator