summaryrefslogtreecommitdiffstats
path: root/llvm/test/CodeGen/X86/windows-itanium-alloca.ll
diff options
context:
space:
mode:
authorSaleem Abdulrasool <compnerd@compnerd.org>2014-11-20 18:01:26 +0000
committerSaleem Abdulrasool <compnerd@compnerd.org>2014-11-20 18:01:26 +0000
commit2f3b3f31827f153a7ed1a3a647a3ea982591c9d7 (patch)
tree9f2cebf6cfc17b3f9a051c7773db621a6ddc56a3 /llvm/test/CodeGen/X86/windows-itanium-alloca.ll
parentd26d85c1f5d4723c6914e26cf0be054e4acc8da0 (diff)
downloadbcm5719-llvm-2f3b3f31827f153a7ed1a3a647a3ea982591c9d7.tar.gz
bcm5719-llvm-2f3b3f31827f153a7ed1a3a647a3ea982591c9d7.zip
X86: use the correct alloca symbol for Windows Itanium
Windows itanium targets the MSVCRT, and the stack probe symbol is provided by MSVCRT. This corrects the emission of stack probes on i686-windows-itanium. llvm-svn: 222439
Diffstat (limited to 'llvm/test/CodeGen/X86/windows-itanium-alloca.ll')
-rw-r--r--llvm/test/CodeGen/X86/windows-itanium-alloca.ll16
1 files changed, 16 insertions, 0 deletions
diff --git a/llvm/test/CodeGen/X86/windows-itanium-alloca.ll b/llvm/test/CodeGen/X86/windows-itanium-alloca.ll
new file mode 100644
index 00000000000..0a06cdef879
--- /dev/null
+++ b/llvm/test/CodeGen/X86/windows-itanium-alloca.ll
@@ -0,0 +1,16 @@
+; RUN: llc -mtriple i686-windows-itanium -filetype asm -o - %s | FileCheck %s
+
+target datalayout = "e-m:w-p:32:32-i64:64-f80:32-n8:16:32-S32"
+target triple = "i686--windows-itanium"
+
+declare void @external(i8*)
+
+define dllexport void @alloca(i32 %sz) {
+entry:
+ %vla = alloca i8, i32 %sz, align 1
+ call void @external(i8* %vla)
+ ret void
+}
+
+; CHECK: __chkstk
+
OpenPOWER on IntegriCloud