| AI Engine API User Guide (AIE-API) 2026.1

Loading...
Searching...
No Matches
stream.hpp File Reference
`#include <algorithm>`
`#include <adf.h>`
`#include "../aie.hpp"`
`#include "../sliding_mul.hpp"`

## Classes
struct | aie::tlast< T, Bool >
| Type used to wrap objects read/written from/to streams that also encapsulates TLAST information. More...

## Namespaces
namespace | aie
| Base namespace for AIE operations and types.

## Concepts
concept | aie::aie::TLast
| Concept for tlast objects passed to << and >> operators with streams.
concept | aie::TLast

## Macros
#define | __AIE_API_AIE_ADF_STREAM_HPP__

## Functions
template<unsigned Lanes, unsigned Points, int CoeffStep, int DataStepX, int DataStepY, aie::ElemBaseType CoeffType, aie::ElemBaseType DataType, aie::AccumElemBaseType AccumTag>
output_cascade< AccumTag, void > & | operator<< (output_cascade< AccumTag, void > &cascade, const aie::partial_sliding_mul< Lanes, Points, CoeffStep, DataStepX, DataStepY, CoeffType, DataType, AccumTag > &value)
| Writes a partial_sliding_mul value to a cascade output port.
template<aie::AccumElemBaseType T, unsigned N>
constexpr output_cascade< T > & | operator<< (output_cascade< T > &w, const aie::accum< T, N > &acc)
| Writes an accumulator into the output cascade stream.
template<aie::ElemBaseType T, unsigned N>
constexpr output_cascade< T > & | operator<< (output_cascade< T > &w, const aie::vector< T, N > &v)
| Writes a vector into the output cascade stream.
template<aie::AccumElemBaseType T, unsigned N>
constexpr output_cascade< T > * | operator<< (output_cascade< T > *w, const aie::accum< T, N > &acc)
| Writes an accumulator into the output cascade stream.
template<aie::ElemBaseType T, unsigned N>
constexpr output_cascade< T > * | operator<< (output_cascade< T > *w, const aie::vector< T, N > &v)
| Writes a vector into the output cascade stream.
template<aie::AccumElemBaseType T, unsigned N>
constexpr output_stream< T > & | operator<< (output_stream< T > &w, const aie::accum< T, N > &acc)
| Writes an accumulator into the output cascade stream.
template<typename T, unsigned N>
constexpr output_stream< T > & | operator<< (output_stream< T > &w, const aie::vector< T, N > &v)
| Writes a vector into the output AXI stream.
template<typename T>
constexpr output_stream< T > & | operator<< (output_stream< T > &w, const T &v)
| Writes a value into the output AXI stream.
template<typename T, aie::TLast< T > TL>
constexpr output_stream< T > & | operator<< (output_stream< T > &w, const TL &tl)
| Writes a value or vector into the output AXI stream.
template<aie::AccumElemBaseType T, unsigned N>
constexpr output_stream< T > * | operator<< (output_stream< T > *w, const aie::accum< T, N > &acc)
| Writes an accumulator into the output cascade stream.
template<typename T, unsigned N>
constexpr output_stream< T > * | operator<< (output_stream< T > *w, const aie::vector< T, N > &v)
| Writes a vector into the output AXI stream.
template<typename T>
constexpr output_stream< T > & | operator<< (output_stream< T > *w, const T &v)
| Writes a value into the output AXI stream.
template<typename T, aie::TLast< T > TL>
constexpr output_stream< T > * | operator<< (output_stream< T > *w, const TL &tl)
| Writes a value into the output AXI stream.
template<unsigned Lanes, unsigned Points, int CoeffStep, int DataStepX, int DataStepY, aie::ElemBaseType CoeffType, aie::ElemBaseType DataType, aie::AccumElemBaseType AccumTag>
input_cascade< AccumTag, void > & | operator>> (input_cascade< AccumTag, void > &cascade, aie::partial_sliding_mul< Lanes, Points, CoeffStep, DataStepX, DataStepY, CoeffType, DataType, AccumTag > &value)
| Reads a partial_sliding_mul value from a cascade port.
template<unsigned N, aie::AccumElemBaseType T>
constexpr input_cascade< T > & | operator>> (input_cascade< T > &w, aie::accum< T, N > &acc)
| Reads an accumulator from the input cascade stream.
template<unsigned N, aie::ElemBaseType T>
constexpr input_cascade< T > & | operator>> (input_cascade< T > &w, aie::vector< T, N > &v)
| Reads a vector from the input cascade stream.
template<unsigned N, aie::AccumElemBaseType T>
constexpr input_cascade< T > * | operator>> (input_cascade< T > *w, aie::accum< T, N > &acc)
| Reads an accumulator from the input cascade stream.
template<unsigned N, aie::ElemBaseType T>
constexpr input_cascade< T > * | operator>> (input_cascade< T > *w, aie::vector< T, N > &v)
| Reads a vector from the input cascade stream.
template<unsigned N, aie::AccumElemBaseType T>
constexpr input_stream< T > & | operator>> (input_stream< T > &w, aie::accum< T, N > &acc)
| Reads an accumulator from the input cascade stream.
template<unsigned N, typename T>
constexpr input_stream< T > & | operator>> (input_stream< T > &w, aie::vector< T, N > &v)
| Reads a vector from the input AXI stream.
template<typename T, aie::TLast< T > TL>
constexpr input_stream< T > & | operator>> (input_stream< T > &w, const TL &tl)
| Reads a value or vector from the input AXI stream.
template<typename T>
constexpr input_stream< T > & | operator>> (input_stream< T > &w, T &v)
| Reads a value from the input AXI stream.
template<unsigned N, aie::AccumElemBaseType T>
constexpr input_stream< T > * | operator>> (input_stream< T > *w, aie::accum< T, N > &acc)
| Reads an accumulator from the input cascade stream.
template<unsigned N, typename T>
constexpr input_stream< T > * | operator>> (input_stream< T > *w, aie::vector< T, N > &v)
| Reads a vector from the input AXI stream.
template<typename T, aie::TLast< T > TL>
constexpr input_stream< T > * | operator>> (input_stream< T > *w, const TL &tl)
| Reads a value or vector from the input AXI stream.
template<typename T>
constexpr input_stream< T > & | operator>> (input_stream< T > *w, T &v)
| Reads a value from the input AXI stream.
template<unsigned N, aie::AccumElemBaseType T>
aie::accum< T, N > | readincr_v (input_cascade< T > *w)
| Reads an accumulator from the input cascade stream.
template<unsigned N, aie::ElemBaseType T>
aie::vector< T, N > | readincr_v (input_cascade< T > *w)
| Reads a vector from the input cascade stream.
template<unsigned N, aie::AccumElemBaseType T>
aie::accum< T, N > | readincr_v (input_stream< T > *w)
| Reads an accumulator from the input cascade stream.
template<unsigned N, aie_stream_resource_in Resource = aie_stream_resource_in::none, typename T>
aie::vector< T, N > | readincr_v (input_stream< T > *w)
| Reads a vector from the input AXI stream.
template<unsigned N, aie_stream_resource_in Resource = aie_stream_resource_in::none, typename T>
aie::vector< T, N > | readincr_v (input_stream< T > *w, bool &tlast)
| Reads a vector from the input AXI stream and returns whether TLAST has been asserted.
template<typename T>
| aie::tlast (const T &, bool) -> tlast< const T &, bool >
template<typename T>
| aie::tlast (T &, bool &) -> tlast< T &, bool & >
template<aie::AccumElemBaseType T, unsigned N>
void | writeincr (output_cascade< T > *w, const aie::accum< T, N > &value)
| Writes an accumulator into the output cascade stream.
template<aie::ElemBaseType T, unsigned N>
void | writeincr (output_cascade< T > *w, const aie::vector< T, N > &value)
| Writes a vector into the output cascade stream.
template<aie::AccumElemBaseType T, unsigned N>
void | writeincr (output_stream< T > *w, const aie::accum< T, N > &value)
| Writes an accumulator into the output cascade stream.
template<aie_stream_resource_out Resource = aie_stream_resource_out::none, typename T, unsigned N>
void | writeincr (output_stream< T > *w, const aie::vector< T, N > &value)
| Writes a vector into the output AXI stream.
template<aie_stream_resource_out Resource = aie_stream_resource_out::none, typename T, unsigned N>
void | writeincr (output_stream< T > *w, const aie::vector< T, N > &value, bool tlast)
| Writes a vector into the output AXI stream.
template<aie::AccumElemBaseType T, unsigned N>
void | writeincr_v (output_stream< T > *w, const aie::accum< T, N > &value)
template<unsigned N, typename T>
void | writeincr_v (output_stream< T > *w, const aie::vector< T, N > &value)
template<unsigned N, typename T>
void | writeincr_v (output_stream< T > *w, const aie::vector< T, N > &value, bool tlast)

