ARM ABI: passing illegal vector types as varargs.
authorManman Ren <mren@apple.com>
Tue, 16 Oct 2012 19:18:39 +0000 (19:18 +0000)
committerManman Ren <mren@apple.com>
Tue, 16 Oct 2012 19:18:39 +0000 (19:18 +0000)
commitfef9e3199a6256c957e990f79051b8926f623538
treeae27eb03d52da5c7977bfea6f684ade05f514d0c
parentcca54d04607b5ad356d9c8babcfb4898ac75d72f
ARM ABI: passing illegal vector types as varargs.

We expand varargs in clang and the call site is handled in the back end, it is
hard to match exactly how illegal vectors are handled in the backend. Therefore,
we legalize the illegal vector types in clang:
if (Size <= 32), legalize to i32.
if (Size == 64), legalize to v2i32.
if (Size == 128), legalize to v4i32.
if (Size > 128), use indirect.

rdar://12439123

llvm-svn: 166043
clang/lib/CodeGen/TargetInfo.cpp
clang/test/CodeGen/arm-abi-vector.c