GetUbSize

Description

Obtains the size of the Unified Buffer (UB) on the platform, in bytes.

Prototype

template <typename T>
uint32_t GetUbSize(const T *context)

Parameters

Parameter

Input/Output

Description

context

Input

Tiling context, of TilingContext or TilingParseContext type.

Return Value

uint64_t: size of the platform UB. Value 0 means the size failed to be obtained.

Constraints

None.

Example

The following sample code is for reference only. Do not copy and run it.

1
compileInfo->ubSize = GetUbSize(context_);