## Macro Definition Documentation

## ◆ __AIE_API_AIE_ADF_STREAM_HPP__

#define __AIE_API_AIE_ADF_STREAM_HPP__

## Function Documentation

## ◆ operator<<()

template<unsigned Lanes, unsigned Points, int CoeffStep, int DataStepX, int DataStepY, aie::ElemBaseType CoeffType, aie::ElemBaseType DataType, aie::AccumElemBaseType AccumTag>

output_cascade< AccumTag, void > & operator<< | ( | output_cascade< AccumTag, void > & | cascade,
|  | const aie::partial_sliding_mul< Lanes, Points, CoeffStep, DataStepX, DataStepY, CoeffType, DataType, AccumTag > & | value )
| inline

Writes a partial_sliding_mul value to a cascade output port.

The value's internal sum must have a valid initialised accumulator, that is, it must not be a default initialised value.

## ◆ operator>>()

template<unsigned Lanes, unsigned Points, int CoeffStep, int DataStepX, int DataStepY, aie::ElemBaseType CoeffType, aie::ElemBaseType DataType, aie::AccumElemBaseType AccumTag>

input_cascade< AccumTag, void > & operator>> | ( | input_cascade< AccumTag, void > & | cascade,
|  | aie::partial_sliding_mul< Lanes, Points, CoeffStep, DataStepX, DataStepY, CoeffType, DataType, AccumTag > & | value )
| inline

Reads a partial_sliding_mul value from a cascade port.

## ◆ readincr_v()

template<unsigned N, aie::AccumElemBaseType T>

aie::accum< T, N > readincr_v | ( | input_cascade< T > * | w | ) |

Reads an accumulator from the input cascade stream.

Parameters

  w | Input cascade stream

## ◆ writeincr_v() [1/3]

template<aie::AccumElemBaseType T, unsigned N>

void writeincr_v | ( | output_stream< T > * | w,
|  | const aie::accum< T, N > & | value )

## ◆ writeincr_v() [2/3]

template<unsigned N, typename T>

void writeincr_v | ( | output_stream< T > * | w,
|  | const aie::vector< T, N > & | value )

## ◆ writeincr_v() [3/3]

template<unsigned N, typename T>

void writeincr_v | ( | output_stream< T > * | w,
|  | const aie::vector< T, N > & | value,
|  | bool | tlast )