LLVM 22.0.0git
llvm::AMDGPU::Waitcnt Struct Reference

Represents the counter values to wait for in an s_waitcnt instruction. More...

#include "Target/AMDGPU/Utils/AMDGPUBaseInfo.h"

Public Member Functions

 Waitcnt ()=default
 Waitcnt (unsigned VmCnt, unsigned ExpCnt, unsigned LgkmCnt, unsigned VsCnt)
 Waitcnt (unsigned LoadCnt, unsigned ExpCnt, unsigned DsCnt, unsigned StoreCnt, unsigned SampleCnt, unsigned BvhCnt, unsigned KmCnt, unsigned XCnt)
bool hasWait () const
bool hasWaitExceptStoreCnt () const
bool hasWaitStoreCnt () const
Waitcnt combined (const Waitcnt &Other) const

Public Attributes

unsigned LoadCnt = ~0u
unsigned ExpCnt = ~0u
unsigned DsCnt = ~0u
unsigned StoreCnt = ~0u
unsigned SampleCnt = ~0u
unsigned BvhCnt = ~0u
unsigned KmCnt = ~0u
unsigned XCnt = ~0u

Detailed Description

Represents the counter values to wait for in an s_waitcnt instruction.

Large values (including the maximum possible integer) can be used to represent "don't care" waits.

Definition at line 1075 of file AMDGPUBaseInfo.h.

Constructor & Destructor Documentation

◆ Waitcnt() [1/3]

llvm::AMDGPU::Waitcnt::Waitcnt ( )
default

Referenced by combined().

◆ Waitcnt() [2/3]

llvm::AMDGPU::Waitcnt::Waitcnt ( unsigned VmCnt,
unsigned ExpCnt,
unsigned LgkmCnt,
unsigned VsCnt )
inline

Definition at line 1087 of file AMDGPUBaseInfo.h.

References DsCnt, ExpCnt, LoadCnt, and StoreCnt.

◆ Waitcnt() [3/3]

llvm::AMDGPU::Waitcnt::Waitcnt ( unsigned LoadCnt,
unsigned ExpCnt,
unsigned DsCnt,
unsigned StoreCnt,
unsigned SampleCnt,
unsigned BvhCnt,
unsigned KmCnt,
unsigned XCnt )
inline

Definition at line 1091 of file AMDGPUBaseInfo.h.

References BvhCnt, DsCnt, ExpCnt, KmCnt, LoadCnt, SampleCnt, StoreCnt, and XCnt.

Member Function Documentation

◆ combined()

Waitcnt llvm::AMDGPU::Waitcnt::combined ( const Waitcnt & Other) const
inline

Definition at line 1105 of file AMDGPUBaseInfo.h.

References BvhCnt, DsCnt, ExpCnt, KmCnt, LoadCnt, llvm::Other, SampleCnt, StoreCnt, Waitcnt(), and XCnt.

◆ hasWait()

bool llvm::AMDGPU::Waitcnt::hasWait ( ) const
inline

Definition at line 1096 of file AMDGPUBaseInfo.h.

References hasWaitExceptStoreCnt(), and StoreCnt.

◆ hasWaitExceptStoreCnt()

bool llvm::AMDGPU::Waitcnt::hasWaitExceptStoreCnt ( ) const
inline

Definition at line 1098 of file AMDGPUBaseInfo.h.

References BvhCnt, DsCnt, ExpCnt, KmCnt, LoadCnt, SampleCnt, and XCnt.

Referenced by hasWait().

◆ hasWaitStoreCnt()

bool llvm::AMDGPU::Waitcnt::hasWaitStoreCnt ( ) const
inline

Definition at line 1103 of file AMDGPUBaseInfo.h.

References StoreCnt.

Member Data Documentation

◆ BvhCnt

unsigned llvm::AMDGPU::Waitcnt::BvhCnt = ~0u

Definition at line 1081 of file AMDGPUBaseInfo.h.

Referenced by combined(), hasWaitExceptStoreCnt(), and Waitcnt().

◆ DsCnt

◆ ExpCnt

unsigned llvm::AMDGPU::Waitcnt::ExpCnt = ~0u

◆ KmCnt

unsigned llvm::AMDGPU::Waitcnt::KmCnt = ~0u

Definition at line 1082 of file AMDGPUBaseInfo.h.

Referenced by combined(), hasWaitExceptStoreCnt(), and Waitcnt().

◆ LoadCnt

◆ SampleCnt

unsigned llvm::AMDGPU::Waitcnt::SampleCnt = ~0u

Definition at line 1080 of file AMDGPUBaseInfo.h.

Referenced by combined(), hasWaitExceptStoreCnt(), and Waitcnt().

◆ StoreCnt

unsigned llvm::AMDGPU::Waitcnt::StoreCnt = ~0u

◆ XCnt

unsigned llvm::AMDGPU::Waitcnt::XCnt = ~0u

Definition at line 1083 of file AMDGPUBaseInfo.h.

Referenced by combined(), hasWaitExceptStoreCnt(), and Waitcnt().


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