vlogefp
Vector Log Base 2 Estimate Floating-Point
vlogefp VRT,VRB
Estimates the base 2 logarithm of single-precision floating-point elements in a vector register.
Encoding
Binary Layout
0
0:5
VRT
6:10
VRB
11:30
11000000000000000000000000000000
31
Operands
-
VRT
Target Vector Register -
VRB
Source Vector Register
Reference
View in PowerISA v3.1C Specification ↗
OPF Power ISA v3.1C
Description
For vlogefp, the single-precision floating-point estimate of the base 2 logarithm of each element in VSR[VRB+32] is placed into the corresponding element in VSR[VRT+32].
Operation
if MSR.VEC=0 then
Vector_Unavailable()
do i = 0 to 3
src ← VSR[VRB+32].word[i]
VSR[VRT+32].word[i] ← bfp32_LOG_BASE2_ESTIMATE(src)
end
Programming Note
This instruction is used for estimating the base 2 logarithm of single-precision floating-point numbers in vector registers. Ensure that the Vector Facility (MSR.VEC) is enabled before using this instruction; otherwise, a Vector_Unavailable exception will be raised. The operation processes four elements at a time, so ensure proper alignment and data handling to avoid unexpected results.