https://bugs.llvm.org/show_bug.cgi?id=49917

            Bug ID: 49917
           Summary: MSVC fails to compile SmallVector.cpp targeting arm32
           Product: libraries
           Version: trunk
          Hardware: PC
                OS: Windows NT
            Status: NEW
          Severity: normal
          Priority: P
         Component: Support Libraries
          Assignee: [email protected]
          Reporter: [email protected]
                CC: [email protected]

Attempting to compile LLVM 12.x for "ARM" architectures in VS2019 latest
(v16.9.2) will fail with the following errors:

llvm-project\llvm\include\llvm/ADT/SmallVector.h(528,1): error C2719: 'Elt':
formal parameter with requested alignment of 16 won't be aligned (compiling
source file llvm-project\llvm\lib\Support\SmallVector.cpp)
llvm-project\llvm\include\llvm/ADT/SmallVector.h(528,1): error C2719: 'Elt':
formal parameter with requested alignment of 32 won't be aligned (compiling
source file llvm-project\llvm\lib\Support\SmallVector.cpp)

This appears to be due to the static assertions in SmallVector.cpp causing
template instantiation of:
void growAndAssign(size_t NumElts, T Elt)

Since this is an explicitly-aligned element being passed on the stack, MSVC
will complain because apparently that's not supported on this architecture. The
code compiles fine for x86/Win32, x64/amd64, and arm64.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to