diff options
author | Jim Laskey <jlaskey@mac.com> | 2006-11-17 16:54:21 +0000 |
---|---|---|
committer | Jim Laskey <jlaskey@mac.com> | 2006-11-17 16:54:21 +0000 |
commit | 64c32dd2eaad73f92f60768212687d85f8114ca7 (patch) | |
tree | 7fb1dbc292166799512a0d5fff827b5452b1d287 /test/CodeGen/PowerPC/Frames-alloca.ll | |
parent | 2ff5cdb16cea04f562402c2a33732840857a66e2 (diff) | |
download | external_llvm-64c32dd2eaad73f92f60768212687d85f8114ca7.zip external_llvm-64c32dd2eaad73f92f60768212687d85f8114ca7.tar.gz external_llvm-64c32dd2eaad73f92f60768212687d85f8114ca7.tar.bz2 |
Tests to verify PowerPC ABI.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31825 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGen/PowerPC/Frames-alloca.ll')
-rw-r--r-- | test/CodeGen/PowerPC/Frames-alloca.ll | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/test/CodeGen/PowerPC/Frames-alloca.ll b/test/CodeGen/PowerPC/Frames-alloca.ll new file mode 100644 index 0000000..0fcae1a --- /dev/null +++ b/test/CodeGen/PowerPC/Frames-alloca.ll @@ -0,0 +1,24 @@ +; RUN: llvm-as < %s | llc -march=ppc32 | grep 'stw r31, 20(r1)' && +; RUN: llvm-as < %s | llc -march=ppc32 | grep 'stwu r1, -64(r1)' && +; RUN: llvm-as < %s | llc -march=ppc32 | grep 'lwz r1, 0(r1)' && +; RUN: llvm-as < %s | llc -march=ppc32 | grep 'lwz r31, 20(r1)' && +; RUN: llvm-as < %s | llc -march=ppc32 -disable-fp-elim | grep 'stw r31, 20(r1)' && +; RUN: llvm-as < %s | llc -march=ppc32 -disable-fp-elim | grep 'stwu r1, -64(r1)' && +; RUN: llvm-as < %s | llc -march=ppc32 -disable-fp-elim | grep 'lwz r1, 0(r1)' && +; RUN: llvm-as < %s | llc -march=ppc32 -disable-fp-elim | grep 'lwz r31, 20(r1)' && +; RUN: llvm-as < %s | llc -march=ppc64 | grep 'std r31, 40(r1)' && +; RUN: llvm-as < %s | llc -march=ppc64 | grep 'stdu r1, -112(r1)' && +; RUN: llvm-as < %s | llc -march=ppc64 | grep 'ld r1, 0(r1)' && +; RUN: llvm-as < %s | llc -march=ppc64 | grep 'ld r31, 40(r1)' && +; RUN: llvm-as < %s | llc -march=ppc64 -disable-fp-elim | grep 'std r31, 40(r1)' && +; RUN: llvm-as < %s | llc -march=ppc64 -disable-fp-elim | grep 'stdu r1, -112(r1)' && +; RUN: llvm-as < %s | llc -march=ppc64 -disable-fp-elim | grep 'ld r1, 0(r1)' && +; RUN: llvm-as < %s | llc -march=ppc64 -disable-fp-elim | grep 'ld r31, 40(r1)' + + +implementation + +int* %f1(uint %n) { + %tmp = alloca int, uint %n + ret int* %tmp +} |