guzba / nimsimd

Pleasant Nim bindings for SIMD instruction sets.
MIT License
73 stars 7 forks source link

little typo in intrinsics import signature #17

Closed Asc2011 closed 7 months ago

Asc2011 commented 7 months ago

Hi guzba thx for the work,

prbl. typo in ./src/nimsimd/sse2.nim :: line-269 i believe the SSE2 import to cast a single-precision to int : func mm_castps_si128*(a: M128d): M128i {.importc: "_mm_castps_si128".}

should instead receive a single-precision like so : func mm_castps_si128*(a: M128): M128i {.importc: "_mm_castps_si128".}

The cast from double-precision mm_castpd_si128 to M128i is correct and currently has the exact same signature as mm_castps_si128(). Latest Intel Intrinsics Guide/dec.2023 confirms this. I fixed it in the local nimble-dir and it works.

greets Andreas

guzba commented 7 months ago

Thanks for reporting the issue. I have fixed this in the latest release 1.2.8.