_mm256_min_phADD TO COMPARE ADDED TO COMPARE
Intel 64-bit (64 bits)/ AVX512
View official documentation
View Félix Cloutier's documentation
Purpose:
Compare packed half-precision (16-bit) floating-point elements in "a" and "b", and store packed minimum values in "dst". [min_float_note]
Result:
__m256h
Example:
#include <immintrin.h>
#include <stdio.h>
int main() {
__m256h a = _mm256_set_ph((_Float16)1.0, (_Float16)5.5, (_Float16)3.0, (_Float16)7.0, (_Float16)2.0, (_Float16)4.0, (_Float16)6.0, (_Float16)0.5, (_Float16)2.5, (_Float16)3.5, (_Float16)4.5, (_Float16)5.0, (_Float16)6.5, (_Float16)7.5, (_Float16)8.0, (_Float16)9.0);
__m256h b = _mm256_set_ph((_Float16)2.0, (_Float16)4.5, (_Float16)4.0, (_Float16)6.5, (_Float16)3.0, (_Float16)3.5, (_Float16)5.0, (_Float16)1.0, (_Float16)1.5, (_Float16)2.5, (_Float16)3.0, (_Float16)4.0, (_Float16)5.5, (_Float16)6.5, (_Float16)7.0, (_Float16)8.0);
__m256h r = _mm256_min_ph(a, b);
_Float16* p = (_Float16*)&r;
for (int i = 0; i < 16; i++) {
printf("%g ", (float)p[i]);
}
return 0;
}
Prototypes
Assembly Instruction:
VMINPH
Usage:
__m256h result =
_mm256_min_ph(
__m256h a, __m256h b
)
Performance Metrics:
📊 Unlock Performance Insights
Get access to detailed performance metrics including latency, throughput, and CPU-specific benchmarks for this intrinsic.
SIMD Intrinsics Summary
| SIMD Engines: | 6 |
| C Intrinsics: | 10444 |
| NEON: | 4353 |
| AVX2: | 405 |
| AVX512: | 4717 |
| SSE4.2: | 598 |
| VSX: | 192 |
| IBM-Z: | 179 |