[PATCH] D34455: Correct VectorCall x86 (32 bit) behavior for SSE Register Assignment

Erich Keane via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Jun 21 08:44:22 PDT 2017


erichkeane created this revision.

In running some internal vectorcall tests in 32 bit mode, we discovered that the behavior I'd previously implemented for x64 (and applied to x32) regarding the assignment of SSE registers was incorrect.  See spec here: https://msdn.microsoft.com/en-us/library/dn375768.aspx

My previous implementation applied register argument position from the x64 version to both.  This isn't correct for x86, so this removes and refactors that section.  Additionally, it corrects the integer/int-pointer assignments.  Unlike x64, x86 permits integers to be assigned independent of position.

Finally, the code for 32 bit was cleaned up a little to clarify the intent, as well as given a descriptive comment.


https://reviews.llvm.org/D34455

Files:
  lib/CodeGen/TargetInfo.cpp
  test/CodeGen/vectorcall.c

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D34455.103391.patch
Type: text/x-patch
Size: 10101 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20170621/db89a09a/attachment-0001.bin>


More information about the cfe-commits mailing list