SetTilingKey
Description
Sets the tiling key.
Different kernel implementation branches can be identified by tiling keys. After a tiling key is set on the host, the corresponding branch can be selected. For example, an operator has different algorithm logics in different shapes. The kernel can use the tiling key to select a specific algorithm logic. However, the tiling algorithms on the host can be different, so the host and kernel can use the same tiling key for association.
Prototype
ge::graphStatus SetTilingKey(const uint64_t tiling_key)
Parameters
Parameter |
Input/Output |
Description |
|---|---|---|
tiling_key |
Input |
Tiling key to be set. |
Returns
ge::GRAPH_SUCCESS on success.
For details about the definition of graphStatus, see ge::graphStatus.
Restrictions
The value of tiling_key must be within the range of the uint64_t data type but cannot be UINT64_MAX.
Example
ge::graphStatus Tiling4XXX(TilingContext* context) {
auto ret = context->SetTilingKey(20);
// ...
}