Please enter what you're looking for to continue your search
 

_mm512_min_epu8
ADD TO COMPARE ADDED TO COMPARE

 Location: Math Functions  >  Vector Minimum
 CPU Extensions: AVX512BW
Purpose:
Compare packed unsigned 8-bit integers in "a" and "b", and store packed minimum values in "dst".
Result:

__m512i

Example:
#include <immintrin.h>
#include <stdio.h>
int main() {
 __m512i a = _mm512_set_epi8(255, 200, 150, 100, 50, 0, 25, 10,                                30, 60, 90, 120, 150, 180, 210, 240,                                100, 120, 140, 160, 180, 200, 220, 240,                                20, 40, 60, 80, 100, 120, 140, 160,                                180, 200, 220, 240, 250, 255, 100, 90,                                80, 70, 60, 50, 40, 30, 20, 10,                                255, 200, 150, 100, 50, 0, 25, 10,                                255, 200, 150, 100, 50, 0, 25, 10);
 __m512i b = _mm512_set_epi8(100, 120, 140, 160, 180, 200, 220, 240,                                250, 240, 230, 220, 210, 200, 190, 180,                                120, 100, 80, 60, 40, 20, 10, 0,                                255, 240, 220, 200, 180, 160, 140, 120,                                100, 80, 60, 40, 20, 0, 255, 250,                                230, 210, 190, 170, 150, 130, 110, 90,                                70, 50, 30, 10, 5, 0, 50, 100,                                70, 50, 30, 10, 5, 0, 50, 100);
 __m512i r = _mm512_min_epu8(a, b);
 unsigned char* p = (unsigned char*)&r;
 for (int i = 0; i < 64; i++) {
   printf("%u ", p[i]);
  }

  return 0;
 }

Prototypes

Assembly Instruction:
vpminub
Usage:
__m512i result = _mm512_min_epu8( __m512i a, __m512i 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