LLVM 24.0.0git
llvm::GenericUniformityInfo< ContextT > Class Template Reference

#include "llvm/ADT/GenericUniformityInfo.h"

Inheritance diagram for llvm::GenericUniformityInfo< ContextT >:
[legend]

Public Types

using BlockT = typename ContextT::BlockT
using FunctionT = typename ContextT::FunctionT
using ValueRefT = typename ContextT::ValueRefT
using ConstValueRefT = typename ContextT::ConstValueRefT
using UseT = typename ContextT::UseT
using InstructionT = typename ContextT::InstructionT
using DominatorTreeT = typename ContextT::DominatorTreeT
using ThisT = GenericUniformityInfo<ContextT>
using CycleInfoT = GenericCycleInfo<ContextT>
using TemporalDivergenceTuple

Public Member Functions

 GenericUniformityInfo (const DominatorTreeT &DT, const CycleInfoT &CI, const TargetTransformInfo *TTI=nullptr)
 GenericUniformityInfo ()=default
 GenericUniformityInfo (GenericUniformityInfo &&)=default
GenericUniformityInfooperator= (GenericUniformityInfo &&)=default
void compute ()
const FunctionTgetFunction () const
 The GPU kernel this analysis result is for.
const CycleInfoTgetCycleInfo () const
 The cycle info this analysis was computed with.
bool isDivergentAtDef (ConstValueRefT V) const
 Whether V is divergent at its definition.
bool isUniformAtDef (ConstValueRefT V) const
 Whether V is uniform/non-divergent at its definition.
bool isUniformTerminator (const InstructionT *I) const
bool isDivergentTerminator (const InstructionT *I) const
bool isDivergentAtUse (const UseT &U) const
 Whether U is divergent at its use.
bool isUniformAtUse (const UseT &U) const
 Whether U is uniform/non-divergent at its use.
bool hasDivergentTerminator (const BlockT &B)
void print (raw_ostream &Out) const
 T helper function for printing.
iterator_range< TemporalDivergenceTuple * > getTemporalDivergenceList () const

Detailed Description

template<typename ContextT>
class llvm::GenericUniformityInfo< ContextT >

Definition at line 29 of file GenericUniformityInfo.h.

Member Typedef Documentation

◆ BlockT

template<typename ContextT>
using llvm::GenericUniformityInfo< ContextT >::BlockT = typename ContextT::BlockT

Definition at line 31 of file GenericUniformityInfo.h.

◆ ConstValueRefT

template<typename ContextT>
using llvm::GenericUniformityInfo< ContextT >::ConstValueRefT = typename ContextT::ConstValueRefT

Definition at line 34 of file GenericUniformityInfo.h.

◆ CycleInfoT

template<typename ContextT>
using llvm::GenericUniformityInfo< ContextT >::CycleInfoT = GenericCycleInfo<ContextT>

Definition at line 40 of file GenericUniformityInfo.h.

◆ DominatorTreeT

template<typename ContextT>
using llvm::GenericUniformityInfo< ContextT >::DominatorTreeT = typename ContextT::DominatorTreeT

Definition at line 37 of file GenericUniformityInfo.h.

◆ FunctionT

template<typename ContextT>
using llvm::GenericUniformityInfo< ContextT >::FunctionT = typename ContextT::FunctionT

Definition at line 32 of file GenericUniformityInfo.h.

◆ InstructionT

template<typename ContextT>
using llvm::GenericUniformityInfo< ContextT >::InstructionT = typename ContextT::InstructionT

Definition at line 36 of file GenericUniformityInfo.h.

◆ TemporalDivergenceTuple

template<typename ContextT>
using llvm::GenericUniformityInfo< ContextT >::TemporalDivergenceTuple
Initial value:
std::tuple<ConstValueRefT, InstructionT *, CycleRef>

Definition at line 42 of file GenericUniformityInfo.h.

◆ ThisT

template<typename ContextT>
using llvm::GenericUniformityInfo< ContextT >::ThisT = GenericUniformityInfo<ContextT>

Definition at line 38 of file GenericUniformityInfo.h.

◆ UseT

template<typename ContextT>
using llvm::GenericUniformityInfo< ContextT >::UseT = typename ContextT::UseT

Definition at line 35 of file GenericUniformityInfo.h.

◆ ValueRefT

template<typename ContextT>
using llvm::GenericUniformityInfo< ContextT >::ValueRefT = typename ContextT::ValueRefT

Definition at line 33 of file GenericUniformityInfo.h.

Constructor & Destructor Documentation

◆ GenericUniformityInfo() [1/3]

