Go to the documentation of this file.
10 #ifdef EXPENSIVE_CHECKS
25 class StructuralHash {
26 uint64_t Hash = 0x6acaa36bef8325c5ULL;
31 StructuralHash() =
default;
43 BBs.push_back(&
F.getEntryBlock());
45 while (!BBs.empty()) {
48 for (
auto &Inst : *
BB)
49 update(Inst.getOpcode());
52 for (
unsigned i = 0,
e =
Term->getNumSuccessors();
i !=
e; ++
i) {
53 if (!VisitedBBs.
insert(
Term->getSuccessor(
i)).second)
55 BBs.push_back(
Term->getSuccessor(
i));
60 void update(
const Module &M) {
65 uint64_t getHash()
const {
return Hash; }
73 details::StructuralHash
H;
79 details::StructuralHash
H;
This is an optimization pass for GlobalISel generic memory operations.
This is a 'vector' (really, a variable-sized array), optimized for the case when the array is small.
SmallPtrSet - This class implements a set which is optimized for holding SmallSize or less elements.
LLVM_NODISCARD T pop_back_val()
LLVM Basic Block Representation.
uint64_t hash_16_bytes(uint64_t low, uint64_t high)
A Module instance is used to store all the information related to an LLVM module.
Common register allocation spilling lr str ldr sxth r3 ldr mla r4 can lr mov lr str ldr sxth r3 mla r4 and then merge mul and lr str ldr sxth r3 mla r4 It also increase the likelihood the store may become dead bb27 Successors according to LLVM BB
std::pair< iterator, bool > insert(PtrType Ptr)
Inserts Ptr if and only if there is no element in the container equal to Ptr.