aboutsummaryrefslogtreecommitdiffstats
path: root/test/CodeGen/Generic
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2006-12-16 21:12:49 +0000
committerChris Lattner <sabre@nondot.org>2006-12-16 21:12:49 +0000
commit286505a94483796860afeba7936d84772978e7d7 (patch)
tree78e39a4dc1503d520c10f5f057412306956da732 /test/CodeGen/Generic
parent7f03b2d10750929972a709c9e7455b024c956c91 (diff)
downloadexternal_llvm-286505a94483796860afeba7936d84772978e7d7.zip
external_llvm-286505a94483796860afeba7936d84772978e7d7.tar.gz
external_llvm-286505a94483796860afeba7936d84772978e7d7.tar.bz2
testcase for pr1049
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@32632 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGen/Generic')
-rw-r--r--test/CodeGen/Generic/2006-12-16-InlineAsmCrash.ll34
1 files changed, 34 insertions, 0 deletions
diff --git a/test/CodeGen/Generic/2006-12-16-InlineAsmCrash.ll b/test/CodeGen/Generic/2006-12-16-InlineAsmCrash.ll
new file mode 100644
index 0000000..f8663c3
--- /dev/null
+++ b/test/CodeGen/Generic/2006-12-16-InlineAsmCrash.ll
@@ -0,0 +1,34 @@
+; RUN: llvm-as < %s | llc -march=x86
+; PR1049
+target datalayout = "e-p:32:32"
+target endian = little
+target pointersize = 32
+target triple = "i686-pc-linux-gnu"
+ %struct.QBasicAtomic = type { int }
+ %struct.QByteArray = type { "struct.QByteArray::Data"* }
+ "struct.QByteArray::Data" = type { %struct.QBasicAtomic, int, int, sbyte*, [1 x sbyte] }
+ %struct.QFactoryLoader = type { %struct.QObject }
+ %struct.QImageIOHandler = type { int (...)**, %struct.QImageIOHandlerPrivate* }
+ %struct.QImageIOHandlerPrivate = type opaque
+ %struct.QImageWriter = type { %struct.QImageWriterPrivate* }
+ %struct.QImageWriterPrivate = type { %struct.QByteArray, %struct.QFactoryLoader*, bool, %struct.QImageIOHandler*, int, float, %struct.QString, %struct.QString, uint, %struct.QString, %struct.QImageWriter* }
+ "struct.QList<QByteArray>" = type { "struct.QList<QByteArray>::._20" }
+ "struct.QList<QByteArray>::._20" = type { %struct.QListData }
+ %struct.QListData = type { "struct.QListData::Data"* }
+ "struct.QListData::Data" = type { %struct.QBasicAtomic, int, int, int, ubyte, [1 x sbyte*] }
+ %struct.QObject = type { int (...)**, %struct.QObjectData* }
+ %struct.QObjectData = type { int (...)**, %struct.QObject*, %struct.QObject*, "struct.QList<QByteArray>", ubyte, [3 x ubyte], int, int }
+ %struct.QString = type { "struct.QString::Data"* }
+ "struct.QString::Data" = type { %struct.QBasicAtomic, int, int, ushort*, ubyte, ubyte, [1 x ushort] }
+
+implementation ; Functions:
+
+bool %_ZNK12QImageWriter8canWriteEv() {
+ %tmp62 = load %struct.QImageWriterPrivate** null ; <%struct.QImageWriterPrivate*> [#uses=1]
+ %tmp = getelementptr %struct.QImageWriterPrivate* %tmp62, int 0, uint 9 ; <%struct.QString*> [#uses=1]
+ %tmp75 = call %struct.QString* %_ZN7QStringaSERKS_( %struct.QString* %tmp, %struct.QString* null ) ; <%struct.QString*> [#uses=0]
+ call void asm sideeffect "lock\0Adecl $0\0Asetne 1", "==m"( int* null )
+ ret bool false
+}
+
+declare %struct.QString* %_ZN7QStringaSERKS_(%struct.QString*, %struct.QString*)