[llvm-bugs] [Bug 31329] New: _mm512_mask_i64gather_ps has incorrect signature
via llvm-bugs
llvm-bugs at lists.llvm.org
Fri Dec 9 05:42:32 PST 2016
https://llvm.org/bugs/show_bug.cgi?id=31329
Bug ID: 31329
Summary: _mm512_mask_i64gather_ps has incorrect signature
Product: clang
Version: unspecified
Hardware: PC
OS: All
Status: NEW
Severity: normal
Priority: P
Component: Headers
Assignee: unassignedclangbugs at nondot.org
Reporter: wenzel.jakob at epfl.ch
CC: llvm-bugs at lists.llvm.org
Classification: Unclassified
Hi,
according to Intel, the intrinsic has the following signature.
__m256 _mm512_mask_i64gather_ps (__m256 src, __mmask8 k, __m512i vindex, void
const* base_addr, int scale)
In particular, note that a void const * pointer is accepted for the 'base_addr'
argument.
However, in avf512intri.h we have
8182 #define _mm512_i64gather_ps(index, addr, scale) __extension__ ({ \
8183 (__m256)__builtin_ia32_gatherdiv16sf((__v8sf)_mm256_undefined_ps(), \
8184 (float const *)(addr), \
8185 (__v8di)(__m512i)(index),
(__mmask8)-1,
8186 (int)(scale)); })
8187
8188 #define _mm512_mask_i64gather_ps( __v1_old, __mask, __index,\
8189 __addr, __scale) __extension__({\
8190 __builtin_ia32_gatherdiv16sf ((__v8sf) __v1_old,\
8191 __addr,(__v8di) __index, __mask, __scale);\
8192 })
Note how the _mm512_i64gather_ps intrinsic casts the argument to float const*,
while the _mm512_mask_i64gather_ps intrinsic does not.
In practice, this means that Clang quits with an type checker error message
when trying to invoke _mm512_mask_i64gather_ps with a void const* argument.
It would be great if this could be fixed!
Thanks,
Wenzel
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20161209/7e0818d6/attachment.html>
More information about the llvm-bugs
mailing list