nki.isa.memset#

nki.isa.memset(dst, value, engine=engine.unknown, name=None)[source]#

Initialize a tile filled with a compile-time constant value using Vector or GpSimd Engine. The shape of the tile is specified in the shape field and the initialized value in the value field. The memset instruction supports all valid NKI dtypes (see Supported Data Types).

Parameters:
  • dst – a tile with shape shape whose elements are initialized to value.

  • value – the constant value to initialize with

  • engine – specify which engine to use for memset: nki.isa.vector_engine or nki.isa.gpsimd_engine ; nki.isa.unknown_engine by default, lets compiler select the best engine for the given input tile shape