Trait that defines how to profile an object of type T for a FoldingSet.
Declared in <llvm/ADT/FoldingSet.h>
template<
typename T,
typename Enable = void>
struct FoldingSetTrait
: DefaultFoldingSetTrait<T>
The default behavior is to invoke a 'Profile' method on an object, but through template specialization the behavior can be tailored for specific types. Combined with the FoldingSetNodeWrapper class, one can add objects to FoldingSets that were not originally designed to have that behavior.
| Name | Description |
|---|---|
DefaultFoldingSetTrait<T> | Default implementations for FoldingSetTrait operations on type T. |
| Name | Description |
|---|---|
ContextStorage | Empty marker type when no folding-set context is stored. |
| Name | Description |
|---|---|
ComputeHash | Compute a hash value for X. |
Equals | Return whether X's profile matches ID. |
Profile | Gather the unique data bits of X into ID by calling X's Profile method. |
| Name | Description |
|---|---|
FoldingSetTrait<SCEV> | FoldingSetTrait specialization for SCEV using interned FastID. |
FoldingSetTrait<SCEVPredicate> | FoldingSetTrait specialization for SCEVPredicate using interned FastID. |
FoldingSetTrait<SDVTListNode> | Specialize FoldingSetTrait for SDVTListNode to avoid computing temp FoldingSetNodeID and hash value. |
FoldingSetTrait<T> | Profile an enumeration by adding its underlying integer value. |
FoldingSetTrait<T*> | Profile a pointer by adding its address to the folding-set node ID. |
FoldingSetTrait<std::pair<T1, T2>> | Profile a pair by profiling both of its elements. |