__lasx_xvfrintrne_s
LASX intrinsic · group: Floating Point Misc
Synopsis
__m256 __lasx_xvfrintrne_s (__m256 a)
#include <lasxintrin.h>
Instruction: xvfrintrne.s xr, xr
CPU Flags: LASX
Description
Round single-precision floating point elements in a to integers, rounding towards nearest even, and store as floating point numbers.
Operation
for (int i = 0; i < 8; i++) {
dst.fp32[i] = (f32)(s32)a.fp32[i]; // rounding mode is not expressed in C
}
Latency and Throughput
| CPU | µarch | Latency | Throughput (IPC) |
|---|---|---|---|
| 3C5000 | LA464 | 4 | 2 |
| 3A6000 | LA664 | 4 | 2 |
| 3C6000 | LA664 | 4 | 2 |