mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-10-25 05:52:53 +02:00
8b6f5df4ae
The "half vectors" are now widened to full size by the legalizer. The only exception is in parameter passing, where half vectors are expanded. This causes changes to some dejagnu tests. llvm-svn: 111360
34 lines
1.0 KiB
LLVM
34 lines
1.0 KiB
LLVM
; Test parameter passing and return values
|
|
;RUN: llc --march=cellspu %s -o - | FileCheck %s
|
|
|
|
; this fits into registers r3-r74
|
|
%paramstruct = type { i32,i32,i32,i32,i32,i32,i32,i32,i32,i32,i32,i32,
|
|
i32,i32,i32,i32,i32,i32,i32,i32,i32,i32,i32,i32,
|
|
i32,i32,i32,i32,i32,i32,i32,i32,i32,i32,i32,i32,
|
|
i32,i32,i32,i32,i32,i32,i32,i32,i32,i32,i32,i32,
|
|
i32,i32,i32,i32,i32,i32,i32,i32,i32,i32,i32,i32,
|
|
i32,i32,i32,i32,i32,i32,i32,i32,i32,i32,i32,i32}
|
|
define ccc i32 @test_regs( %paramstruct %prm )
|
|
{
|
|
;CHECK: lr $3, $74
|
|
;CHECK: bi $lr
|
|
%1 = extractvalue %paramstruct %prm, 71
|
|
ret i32 %1
|
|
}
|
|
|
|
define ccc i32 @test_regs_and_stack( %paramstruct %prm, i32 %stackprm )
|
|
{
|
|
;CHECK-NOT: a $3, $74, $75
|
|
%1 = extractvalue %paramstruct %prm, 71
|
|
%2 = add i32 %1, %stackprm
|
|
ret i32 %2
|
|
}
|
|
|
|
define ccc %paramstruct @test_return( i32 %param, %paramstruct %prm )
|
|
{
|
|
;CHECK: lqd $75, 80($sp)
|
|
;CHECK: lr $3, $4
|
|
ret %paramstruct %prm
|
|
}
|
|
|