mirror of
https://github.com/RPCSX/llvm.git
synced 2024-11-28 06:00:28 +00:00
f8d3677531
All the usual X86 target-specific conventions are collapsed to the normal Win64 convention, but the custom conventions like GHC and webkit should not be. Previously we would assume that the caller allocated 32 bytes of shadow space for us, which is not how webkit_jscc or other custom conventions are supposed to work. Based on a patch by peavo@outlook.com. Fixes PR24051. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@241725 91177308-0d34-0410-b5e6-96231b3b80d8
19 lines
619 B
LLVM
19 lines
619 B
LLVM
; RUN: llc -mtriple=x86_64-apple-darwin -mcpu=corei7 < %s | FileCheck %s
|
|
; RUN: llc -mtriple=x86_64-linux-gnu -mcpu=corei7 < %s | FileCheck %s
|
|
; RUN: llc -mtriple=x86_64-windows-gnu -mcpu=corei7 < %s | FileCheck %s
|
|
; RUN: llc -mtriple=x86_64-windows-msvc -mcpu=corei7 < %s | FileCheck %s
|
|
|
|
define webkit_jscc i32 @simple_jscall(i32 %a, i32 %b, i32 %c) {
|
|
%ab = add i32 %a, %b
|
|
%abc = add i32 %ab, %c
|
|
ret i32 %abc
|
|
}
|
|
|
|
; 32-bit integers are only aligned to 4 bytes, even on x64. They are *not*
|
|
; promoted to i64.
|
|
|
|
; CHECK: simple_jscall:
|
|
; CHECK: addl 8(%rsp), %eax
|
|
; CHECK-NEXT: addl 12(%rsp), %eax
|
|
; CHECK-NEXT: retq
|