xref: /aosp_15_r20/external/llvm/test/CodeGen/Mips/cconv/stack-alignment.ll (revision 9880d6810fe72a1726cb53787c6711e909410d58)
1*9880d681SAndroid Build Coastguard Worker; RUN: llc -march=mips < %s | FileCheck --check-prefixes=ALL,O32 %s
2*9880d681SAndroid Build Coastguard Worker; RUN: llc -march=mipsel < %s | FileCheck --check-prefixes=ALL,O32 %s
3*9880d681SAndroid Build Coastguard Worker
4*9880d681SAndroid Build Coastguard Worker; RUN-TODO: llc -march=mips64 -target-abi o32 < %s | FileCheck --check-prefixes=ALL,O32 %s
5*9880d681SAndroid Build Coastguard Worker; RUN-TODO: llc -march=mips64el -target-abi o32 < %s | FileCheck --check-prefixes=ALL,O32 %s
6*9880d681SAndroid Build Coastguard Worker
7*9880d681SAndroid Build Coastguard Worker; RUN: llc -march=mips64 -target-abi n32 < %s | FileCheck --check-prefixes=ALL,N32 %s
8*9880d681SAndroid Build Coastguard Worker; RUN: llc -march=mips64el -target-abi n32 < %s | FileCheck --check-prefixes=ALL,N32 %s
9*9880d681SAndroid Build Coastguard Worker
10*9880d681SAndroid Build Coastguard Worker; RUN: llc -march=mips64 -target-abi n64 < %s | FileCheck --check-prefixes=ALL,N64 %s
11*9880d681SAndroid Build Coastguard Worker; RUN: llc -march=mips64el -target-abi n64 < %s | FileCheck --check-prefixes=ALL,N64 %s
12*9880d681SAndroid Build Coastguard Worker
13*9880d681SAndroid Build Coastguard Worker; Test the stack alignment for all ABI's and byte orders as specified by
14*9880d681SAndroid Build Coastguard Worker; section 5 of MD00305 (MIPS ABIs Described).
15*9880d681SAndroid Build Coastguard Worker
16*9880d681SAndroid Build Coastguard Workerdefine void @local_bytes_1() nounwind {
17*9880d681SAndroid Build Coastguard Workerentry:
18*9880d681SAndroid Build Coastguard Worker        %0 = alloca i8
19*9880d681SAndroid Build Coastguard Worker        ret void
20*9880d681SAndroid Build Coastguard Worker}
21*9880d681SAndroid Build Coastguard Worker
22*9880d681SAndroid Build Coastguard Worker; ALL-LABEL: local_bytes_1:
23*9880d681SAndroid Build Coastguard Worker; O32:           addiu $sp, $sp, -8
24*9880d681SAndroid Build Coastguard Worker; O32:           addiu $sp, $sp, 8
25*9880d681SAndroid Build Coastguard Worker; N32:           addiu $sp, $sp, -16
26*9880d681SAndroid Build Coastguard Worker; N32:           addiu $sp, $sp, 16
27*9880d681SAndroid Build Coastguard Worker; N64:           addiu $sp, $sp, -16
28*9880d681SAndroid Build Coastguard Worker; N64:           addiu $sp, $sp, 16
29