Go to the documentation of this file.
24 #ifndef LLVM_IR_SYMBOLTABLELISTTRAITS_H
25 #define LLVM_IR_SYMBOLTABLELISTTRAITS_H
41 class ValueSymbolTable;
49 #define DEFINE_SYMBOL_TABLE_PARENT_TYPE(NODE, PARENT) \
50 template <> struct SymbolTableListParentType<NODE> { using type = PARENT; };
58 #undef DEFINE_SYMBOL_TABLE_PARENT_TYPE
65 template <
typename ValueSubClass>
69 using ItemParentClass =
78 ItemParentClass *getListOwner() {
79 size_t Offset =
reinterpret_cast<size_t>(
80 &((ItemParentClass *)nullptr->*ItemParentClass::getSublistAccess(
81 static_cast<ValueSubClass *
>(
83 ListTy *Anchor =
static_cast<ListTy *
>(
this);
84 return reinterpret_cast<ItemParentClass*
>(
reinterpret_cast<char*
>(Anchor)-
88 static ListTy &getList(ItemParentClass *Par) {
89 return Par->*(Par->getSublistAccess((ValueSubClass*)
nullptr));
92 static ValueSymbolTable *getSymTab(ItemParentClass *Par) {
93 return Par ?
toPtr(Par->getValueSymbolTable()) : nullptr;
102 template<
typename TPtr>
114 class SymbolTableList
115 :
public iplist_impl<simple_ilist<T>, SymbolTableListTraits<T>> {};
119 #endif // LLVM_IR_SYMBOLTABLELISTTRAITS_H
This is an optimization pass for GlobalISel generic memory operations.
This currently compiles esp xmm0 movsd esp eax eax esp ret We should use not the dag combiner This is because dagcombine2 needs to be able to see through the X86ISD::Wrapper which DAGCombine can t really do The code for turning x load into a single vector load is target independent and should be moved to the dag combiner The code for turning x load into a vector load can only handle a direct load from a global or a direct load from the stack It should be generalized to handle any load from P
#define DEFINE_SYMBOL_TABLE_PARENT_TYPE(NODE, PARENT)
SymbolTableListTraits()=default
static ValueSymbolTable * toPtr(ValueSymbolTable &R)
void removeNodeFromList(ValueSubClass *V)
Use delete by default for iplist and ilist.
@ BasicBlock
Various leaf nodes.
List that automatically updates parent links and symbol tables.
void addNodeToList(ValueSubClass *V)
void setSymTabObject(TPtr *, TPtr)
setSymTabObject - This is called when (f.e.) the parent of a basic block changes.
Machine Check Debug Module
Iterator for intrusive lists based on ilist_node.
static ValueSymbolTable * toPtr(ValueSymbolTable *P)
This class provides a symbol table of name/value pairs.
void transferNodesFromList(SymbolTableListTraits &L2, iterator first, iterator last)
Template metafunction to get the parent type for a symbol table list.