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

vec_splat_s16
ADD TO COMPARE ADDED TO COMPARE

 IBM Power 9 64-bit (64 bits)/ VSX  View official documentation
Purpose:

Returns a vector with all elements equal to the given value.

Result:

Each element of output is given the sign-extended 5-bit value of a. The range of this value is [-16:15].

Prototypes

Assembly Instruction:
vspltish
Usage:
vector signed short result = vec_splat_s16( 5_bit_literal a )
Performance Metrics:
📊 Unlock Performance Insights

Get access to detailed performance metrics including latency, throughput, and CPU-specific benchmarks for this intrinsic.

Example:
#include <altivec.h>
#include <stdio.h>
int main() {
 vector signed short r = vec_splat_s16(7);
 for (int i = 0; i < 8; i++) {
   printf("%d ", r[i]);
  }

  return 0;
 }
SIMD Intrinsics Summary
SIMD Engines: 6
C Intrinsics: 10444
NEON: 4353
AVX2: 405
AVX512: 4717
SSE4.2: 598
VSX: 192
IBM-Z: 179