| AI Engine Intrinsics User Guide (v2026.1)

Loading...
Searching...
No Matches
Functions | Variables
Float
Intrinsics » Vector Operations » Vector Compares » Advanced » Vector comparison

## Overview

Float vector comparison.

Performs the comparison between lanes and return the result of the comparison as a bit in the return word.

## Functions
unsigned int | fpge (v8float acc, v16float xbuf, int xstart, unsigned int xoffs)
| Greater-equal comparison for single precision real floating point vectors.
unsigned int | fpge (v8float acc, v32float xbuf, int xstart, unsigned int xoffs)
| Greater-equal comparison for single precision real floating point vectors.
unsigned int | fpge (v8float acc, v8float xbuf, int xstart, unsigned int xoffs)
| Greater-equal comparison for single precision real floating point vectors.
unsigned int | fpge_abs (v8float acc, v32float xbuf, int xstart, unsigned int xoffs)
| Take absolute value and perform greater-equal comparison for single precision real floating point vectors.
unsigned int | fpge_abs (v8float acc, v8float xbuf)
| Take absolute value and perform greater-equal comparison for single precision real floating point vectors.
unsigned int | fpge_abs (v8float acc, v8float xbuf, int xstart, unsigned int xoffs)
| Take absolute value and perform greater-equal comparison for single precision real floating point vectors.
unsigned int | fplt (v8float acc, v16float xbuf, int xstart, unsigned int xoffs)
| Less-than comparision for single precision real floating point vectors.
unsigned int | fplt (v8float acc, v32float xbuf, int xstart, unsigned int xoffs)
| Less-than comparision for single precision real floating point vectors.
unsigned int | fplt (v8float acc, v8float xbuf, int xstart, unsigned int xoffs)
| Less-than comparision for single precision real floating point vectors.
unsigned int | fplt_abs (v8float acc, v32float xbuf, int xstart, unsigned int xoffs)
| Take absolute value and perform less-than comparison for single precision real floating point vectors.
unsigned int | fplt_abs (v8float acc, v8float xbuf)
| Take absolute value and perform less-than comparison for single precision real floating point vectors.
unsigned int | fplt_abs (v8float acc, v8float xbuf, int xstart, unsigned int xoffs)
| Take absolute value and perform less-than comparison for single precision real floating point vectors.

## Variables
return | cmp
v8float | ret
v16float | xbuf
v16float int unsigned int | xoffs
v16float int | xstart

## Function Documentation

## ◆ fpge() [1/3]

unsigned int fpge | ( | v8float | acc,
|  | v16float | xbuf,
|  | int | xstart,
|  | unsigned int | xoffs )

Greater-equal comparison for single precision real floating point vectors.

for (i = 0; i < 8; i++)
ret[i] = acc[i] >= xbuf[xstart + xoffs[i]]
xstart
v16float int xstart
Definition me_vfloat.h:5095
xoffs
v16float int unsigned int xoffs
Definition me_vfloat.h:5097
ret
v8float ret
Definition me_vfloat.h:5099
xbuf
v16float xbuf
Definition me_vfloat.h:5095

Returns
  Scalar integer with one comparison result per bit.

Parameters

  acc | Incoming accumulation vector.
  xbuf | Input buffer.
  xstart | Starting offset for all lanes of X.
  xoffs | 8 x 4 bits: Additional lane-dependent offset for X.

## ◆ fpge() [2/3]

unsigned int fpge | ( | v8float | acc,
|  | v32float | xbuf,
|  | int | xstart,
|  | unsigned int | xoffs )

Greater-equal comparison for single precision real floating point vectors.

for (i = 0; i < 8; i++)
ret[i] = acc[i] >= xbuf[xstart + xoffs[i]]

Returns
  Scalar integer with one comparison result per bit.

Parameters

  acc | Incoming accumulation vector.
  xbuf | Input buffer.
  xstart | Starting offset for all lanes of X.
  xoffs | 8 x 4 bits: Additional lane-dependent offset for X.

## ◆ fpge() [3/3]

unsigned int fpge | ( | v8float | acc,
|  | v8float | xbuf,
|  | int | xstart,
|  | unsigned int | xoffs )

Greater-equal comparison for single precision real floating point vectors.

for (i = 0; i < 8; i++)
ret[i] = acc[i] >= xbuf[xstart + xoffs[i]]

Returns
  Scalar integer with one comparison result per bit.

Parameters

  acc | Incoming accumulation vector.
  xbuf | Input buffer.
  xstart | Starting offset for all lanes of X.
  xoffs | 8 x 4 bits: Additional lane-dependent offset for X.

## ◆ fpge_abs() [1/3]

unsigned int fpge_abs | ( | v8float | acc,
|  | v32float | xbuf,
|  | int | xstart,
|  | unsigned int | xoffs )

Take absolute value and perform greater-equal comparison for single precision real floating point vectors.

