AI Engine  (AIE) r2p15.2
 All Data Structures Functions Variables Groups Pages

Overview

Advanced Float Vector Arithmetic Operations. The lane selection scheme is explained after each intrinsic. Note that these intrinsics are a wrapper over the fully configurable fpmac_conf base function, explained here. More information on fpmac_conf can be found here.

Functions

v8float fpabs (v32float xbuf, int xstart, unsigned int xoffs)
 Select elements and take absolute value of elements from a real single precision floating point vector.
 
v8float fpabs (v16float xbuf, int xstart, unsigned int xoffs)
 Select elements and take absolute value of elements from a real single precision floating point vector.
 

Addition functions

v8float fpadd (v8float acc, v32float xbuf, int xstart, unsigned int xoffs)
 Add single precision real floating point vectors.
 
v8float fpadd (v8float acc, v16float xbuf, int xstart, unsigned int xoffs)
 Add single precision real floating point vectors.
 
v4cfloat fpadd (v4cfloat acc, v16cfloat xbuf, int xstart, unsigned int xoffs)
 Add complex single precision floating point vectors.
 
v4cfloat fpadd (v4cfloat acc, v8cfloat xbuf, int xstart, unsigned int xoffs)
 Add complex single precision floating point vectors.
 
v8float fpadd_abs (v8float acc, v32float xbuf, int xstart, unsigned int xoffs)
 Take absolute value and add real single precision floating point vectors.
 
v8float fpadd_abs (v8float acc, v16float xbuf, int xstart, unsigned int xoffs)
 Take absolute value and add real single precision floating point vectors.
 

Subtraction functions

v8float fpsub (v8float acc, v32float xbuf, int xstart, unsigned int xoffs)
 Subtract real single precision floating point vectors.
 
v8float fpsub (v8float acc, v16float xbuf, int xstart, unsigned int xoffs)
 Subtract real single precision floating point vectors.
 
v4cfloat fpsub (v4cfloat acc, v16cfloat xbuf, int xstart, unsigned int xoffs)
 Subtract complex single precision floating point vectors.
 
v4cfloat fpsub (v4cfloat acc, v8cfloat xbuf, int xstart, unsigned int xoffs)
 Subtract complex single precision floating point vectors.
 
v8float fpsub_abs (v8float acc, v32float xbuf, int xstart, unsigned int xoffs)
 Take absolute value and subtract real single precision floating point vectors.
 
v8float fpsub_abs (v8float acc, v16float xbuf, int xstart, unsigned int xoffs)
 Take absolute value and subtract real single precision floating point vectors.
 

Negation intrinsics

v8float fpneg (v32float xbuf, int xstart, unsigned int xoffs)
 Negate a real single precision floating point vector.
 
v8float fpneg (v16float xbuf, int xstart, unsigned int xoffs)
 Negate a real single precision floating point vector.
 
v4cfloat fpneg (v16cfloat xbuf, int xstart, unsigned int xoffs)
 Negate a complex single precision floating point vector.
 
v4cfloat fpneg (v8cfloat xbuf, int xstart, unsigned int xoffs)
 Negate a complex single precision floating point vector.
 
v8float fpneg_abs (v32float xbuf, int xstart, unsigned int xoffs)
 Take absolute value and negate a real single precision floating point vector.
 
v8float fpneg_abs (v16float xbuf, int xstart, unsigned int xoffs)
 Take absolute value and negate a real single precision floating point vector.
 

Function Documentation

v8float fpabs ( v32float  xbuf,
int  xstart,
unsigned int  xoffs 
)

Select elements and take absolute value of elements from a real single precision floating point vector.

for (i = 0 ; i < 8 ; i++)
ret[i] = abs(xbuf[xstart + xoffs[i]])
Returns
Vector with the absolute values.
Parameters
xbufInput buffer.
xstartStarting offset for all lanes of X.
xoffs4 bits per lane: Additional lane-dependent offset for X.
v8float fpabs ( v16float  xbuf,
int  xstart,
unsigned int  xoffs 
)

Select elements and take absolute value of elements from a real single precision floating point vector.

for (i = 0 ; i < 8 ; i++)
ret[i] = abs(xbuf[xstart + xoffs[i]])
Returns
Vector with the absolute values.
Parameters
xbufInput buffer. Small buffer variant.
xstartStarting offset for all lanes of X.
xoffs4 bits per lane: Additional lane-dependent offset for X.
v8float fpadd ( v8float  acc,
v32float  xbuf,
int  xstart,
unsigned int  xoffs 
)

Add single precision real floating point vectors.

for (i = 0 ; i < 8 ; i++)
ret[i] = acc[i] + xbuf[xstart + xoffs[i]]
Returns
Vector with the addition result.
Parameters
accIncoming accumulation vector.
xbufBig input buffer.
xstartStarting offset for all lanes of X.
xoffs4 bits per lane: Additional lane-dependent offset for X.
v8float fpadd ( v8float  acc,
v16float  xbuf,
int  xstart,
unsigned int  xoffs 
)

