MCPcopy Create free account
hub / github.com/numpy/numpy / npyv_load_till_s64

Function npyv_load_till_s64

numpy/core/src/common/simd/sse/memory.h:251–266  ·  view source on GitHub ↗

/ 64

Source from the content-addressed store, hash-verified

249}
250//// 64
251NPY_FINLINE npyv_s64 npyv_load_till_s64(const npy_int64 *ptr, npy_uintp nlane, npy_int64 fill)
252{
253 assert(nlane > 0);
254 if (nlane == 1) {
255 const __m128i vfill = npyv_setall_s64(fill);
256 npyv_s64 a = _mm_castpd_si128(
257 _mm_loadl_pd(_mm_castsi128_pd(vfill), (double*)ptr)
258 );
259 #if NPY_SIMD_GUARD_PARTIAL_LOAD
260 volatile __m128i workaround = a;
261 a = _mm_or_si128(workaround, a);
262 #endif
263 return a;
264 }
265 return npyv_load_s64(ptr);
266}
267// fill zero to rest lanes
268NPY_FINLINE npyv_s64 npyv_load_tillz_s64(const npy_int64 *ptr, npy_uintp nlane)
269{

Callers 1

npyv_loadn_till_s64Function · 0.70

Calls 1

npyv_setall_s64Function · 0.70

Tested by

no test coverage detected