LLVM 19.0.0git
Public Member Functions | List of all members
llvm::SetState< BaseTy >::SetContents Struct Reference

A wrapper around a set that has semantics for handling unions and intersections with a "universal" set that contains all elements. More...

#include "llvm/Transforms/IPO/Attributor.h"

Public Member Functions

 SetContents (bool Universal)
 Creates a universal set with no concrete elements or an empty set.
 
 SetContents (const DenseSet< BaseTy > &Assumptions)
 Creates a non-universal set with concrete values.
 
 SetContents (bool Universal, const DenseSet< BaseTy > &Assumptions)
 
const DenseSet< BaseTy > & getSet () const
 
bool isUniversal () const
 
bool empty () const
 
bool getIntersection (const SetContents &RHS)
 Finds A := A ^ B where A or B could be the "Universal" set which contains every possible attribute.
 
bool getUnion (const SetContents &RHS)
 Finds A := A u B where A or B could be the "Universal" set which contains every possible attribute.
 

Detailed Description

template<typename BaseTy>
struct llvm::SetState< BaseTy >::SetContents

A wrapper around a set that has semantics for handling unions and intersections with a "universal" set that contains all elements.

Definition at line 3043 of file Attributor.h.

Constructor & Destructor Documentation

◆ SetContents() [1/3]

template<typename BaseTy >
llvm::SetState< BaseTy >::SetContents::SetContents ( bool  Universal)
inline

Creates a universal set with no concrete elements or an empty set.

Definition at line 3045 of file Attributor.h.

◆ SetContents() [2/3]

template<typename BaseTy >
llvm::SetState< BaseTy >::SetContents::SetContents ( const DenseSet< BaseTy > &  Assumptions)
inline

Creates a non-universal set with concrete values.

Definition at line 3048 of file Attributor.h.

◆ SetContents() [3/3]

template<typename BaseTy >
llvm::SetState< BaseTy >::SetContents::SetContents ( bool  Universal,
const DenseSet< BaseTy > &  Assumptions 
)
inline

Definition at line 3051 of file Attributor.h.

Member Function Documentation

◆ empty()

template<typename BaseTy >
bool llvm::SetState< BaseTy >::SetContents::empty ( ) const
inline

◆ getIntersection()

template<typename BaseTy >
bool llvm::SetState< BaseTy >::SetContents::getIntersection ( const SetContents RHS)
inline

Finds A := A ^ B where A or B could be the "Universal" set which contains every possible attribute.

Returns true if changes were made.

Definition at line 3062 of file Attributor.h.

References RHS, llvm::set_intersect(), llvm::detail::DenseSetImpl< ValueT, MapTy, ValueInfoT >::size(), and Size.

Referenced by llvm::SetState< BaseTy >::getIntersection().

◆ getSet()

template<typename BaseTy >
const DenseSet< BaseTy > & llvm::SetState< BaseTy >::SetContents::getSet ( ) const
inline

◆ getUnion()

template<typename BaseTy >
bool llvm::SetState< BaseTy >::SetContents::getUnion ( const SetContents RHS)
inline

Finds A := A u B where A or B could be the "Universal" set which contains every possible attribute.

returns true if changes were made.

Definition at line 3082 of file Attributor.h.

References RHS, llvm::set_union(), llvm::detail::DenseSetImpl< ValueT, MapTy, ValueInfoT >::size(), and Size.

Referenced by llvm::SetState< BaseTy >::getIntersection(), and llvm::SetState< BaseTy >::getUnion().

◆ isUniversal()

template<typename BaseTy >
bool llvm::SetState< BaseTy >::SetContents::isUniversal ( ) const
inline

Definition at line 3056 of file Attributor.h.

Referenced by llvm::SetState< BaseTy >::getIntersection().


The documentation for this struct was generated from the following file: