]> granicus.if.org Git - clang/commit
[mips] Correct alignment of vectors passed in varargs for the O32 ABI.
authorDaniel Sanders <daniel.sanders@imgtec.com>
Mon, 22 Sep 2014 13:27:06 +0000 (13:27 +0000)
committerDaniel Sanders <daniel.sanders@imgtec.com>
Mon, 22 Sep 2014 13:27:06 +0000 (13:27 +0000)
commitf7c6647550310ec879856927a5188d0b98fdc311
tree51b9531e5187feb5817b1ce1cbed9817475b238a
parentf066d2a51304347cfc1431800bc8a777a0d7063c
[mips] Correct alignment of vectors passed in varargs for the O32 ABI.

Summary:
Vectors are normally 16-byte aligned, however the O32 ABI enforces a
maximum alignment of 8-bytes since the base of the stack is 8-byte aligned.
Previously, this was enforced on the caller side, but not on the callee side.

This fixes the output of OpenCL's printf when given vectors.

Reviewers: atanasyan

Reviewed By: atanasyan

Subscribers: llvm-commits, pekka.jaaskelainen

Differential Revision: http://reviews.llvm.org/D5433

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@218248 91177308-0d34-0410-b5e6-96231b3b80d8
lib/CodeGen/TargetInfo.cpp
test/CodeGen/mips-varargs.c [new file with mode: 0644]