for (i = 0; i < 8; i++)
ret[i] = acc[i] >= abs(xbuf[xstart + xoffs[i]]

Returns
  Scalar integer with one comparison result per bit.

Parameters

  acc | Incoming accumulation vector.
  xbuf | Input buffer.
  xstart | Starting offset for all lanes of X.
  xoffs | 8 x 4 bits: Additional lane-dependent offset for X.

## ◆ fpge_abs() [2/3]

unsigned int fpge_abs | ( | v8float | acc,
|  | v8float | xbuf )

Take absolute value and perform greater-equal comparison for single precision real floating point vectors.

for (i = 0 ; i < 8 ; i++)
ret[i] = acc[i] >= abs(xbuf[i]

Returns
  Scalar integer with one comparison result per bit.

Parameters

  acc | Incoming accumulation vector.
  xbuf | Input buffer.

## ◆ fpge_abs() [3/3]

unsigned int fpge_abs | ( | v8float | acc,
|  | v8float | xbuf,
|  | int | xstart,
|  | unsigned int | xoffs )

Take absolute value and perform greater-equal comparison for single precision real floating point vectors.

for (i = 0; i < 8; i++)
ret[i] = acc[i] >= abs(xbuf[xstart + xoffs[i]]

Returns
  Scalar integer with one comparison result per bit.

Parameters

  acc | Incoming accumulation vector.
  xbuf | Input buffer.
  xstart | Starting offset for all lanes of X.
  xoffs | 8 x 4 bits: Additional lane-dependent offset for X.

## ◆ fplt() [1/3]

unsigned int fplt | ( | v8float | acc,
|  | v16float | xbuf,
|  | int | xstart,
|  | unsigned int | xoffs )

Less-than comparision for single precision real floating point vectors.

for (i = 0; i < 8; i++)
ret[i] = acc[i] < xbuf[xstart + xoffs[i]]

Returns
  Scalar integer with one comparison result per bit.

Parameters

  acc | Incoming accumulation vector.
  xbuf | Input buffer.
  xstart | Starting offset for all lanes of X.
  xoffs | 8 x 4 bits: Additional lane-dependent offset for X.

## ◆ fplt() [2/3]

unsigned int fplt | ( | v8float | acc,
|  | v32float | xbuf,
|  | int | xstart,
|  | unsigned int | xoffs )

Less-than comparision for single precision real floating point vectors.

for (i = 0; i < 8; i++)
ret[i] = acc[i] < xbuf[xstart + xoffs[i]]

Returns
  Scalar integer with one comparison result per bit.

Parameters

  acc | Incoming accumulation vector.
  xbuf | Input buffer.
  xstart | Starting offset for all lanes of X.
  xoffs | 8 x 4 bits: Additional lane-dependent offset for X.

## ◆ fplt() [3/3]

unsigned int fplt | ( | v8float | acc,
|  | v8float | xbuf,
|  | int | xstart,
|  | unsigned int | xoffs )

Less-than comparision for single precision real floating point vectors.

for (i = 0; i < 8; i++)
ret[i] = acc[i] < xbuf[xstart + xoffs[i]]

Returns
  Scalar integer with one comparison result per bit.

Parameters

  acc | Incoming accumulation vector.
  xbuf | Input buffer.
  xstart | Starting offset for all lanes of X.
  xoffs | 8 x 4 bits: Additional lane-dependent offset for X.

## ◆ fplt_abs() [1/3]

unsigned int fplt_abs | ( | v8float | acc,
|  | v32float | xbuf,
|  | int | xstart,
|  | unsigned int | xoffs )

Take absolute value and perform less-than comparison for single precision real floating point vectors.

for (i = 0; i < 8; i++)
ret[i] = acc[i] < abs(xbuf[xstart + xoffs[i]]

Returns
  Scalar integer with one comparison result per bit.

Parameters

  acc | Incoming accumulation vector.
  xbuf | Input buffer.
  xstart | Starting offset for all lanes of X.
  xoffs | 8 x 4 bits: Additional lane-dependent offset for X.

## ◆ fplt_abs() [2/3]

unsigned int fplt_abs | ( | v8float | acc,
|  | v8float | xbuf )

Take absolute value and perform less-than comparison for single precision real floating point vectors.

for (i = 0 ; i < 8 ; i++)
ret[i] = acc[i] < abs(xbuf[i]

Returns
  Scalar integer with one comparison result per bit.

Parameters

  acc | Incoming accumulation vector.
  xbuf | Input buffer.

## ◆ fplt_abs() [3/3]

unsigned int fplt_abs | ( | v8float | acc,
|  | v8float | xbuf,
|  | int | xstart,
|  | unsigned int | xoffs )

Take absolute value and perform less-than comparison for single precision real floating point vectors.

for (i = 0; i < 8; i++)
ret[i] = acc[i] < abs(xbuf[xstart + xoffs[i]]

Returns
  Scalar integer with one comparison result per bit.

Parameters

  acc | Incoming accumulation vector.
  xbuf | Input buffer.
  xstart | Starting offset for all lanes of X.
  xoffs | 8 x 4 bits: Additional lane-dependent offset for X.

## Variable Documentation

## ◆ cmp

return cmp

## ◆ ret

v8float ret

Initial value:
= fpmac_conf(acc,
xbuf,xstart,xoffs,
undef_v8float(),0,0,
true,true,fpadd_sub,0x00,fpcmp_ge
,cmp)
fpmac_conf
v8float fpmac_conf(v8float acc, v8float xbuf, int xstart, unsigned int xoffs, v8float zbuf, int zstart, unsigned int zoffs, bool ones, bool abs, unsigned int addmode, unsigned int addmask, unsigned int cmpmode, unsigned int &cmp)
Fully configurable multiply and accumulate for single precision floating point vectors.
Definition me_vfloat.h:483
cmp
return cmp
Definition me_vfloat.h:5105
undef_v8float
v8float undef_v8float()

## ◆ xbuf

v16float xbuf

## ◆ xoffs

v16float int unsigned int xoffs

Initial value:
{
unsigned int cmp

## ◆ xstart

v16float int xstart