_mm_sqrt_psADD TO COMPARE ADDED TO COMPARE
Intel 64-bit (64 bits)/ SSE4.2
View official documentation
Location:
Math Functions
>
Vector Square Root
Purpose:
Compute the square root of packed single-precision (32-bit) floating-point elements in a, and store the results in output.
Result:
__m128
Example:
#include <xmmintrin.h>
#include <stdio.h>
int main() {
__m128 a = _mm_set_ps(16.0f, 9.0f, 4.0f, 1.0f);
__m128 result = _mm_sqrt_ps(a);
float res[4];
_mm_storeu_ps(res, result);
printf("%f %f %f %f\n", res[0], res[1], res[2], res[3]);
return 0;
}
Prototypes
Assembly Instruction:
rsqrtps
Usage:
__m128 output =
_mm_sqrt_ps(
__m128 a
)
DB statistics
SIMD Engines: | 5 |
C Intrinsics: | 10702 |
NEON: | 4232 |
AVX2: | 462 |
AVX512: | 4955 |
SSE4.2: | 652 |
VSX: | 401 |