mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2026-04-25 21:18:19 +00:00
[ms-cxxabi] Add a new calling convention that swaps 'this' and 'sret'
MSVC always places the 'this' parameter for a method first. The implicit 'sret' pointer for methods always comes second. We already implement this for __thiscall by putting sret parameters on the stack, but __cdecl methods require putting both parameters on the stack in opposite order. Using a special calling convention allows frontends to keep the sret parameter first, which avoids breaking lots of assumptions in LLVM and Clang. Fixes PR15768 with the corresponding change in Clang. Reviewers: ributzka, majnemer Differential Revision: http://llvm-reviews.chandlerc.com/D2663 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@200561 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -746,6 +746,8 @@ function. The operand fields are:
|
||||
* ``arm_apcscc``: code 66
|
||||
* ``arm_aapcscc``: code 67
|
||||
* ``arm_aapcs_vfpcc``: code 68
|
||||
* ``x86_thiscallcc``: code 70
|
||||
* ``x86_cdeclmethodcc``: code 80
|
||||
|
||||
* isproto*: Non-zero if this entry represents a declaration rather than a
|
||||
definition
|
||||
|
||||
Reference in New Issue
Block a user