Add single precision real floating point vectors.

for (i = 0 ; i < 8 ; i++)
ret[i] = acc[i] + xbuf[xstart + xoffs[i]]
Returns
Vector with the addition result.
Parameters
accIncoming accumulation vector.
xbufInput buffer. Small buffer variant.
xstartStarting offset for all lanes of X.
xoffs4 bits per lane: Additional lane-dependent offset for X.
v4cfloat fpadd ( v4cfloat  acc,
v16cfloat  xbuf,
int  xstart,
unsigned int  xoffs 
)

Add complex single precision floating point vectors.

for (i = 0 ; i < 4 ; i++)
ret[i].re = acc[i].re + xbuf[xstart + xoffs[i]].re
ret[i].re = acc[i].im + xbuf[xstart + xoffs[i]].im
Returns
Vector with the addition result.
Parameters
accIncoming accumulation vector.
xbufInput buffer.
xstartStarting offset for all lanes of X. The offsets are referring to complex lanes (lane 0 corresponds to the first real and complex values).
xoffs4 bits per lane: Additional lane-dependent offset for X. The offsets are referring to complex lanes. For optimized code should be compile time constant.
v4cfloat fpadd ( v4cfloat  acc,
v8cfloat  xbuf,
int  xstart,
unsigned int  xoffs 
)

Add complex single precision floating point vectors.

for (i = 0 ; i < 4 ; i++)
ret[i].re = acc[i].re + xbuf[xstart + xoffs[i]].re
ret[i].re = acc[i].im + xbuf[xstart + xoffs[i]].im
Returns
Vector with the addition result.
Parameters
accIncoming accumulation vector.
xbufInput buffer. Small buffer variant.
xstartStarting offset for all lanes of X. The offsets are referring to complex lanes (lane 0 corresponds to the first real and complex values).
xoffs4 bits per lane: Additional lane-dependent offset for X. The offsets are referring to complex lanes. For optimized code should be compile time constant.
v8float fpadd_abs ( v8float  acc,
v32float  xbuf,
int  xstart,
unsigned int  xoffs 
)

Take absolute value and add real single precision floating point vectors.

for (i = 0 ; i < 8 ; i++)
ret[i] = acc[i] + abs(xbuf[xstart + xoffs[i]])
Returns
Vector with the addition result.
Parameters
accIncoming accumulation vector.
xbufInput buffer.
xstartStarting offset for all lanes of X.
xoffs4 bits per lane: Additional lane-dependent offset for X.
v8float fpadd_abs ( v8float  acc,
v16float  xbuf,
int  xstart,
unsigned int  xoffs 
)

Take absolute value and add real single precision floating point vectors.

for (i = 0 ; i < 8 ; i++)
ret[i] = acc[i] + abs(xbuf[xstart + xoffs[i]])
Returns
Vector with the addition result.
Parameters
accIncoming accumulation vector.
xbufInput buffer. Small buffer variant.
xstartStarting offset for all lanes of X.
xoffs4 bits per lane: Additional lane-dependent offset for X.
v8float fpneg ( v32float  xbuf,
int  xstart,
unsigned int  xoffs 
)

Negate a real single precision floating point vector.

for (i = 0 ; i < 8 ; i++)
ret[i] = - xbuf[xstart + xoffs[i]]
Returns
Vector with the negated result.
Parameters
xbufInput buffer.
xstartStarting offset for all lanes of X.
xoffs4 bits per lane: Additional lane-dependent offset for X.
v8float fpneg ( v16float  xbuf,
int  xstart,
unsigned int  xoffs 
)

Negate a real single precision floating point vector.

for (i = 0 ; i < 8 ; i++)
ret[i] = - xbuf[xstart + xoffs[i]]
Returns
Vector with the negated result.
Parameters
xbufInput buffer. Small buffer variant.
xstartStarting offset for all lanes of X.
xoffs4 bits per lane: Additional lane-dependent offset for X.
v4cfloat fpneg ( v16cfloat  xbuf,
int  xstart,
unsigned int  xoffs 
)

Negate a complex single precision floating point vector.

for (i = 0 ; i < 4 ; i++)
ret[i].re = - xbuf[xstart + xoffs[i]].re
ret[i].im = - xbuf[xstart + xoffs[i]].im
Returns
Vector with the subtraction result.
Parameters
xbufInput buffer.
xstartStarting offset for all lanes of X. The offsets are referring to complex lanes (lane 0 corresponds to the first real and complex values).
xoffs4 bits per lane: Additional lane-dependent offset for X. The offsets are referring to complex lanes. For optimized code should be compile time constant.
v4cfloat fpneg ( v8cfloat  xbuf,
int  xstart,
unsigned int  xoffs 
)

Negate a complex single precision floating point vector.

