[llvm-bugs] [Bug 42263] New: Clang-cl support for MSVC overload of __builtin_assume_aligned
via llvm-bugs
llvm-bugs at lists.llvm.org
Wed Jun 12 17:33:02 PDT 2019
https://bugs.llvm.org/show_bug.cgi?id=42263
Bug ID: 42263
Summary: Clang-cl support for MSVC overload of
__builtin_assume_aligned
Product: new-bugs
Version: unspecified
Hardware: PC
OS: Windows NT
Status: NEW
Severity: normal
Priority: P
Component: new bugs
Assignee: unassignedbugs at nondot.org
Reporter: kile at microsoft.com
CC: htmldeveloper at gmail.com, llvm-bugs at lists.llvm.org
Created attachment 22087
--> https://bugs.llvm.org/attachment.cgi?id=22087&action=edit
example
As part of the C++20 work for std::assume_aligned, MSVC has implemented an
intrinsic that has an already existing counterpart on clang, gcc, etc. The
declaration is almost identical to those except that it's constexpr. Function
declaration:
constexpr void* __builtin_assume_aligned(const void*, size_t, ... ) noexcept;
Clang/GCC delcaration:
void* __builtin_assume_aligned(const void*, size_t, ... ) noexcept;
Currently the MSVC intrinsic isn't accepted due to it's constexprness (or at
least on clang-cl it's not right now) but we'd like this to work on that front
end at some point.
Current error:
error: constexpr declaration of '__builtin_assume_aligned' follows
non-constexpr declaration
constexpr void* __builtin_assume_aligned(const void*, size_t, ... /* size_t
misalignmentOffset */) noexcept;
^
bug.cpp(2,17): note: previous declaration is here
--
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/20190613/069e4f90/attachment.html>
More information about the llvm-bugs
mailing list