template<typename ContextT>
llvm::GenericUniformityInfo< ContextT >::GenericUniformityInfo ( const DominatorTreeT & DT,
const CycleInfoT & CI,
const TargetTransformInfo * TTI = nullptr )

Definition at line 1193 of file GenericUniformityImpl.h.

◆ GenericUniformityInfo() [2/3]

template<typename ContextT>
llvm::GenericUniformityInfo< ContextT >::GenericUniformityInfo ( )
default

◆ GenericUniformityInfo() [3/3]

template<typename ContextT>
llvm::GenericUniformityInfo< ContextT >::GenericUniformityInfo ( GenericUniformityInfo< ContextT > && )
default

Member Function Documentation

◆ compute()

template<typename ContextT>
void llvm::GenericUniformityInfo< ContextT >::compute ( )
inline

Definition at line 51 of file GenericUniformityInfo.h.

Referenced by llvm::computeMachineUniformityInfo().

◆ getCycleInfo()

template<typename ContextT>
const GenericUniformityInfo< ContextT >::CycleInfoT & llvm::GenericUniformityInfo< ContextT >::getCycleInfo ( ) const

The cycle info this analysis was computed with.

Definition at line 1291 of file GenericUniformityImpl.h.

◆ getFunction()

template<typename ContextT>
const ContextT::FunctionT & llvm::GenericUniformityInfo< ContextT >::getFunction ( ) const

The GPU kernel this analysis result is for.

Definition at line 1285 of file GenericUniformityImpl.h.

◆ getTemporalDivergenceList()

template<typename ContextT>
iterator_range< typename GenericUniformityInfo< ContextT >::TemporalDivergenceTuple * > llvm::GenericUniformityInfo< ContextT >::getTemporalDivergenceList ( ) const

Definition at line 1278 of file GenericUniformityImpl.h.

References llvm::make_range().

◆ hasDivergentTerminator()

template<typename ContextT>
bool llvm::GenericUniformityInfo< ContextT >::hasDivergentTerminator ( const BlockT & B)

Definition at line 1316 of file GenericUniformityImpl.h.

References B().

◆ isDivergentAtDef()

template<typename ContextT>
bool llvm::GenericUniformityInfo< ContextT >::isDivergentAtDef ( ConstValueRefT V) const

Whether V is divergent at its definition.

A default-constructed instance (no analysis computed) reports everything as uniform, which is conservatively correct for non-divergent targets.

Definition at line 1299 of file GenericUniformityImpl.h.

Referenced by llvm::SITargetLowering::isSDNodeSourceOfDivergence(), llvm::GenericUniformityInfo< SSAContext >::isUniformAtDef(), and matchUniformityAndLLT().

◆ isDivergentAtUse()

template<typename ContextT>
bool llvm::GenericUniformityInfo< ContextT >::isDivergentAtUse ( const UseT & U) const

Whether U is divergent at its use.

Uses of a uniform value can be divergent.

Definition at line 1311 of file GenericUniformityImpl.h.

Referenced by isDivergentUseWithNew(), and llvm::GenericUniformityInfo< SSAContext >::isUniformAtUse().

◆ isDivergentTerminator()

template<typename ContextT>
bool llvm::GenericUniformityInfo< ContextT >::isDivergentTerminator ( const InstructionT * I) const

◆ isUniformAtDef()

template<typename ContextT>
bool llvm::GenericUniformityInfo< ContextT >::isUniformAtDef ( ConstValueRefT V) const
inline

Whether V is uniform/non-divergent at its definition.

Definition at line 66 of file GenericUniformityInfo.h.

Referenced by llvm::AMDGPU::SetOfRulesForOpcode::findMappingForMI(), isSCEVUniform(), and matchUniformityAndLLT().

◆ isUniformAtUse()

template<typename ContextT>
bool llvm::GenericUniformityInfo< ContextT >::isUniformAtUse ( const UseT & U) const
inline

Whether U is uniform/non-divergent at its use.

Definition at line 86 of file GenericUniformityInfo.h.

◆ isUniformTerminator()

template<typename ContextT>
bool llvm::GenericUniformityInfo< ContextT >::isUniformTerminator ( const InstructionT * I) const
inline

Definition at line 76 of file GenericUniformityInfo.h.

◆ operator=()

template<typename ContextT>
GenericUniformityInfo & llvm::GenericUniformityInfo< ContextT >::operator= ( GenericUniformityInfo< ContextT > && )
default

◆ print()

template<typename ContextT>
void llvm::GenericUniformityInfo< ContextT >::print ( raw_ostream & Out) const

T helper function for printing.

Definition at line 1322 of file GenericUniformityImpl.h.

Referenced by llvm::MachineUniformityPrinterPass::run().


The documentation for this class was generated from the following files: