21#define DEBUG_TYPE "Range"
33 <<
"Range: [" <<
hexValue(RangeEntry.lower()) <<
":"
34 <<
hexValue(RangeEntry.upper()) <<
"]\n";
37 RangesTree.insert(RangeEntry.lower(), RangeEntry.upper(),
45 dbgs() <<
"\nRanges Tree:\n";
46 RangesTree.print(
dbgs());
56 if (LowerAddress > UpperAddress)
60 if (LowerAddress < Lower)
62 if (UpperAddress > Upper)
66 RangeEntries.emplace_back(LowerAddress, UpperAddress,
Scope);
91 for (LVRangesTree::find_iterator Iter = RangesTree.find(
Address),
92 End = RangesTree.find_end();
93 Iter != End; ++Iter) {
95 dbgs() <<
formatv(
"[{0:x8},{1:x8}] ", Iter->left(), Iter->right());
97 Scope = Iter->value();
99 if (
Level > TargetLevel) {
114 if (LowerAddress >= RangeEntry.lower() && UpperAddress < RangeEntry.upper())
115 return RangeEntry.scope();
122 if (LowerAddress == RangeEntry.lower() &&
123 UpperAddress == RangeEntry.upper())
132 if (lhs.
lower() < rhs.lower())
137 if (lhs.
lower() == rhs.lower())
138 return lhs.
upper() < rhs.upper();
148 size_t Indentation = 0;
155 OS <<
formatv(
"[{0:x8},{1:x8}] ", RangeEntry.lower(), RangeEntry.upper())
assert(UImm &&(UImm !=~static_cast< T >(0)) &&"Invalid immediate!")
Target - Wrapper for Target specific information.
size_t indentationSize() const
LVScope * getEntry(LVAddress Address) const
bool hasEntry(LVAddress Low, LVAddress High) const
void printExtra(raw_ostream &OS, bool Full=true) const override
void print(raw_ostream &OS, bool Full=true) const override
void addEntry(LVScope *Scope, LVAddress LowerAddress, LVAddress UpperAddress)
This class implements an extremely fast bulk output stream that can only output to a stream.
FormattedNumber hexValue(uint64_t N, unsigned Width=HEX_WIDTH, bool Upper=false)
std::string formattedKind(StringRef Kind)
std::string formattedName(StringRef Name)
SmallVector< LVLocation *, 8 > LVLocations
This is an optimization pass for GlobalISel generic memory operations.
void stable_sort(R &&Range)
FormattedNumber format_decimal(int64_t N, unsigned Width)
format_decimal - Output N as a right justified, fixed-width decimal.
auto formatv(bool Validate, const char *Fmt, Ts &&...Vals)
LLVM_ABI raw_ostream & dbgs()
dbgs() - This returns a reference to a raw_ostream for debugging messages.
void swap(llvm::BitVector &LHS, llvm::BitVector &RHS)
Implement std::swap in terms of BitVector swap.