15 #ifndef LLVM_TRANSFORMS_IPO_LOWERTYPETESTS_H 16 #define LLVM_TRANSFORMS_IPO_LOWERTYPETESTS_H 29 class ModuleSummaryIndex;
32 namespace lowertypetests {
50 return Bits.size() == 1;
136 : Fragments(1), FragmentMap(NumObjects) {}
141 void addFragment(
const std::set<uint64_t> &
F);
179 enum { BitsPerByte = 8 };
182 uint64_t BitAllocs[BitsPerByte];
185 memset(BitAllocs, 0,
sizeof(BitAllocs));
193 void allocate(
const std::set<uint64_t> &
Bits, uint64_t
BitSize,
194 uint64_t &AllocByteOffset, uint8_t &AllocMask);
205 : ExportSummary(ExportSummary), ImportSummary(ImportSummary) {}
211 #endif // LLVM_TRANSFORMS_IPO_LOWERTYPETESTS_H
This class implements a layout algorithm for globals referenced by bit sets that tries to keep member...
This class is used to build a byte array containing overlapping bit sets.
GCNRegPressure max(const GCNRegPressure &P1, const GCNRegPressure &P2)
This class represents lattice values for constants.
A Module instance is used to store all the information related to an LLVM module. ...
void push_back(const T &Elt)
void print(raw_ostream &OS) const
void addOffset(uint64_t Offset)
bool isSingleOffset() const
std::vector< uint8_t > Bytes
The byte array built so far.
std::vector< uint64_t > FragmentMap
Mapping from object index to fragment index.
const ModuleSummaryIndex * ImportSummary
ModuleSummaryIndex * ExportSummary
A CRTP mix-in to automatically provide informational APIs needed for passes.
bool containsGlobalOffset(uint64_t Offset) const
Class to hold module path string table and global value map, and encapsulate methods for operating on...
Error build(ArrayRef< Module *> Mods, SmallVector< char, 0 > &Symtab, StringTableBuilder &StrtabBuilder, BumpPtrAllocator &Alloc)
Fills in Symtab and StrtabBuilder with a valid symbol and string table for Mods.
A set of analyses that are preserved following a run of a transformation pass.
SmallVector< uint64_t, 16 > Offsets
LowerTypeTestsPass(ModuleSummaryIndex *ExportSummary, const ModuleSummaryIndex *ImportSummary)
GlobalLayoutBuilder(uint64_t NumObjects)
This class implements an extremely fast bulk output stream that can only output to a stream...
A container for analyses that lazily runs them and caches their results.
std::set< uint64_t > Bits
This header defines various interfaces for pass management in LLVM.
std::vector< std::vector< uint64_t > > Fragments
The computed layout.