vrintn
Vector Round Floating-Point (Nearest Even)
VRINTN<c>.F32 <Qd>, <Qm>
Rounds float to integral float (Nearest Even).
Pseudocode Operation
for i = 0 to 3
Qd[i] ← RoundToNearestEven(Qm[i])
end for
Example
VRINTN.F32 q0, q2
Encoding
Binary Layout
111111101
31:23
D
22
111
21:19
0
18
01
17:16
Vd
15:12
10
11:10
10
9:8
0
7
1
6
M
5
0
4
Vm
3:0
Operands
-
Qd
Destination 128-bit SIMD register -
Qm
Second source 128-bit SIMD register
Related
More in NEON (SIMD)
Reference
View in Arm A64 ISA Reference ↗
Arm AArch32 ISA
Instruction Forms
| Encoding | Instruction | ISA | Bit pattern | ||
|---|---|---|---|---|---|
| 0xF3B20400 | VRINTN{<q>}.<dt> <Dd>, <Dm> | A32 | 111100111 | D | 11 | size | 10 | Vd | 0 | 1 | 000 | 0 | M | 0 | Vm | ||
| 0xF3B20440 | VRINTN{<q>}.<dt> <Qd>, <Qm> | A32 | 111100111 | D | 11 | size | 10 | Vd | 0 | 1 | 000 | 1 | M | 0 | Vm | ||
| 0xFFB20400 | VRINTN{<q>}.<dt> <Dd>, <Dm> | T32 | 111111111 | D | 11 | size | 10 | Vd | 0 | 1 | 000 | 0 | M | 0 | Vm | ||
| 0xFFB20440 | VRINTN{<q>}.<dt> <Qd>, <Qm> | T32 | 111111111 | D | 11 | size | 10 | Vd | 0 | 1 | 000 | 1 | M | 0 | Vm | ||
| 0xFEB90940 | VRINTN{<q>}.F16 <Sd>, <Sm> | A32 | 111111101 | D | 111 | 0 | 01 | Vd | 10 | 01 | 0 | 1 | M | 0 | Vm | ||
| 0xFEB90A40 | VRINTN{<q>}.F32 <Sd>, <Sm> | A32 | 111111101 | D | 111 | 0 | 01 | Vd | 10 | 10 | 0 | 1 | M | 0 | Vm | ||
| 0xFEB90B40 | VRINTN{<q>}.F64 <Dd>, <Dm> | A32 | 111111101 | D | 111 | 0 | 01 | Vd | 10 | 11 | 0 | 1 | M | 0 | Vm |
Description
Round floating-point to integer to Nearest rounds a floating-point value to an integral floating-point value of the same size using the Round to Nearest rounding mode. A zero input gives a zero result with the same sign, an infinite input gives an infinite result with the same sign, and a NaN is propagated as for normal arithmetic.
Operation
EncodingSpecificOperations(); CheckVFPEnabled(TRUE);
case esize of
when 16
S[d] = Zeros(16) : FPRoundInt(S[m]<15:0>, FPSCR[], rounding, exact);
when 32
S[d] = FPRoundInt(S[m], FPSCR[], rounding, exact);
when 64
D[d] = FPRoundInt(D[m], FPSCR[], rounding, exact);