tilelang.language.fill_op

Fill operations exposed on the TileLang language surface.

Functions

fill(buffer, value)

Fill a buffer or buffer region with a specified value.

clear(buffer)

Clear a buffer by filling it with zeros.

Module Contents

tilelang.language.fill_op.fill(buffer, value)

Fill a buffer or buffer region with a specified value.

参数:
  • buffer (tilelang._typing.BufferLikeType) -- Either a TVM buffer or buffer region to be filled

  • value (tvm.tir.PrimExpr) -- The value to fill the buffer with

返回:

A TVM intrinsic call that performs the fill operation

返回类型:

tvm.tir.PrimExpr

tilelang.language.fill_op.clear(buffer)

Clear a buffer by filling it with zeros.

参数:

buffer (tilelang._typing.BufferLikeType) -- Either a TVM buffer or a variable that contains a buffer region

返回:

A fill operation that sets the buffer contents to zero

抛出:

ValueError -- If the buffer variable contains an invalid buffer region

返回类型:

tvm.tir.PrimExpr