for (i = 0 ; i < 4 ; i++)
ret[i].re = - xbuf[xstart + xoffs[i]].re
ret[i].im = - xbuf[xstart + xoffs[i]].im
Returns
Vector with the subtraction result.
Parameters
xbufInput buffer. Small buffer variant.
xstartStarting offset for all lanes of X. The offsets are referring to complex lanes (lane 0 corresponds to the first real and complex values).
xoffs4 bits per lane: Additional lane-dependent offset for X. The offsets are referring to complex lanes. For optimized code should be compile time constant.
v8float fpneg_abs ( v32float  xbuf,
int  xstart,
unsigned int  xoffs 
)

Take absolute value and negate a real single precision floating point vector.

for (i = 0 ; i < 8 ; i++)
ret[i] = - abs(xbuf[xstart + xoffs[i]])
Returns
Vector with the negated absolute values.
Parameters
xbufInput buffer.
xstartStarting offset for all lanes of X.
xoffs4 bits per lane: Additional lane-dependent offset for X.
v8float fpneg_abs ( v16float  xbuf,
int  xstart,
unsigned int  xoffs 
)

Take absolute value and negate a real single precision floating point vector.

for (i = 0 ; i < 8 ; i++)
ret[i] = - abs(xbuf[xstart + xoffs[i]])
Returns
Vector with the negated absolute values.
Parameters
xbufInput buffer. Small buffer variant.
xstartStarting offset for all lanes of X.
xoffs4 bits per lane: Additional lane-dependent offset for X.
v8float fpsub ( v8float  acc,
v32float  xbuf,
int  xstart,
unsigned int  xoffs 
)

Subtract real single precision floating point vectors.

for (i = 0 ; i < 8 ; i++)
ret[i] = acc[i] - xbuf[xstart + xoffs[i]]
Returns
Vector with the subtraction result.
Parameters
accIncoming accumulation vector.
xbufInput buffer.
xstartStarting offset for all lanes of X.
xoffs4 bits per lane: Additional lane-dependent offset for X.
v8float fpsub ( v8float  acc,
v16float  xbuf,
int  xstart,
unsigned int  xoffs 
)

Subtract real single precision floating point vectors.

for (i = 0 ; i < 8 ; i++)
ret[i] = acc[i] - xbuf[xstart + xoffs[i]]
Returns
Vector with the subtraction result.
Parameters
accIncoming accumulation vector.
xbufInput buffer. Small buffer variant.
xstartStarting offset for all lanes of X.
xoffs4 bits per lane: Additional lane-dependent offset for X.
v4cfloat fpsub ( v4cfloat  acc,
v16cfloat  xbuf,
int  xstart,
unsigned int  xoffs 
)

Subtract complex single precision floating point vectors.

for (i = 0 ; i < 4 ; i++)
ret[i].re = acc[i].re - xbuf[xstart + xoffs[i]].re
ret[i].re = acc[i].im - xbuf[xstart + xoffs[i]].im
Returns
Vector with the subtraction result.
Parameters
accIncoming accumulation vector.
xbufInput buffer.
xstartStarting offset for all lanes of X. The offsets are referring to complex lanes (lane 0 corresponds to the first real and complex values).
xoffs4 bits per lane: Additional lane-dependent offset for X. The offsets are referring to complex lanes. For optimized code should be compile time constant.
v4cfloat fpsub ( v4cfloat  acc,
v8cfloat  xbuf,
int  xstart,
unsigned int  xoffs 
)

Subtract complex single precision floating point vectors.

for (i = 0 ; i < 4 ; i++)
ret[i].re = acc[i].re - xbuf[xstart + xoffs[i]].re
ret[i].re = acc[i].im - xbuf[xstart + xoffs[i]].im
Returns
Vector with the subtraction result.
Parameters
accIncoming accumulation vector.
xbufInput buffer. Small buffer variant.
xstartStarting offset for all lanes of X. The offsets are referring to complex lanes (lane 0 corresponds to the first real and complex values).
xoffs4 bits per lane: Additional lane-dependent offset for X. The offsets are referring to complex lanes. For optimized code should be compile time constant.
v8float fpsub_abs ( v8float  acc,
v32float  xbuf,
int  xstart,
unsigned int  xoffs 
)

Take absolute value and subtract real single precision floating point vectors.

for (i = 0 ; i < 8 ; i++)
ret[i] = acc[i] - abs(xbuf[xstart + xoffs[i]])
Returns
Vector with the abs-subtraction result.
Parameters
accIncoming accumulation vector.
xbufInput buffer.
xstartStarting offset for all lanes of X.
xoffs4 bits per lane: Additional lane-dependent offset for X.
v8float fpsub_abs ( v8float  acc,
v16float  xbuf,
int  xstart,
unsigned int  xoffs 
)

Take absolute value and subtract real single precision floating point vectors.

for (i = 0 ; i < 8 ; i++)
ret[i] = acc[i] - abs(xbuf[xstart + xoffs[i]])
Returns
Vector with the abs-subtraction result.
Parameters
accIncoming accumulation vector.
xbufInput buffer. Small buffer variant.
xstartStarting offset for all lanes of X.
xoffs4 bits per lane: Additional lane-dependent offset for X.