Commit Graph

4 Commits

Author SHA1 Message Date
Reid Kleckner 5b2787dfb2 Revert "Don't count inreg params when mangling fastcall functions"
This reverts commit r214981.

I'm not sure what I was thinking when I wrote this. Testing with MSVC
shows that this function is mangled to '@f@8':
  int __fastcall f(int a, int b);

llvm-svn: 220492
2014-10-23 17:50:42 +00:00
Reid Kleckner 2daa731bab Add a triple to this test to get the right IR mangling
llvm-svn: 214982
2014-08-06 18:09:15 +00:00
Reid Kleckner 61bac93faa Don't count inreg params when mangling fastcall functions
This is consistent with MSVC.

llvm-svn: 214981
2014-08-06 18:09:04 +00:00
Reid Kleckner e41d957028 Round up the size of byval arguments to MinAlign
Otherwise we can end up with an argument frame size that is not a
multiple of stack slot size, which is very awkward.

This fixes PR20547, which was a bug in x86_64 Sys V vararg handling.
However, it's much easier to test this with x86 callee-cleanup
functions, which previously ended in "retl $6" instead of "retl $8".

This does affect behavior of all backends, but it presumably fixes the
same bug in all of them.

llvm-svn: 214980
2014-08-06 17:57:23 +00:00