| AI Engine Intrinsics User Guide (AIE) v2025.2

Loading...
Searching...
No Matches
Functions
Float
Intrinsics » Vector Operations » Vector Compares » Advanced » Vector Max/Min

## Overview

Float vector max/min.

Performs the comparison between lanes and returns the result of the comparison (either max or min) as a lane in the output vector.

## Functions
v8float | fpmax (v8float acc, v16float xbuf, int xstart, unsigned int xoffs)
| Maximum for single precision real floating point vectors.
v8float | fpmax (v8float acc, v32float xbuf, int xstart, unsigned int xoffs)
| Maximum for single precision real floating point vectors.
v8float | fpmax (v8float acc, v8float xbuf)
| Maximum for single precision real floating point vectors.
v8float | fpmax (v8float acc, v8float xbuf, int xstart, unsigned int xoffs)
| Maximum for single precision real floating point vectors.
v8float | fpmax_abs (v8float acc, v16float xbuf, int xstart, unsigned int xoffs)
| Take absolute value and find maximum for single precision real floating point vectors.
v8float | fpmax_abs (v8float acc, v32float xbuf, int xstart, unsigned int xoffs)
| Take absolute value and find maximum for single precision real floating point vectors.
v8float | fpmax_abs (v8float acc, v8float xbuf)
| Take absolute value and find maximum for single precision real floating point vectors.
v8float | fpmax_abs (v8float acc, v8float xbuf, int xstart, unsigned int xoffs)
| Take absolute value and find maximum for single precision real floating point vectors.
v8float | fpmin (v8float acc, v16float xbuf, int xstart, unsigned int xoffs)
| Minimum for single precision real floating point vectors.
v8float | fpmin (v8float acc, v32float xbuf, int xstart, unsigned int xoffs)
| Minimum for single precision real floating point vectors.
v8float | fpmin (v8float acc, v8float xbuf)
| Minimum for single precision real floating point vectors.
v8float | fpmin (v8float acc, v8float xbuf, int xstart, unsigned int xoffs)
| Minimum for single precision real floating point vectors.
v8float | fpmin_abs (v8float acc, v16float xbuf, int xstart, unsigned int xoffs)
| Take absolute value and find minimum for single precision real floating point vectors.
v8float | fpmin_abs (v8float acc, v32float xbuf, int xstart, unsigned int xoffs)
| Take absolute value and find minimum for single precision real floating point vectors.
v8float | fpmin_abs (v8float acc, v8float xbuf)
| Take absolute value and find minimum for single precision real floating point vectors.
v8float | fpmin_abs (v8float acc, v8float xbuf, int xstart, unsigned int xoffs)
| Take absolute value and find minimum for single precision real floating point vectors.

## Function Documentation

## ◆ fpmax() [1/4]

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

Maximum for single precision real floating point vectors.

for (i = 0; i < 8; i++)
ret[i] = max(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
  Result vector.

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.

## ◆ fpmax() [2/4]

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

Maximum for single precision real floating point vectors.

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

Returns
  Result vector.

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.

## ◆ fpmax() [3/4]

v8float fpmax | ( | v8float | acc,
|  | v8float | xbuf
| ) |  |

Maximum for single precision real floating point vectors.

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

Returns
  Result vector.

Parameters

  acc | Incoming accumulation vector.
  xbuf | Input buffer.

## ◆ fpmax() [4/4]

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

Maximum for single precision real floating point vectors.

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

Returns
  Result vector.

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.

## ◆ fpmax_abs() [1/4]

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

Take absolute value and find maximum for single precision real floating point vectors.

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

Returns
  Result vector.

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.

## ◆ fpmax_abs() [2/4]

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

Take absolute value and find maximum for single precision real floating point vectors.

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

Returns
  Result vector.

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.

## ◆ fpmax_abs() [3/4]

v8float fpmax_abs | ( | v8float | acc,
|  | v8float | xbuf
| ) |  |

Take absolute value and find maximum for single precision real floating point vectors.

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

Returns
  Result vector.

Parameters

  acc | Incoming accumulation vector.
  xbuf | Input buffer.

## ◆ fpmax_abs() [4/4]

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

Take absolute value and find maximum for single precision real floating point vectors.

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

Returns
  Result vector.

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.

## ◆ fpmin() [1/4]

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

Minimum for single precision real floating point vectors.

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

Returns
  Result vector.

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.

## ◆ fpmin() [2/4]

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

Minimum for single precision real floating point vectors.

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

Returns
  Result vector.

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.

## ◆ fpmin() [3/4]

v8float fpmin | ( | v8float | acc,
|  | v8float | xbuf
| ) |  |

Minimum for single precision real floating point vectors.

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

Returns
  Result vector.

Parameters

  acc | Incoming accumulation vector.
  xbuf | Input buffer.

## ◆ fpmin() [4/4]

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

Minimum for single precision real floating point vectors.

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

Returns
  Result vector.

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.

## ◆ fpmin_abs() [1/4]

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

Take absolute value and find minimum for single precision real floating point vectors.

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

Returns
  Result vector.

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.

## ◆ fpmin_abs() [2/4]

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

Take absolute value and find minimum for single precision real floating point vectors.

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

Returns
  Result vector.

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.

## ◆ fpmin_abs() [3/4]

v8float fpmin_abs | ( | v8float | acc,
|  | v8float | xbuf
| ) |  |

Take absolute value and find minimum for single precision real floating point vectors.

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

Returns
  Result vector.

Parameters

  acc | Incoming accumulation vector.
  xbuf | Input buffer.

## ◆ fpmin_abs() [4/4]

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

Take absolute value and find minimum for single precision real floating point vectors.

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

Returns
  Result vector.

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.