1 ; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 4
2 ; RUN: opt < %s -passes=newgvn | llvm-dis
4 target datalayout = "e-p:32:32:32-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:32:64-f32:32:32-f64:32:64-v64:64:64-v128:128:128-a0:0:64-f80:128:128"
5 target triple = "i386-apple-darwin7"
6 %struct..4sPragmaType = type { ptr, i32 }
7 %struct.AggInfo = type { i8, i8, i32, ptr, i32, ptr, i32, i32, i32, ptr, i32, i32 }
8 %struct.AggInfo_col = type { ptr, i32, i32, i32, i32, ptr }
9 %struct.AggInfo_func = type { ptr, ptr, i32, i32 }
10 %struct.AuxData = type { ptr, ptr }
11 %struct.Bitvec = type { i32, i32, i32, { [125 x i32] } }
12 %struct.BtCursor = type { ptr, ptr, ptr, ptr, ptr, ptr, i32, ptr, i32, %struct.CellInfo, i8, i8, ptr, i64, i32, i8, ptr }
13 %struct.BtLock = type { ptr, i32, i8, ptr }
14 %struct.BtShared = type { ptr, ptr, ptr, ptr, i8, i8, i8, i8, i8, i8, i8, i8, i32, i16, i16, i32, i32, i32, i32, i8, i32, ptr, ptr, ptr, %struct.BusyHandler, i32, ptr, ptr, ptr }
15 %struct.Btree = type { ptr, ptr, i8, i8, i8, i32, ptr, ptr }
16 %struct.BtreeMutexArray = type { i32, [11 x ptr] }
17 %struct.BusyHandler = type { ptr, ptr, i32 }
18 %struct.CellInfo = type { ptr, i64, i32, i32, i16, i16, i16, i16 }
19 %struct.CollSeq = type { ptr, i8, i8, ptr, ptr, ptr }
20 %struct.Column = type { ptr, ptr, ptr, ptr, i8, i8, i8, i8 }
21 %struct.Context = type { i64, i32, %struct.Fifo }
22 %struct.CountCtx = type { i64 }
23 %struct.Cursor = type { ptr, i32, i64, i64, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i64, ptr, i32, ptr, i64, ptr, ptr, i32, i64, ptr, ptr, i32, i32, ptr, ptr, ptr }
24 %struct.Db = type { ptr, ptr, i8, i8, ptr, ptr, ptr }
25 %struct.Expr = type { i8, i8, i16, ptr, ptr, ptr, ptr, %struct..4sPragmaType, %struct..4sPragmaType, i32, i32, ptr, i32, i32, ptr, ptr, i32 }
26 %struct.ExprList = type { i32, i32, i32, ptr }
27 %struct.ExprList_item = type { ptr, ptr, i8, i8, i8 }
28 %struct.FKey = type { ptr, ptr, ptr, ptr, i32, ptr, i8, i8, i8, i8 }
29 %struct.Fifo = type { i32, ptr, ptr }
30 %struct.FifoPage = type { i32, i32, i32, ptr, [1 x i64] }
31 %struct.FuncDef = type { i16, i8, i8, i8, ptr, ptr, ptr, ptr, ptr, [1 x i8] }
32 %struct.Hash = type { i8, i8, i32, i32, ptr, ptr }
33 %struct.HashElem = type { ptr, ptr, ptr, ptr, i32 }
34 %struct.IdList = type { ptr, i32, i32 }
35 %struct.Index = type { ptr, i32, ptr, ptr, ptr, i32, i8, i8, ptr, ptr, ptr, ptr, ptr }
36 %struct.KeyInfo = type { ptr, i8, i8, i8, i32, ptr, [1 x ptr] }
37 %struct.Mem = type { %struct.CountCtx, double, ptr, ptr, i32, i16, i8, i8, ptr }
38 %struct.MemPage = type { i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i16, i16, i16, i16, i16, i16, [5 x %struct._OvflCell], ptr, ptr, ptr, i32, ptr }
39 %struct.Module = type { ptr, ptr, ptr, ptr }
40 %struct.Op = type { i8, i8, i8, i8, i32, i32, i32, { i32 } }
41 %struct.Pager = type { ptr, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, %struct.PagerLruList, ptr, ptr, ptr, i64, i64, i64, i64, i64, i32, ptr, ptr, i32, ptr, ptr, [16 x i8] }
42 %struct.PagerLruLink = type { ptr, ptr }
43 %struct.PagerLruList = type { ptr, ptr, ptr }
44 %struct.Parse = type { ptr, i32, ptr, ptr, i8, i8, i8, i8, i8, i8, i8, [8 x i32], i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, [12 x i32], i32, ptr, i32, i32, i32, i32, i32, ptr, i8, %struct..4sPragmaType, %struct..4sPragmaType, %struct..4sPragmaType, ptr, ptr, ptr, ptr, ptr, ptr, %struct..4sPragmaType, i8, ptr, i32 }
45 %struct.PgHdr = type { ptr, i32, ptr, ptr, %struct.PagerLruLink, ptr, i8, i8, i8, i8, i8, i16, ptr, ptr, ptr }
46 %struct.Schema = type { i32, %struct.Hash, %struct.Hash, %struct.Hash, %struct.Hash, ptr, i8, i8, i16, i32, ptr }
47 %struct.Select = type { ptr, i8, i8, i8, i8, i8, i8, i8, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, i32, i32, [3 x i32] }
48 %struct.SrcList = type { i16, i16, [1 x %struct.SrcList_item] }
49 %struct.SrcList_item = type { ptr, ptr, ptr, ptr, ptr, i8, i8, i32, ptr, ptr, i64 }
50 %struct.Table = type { ptr, i32, ptr, i32, ptr, i32, ptr, i32, ptr, ptr, ptr, ptr, i32, i8, i8, i8, i8, i8, i8, i8, ptr, ptr, i32, ptr, ptr }
51 %struct.TableLock = type { i32, i32, i8, ptr }
52 %struct.Trigger = type { ptr, ptr, i8, i8, ptr, ptr, %struct..4sPragmaType, ptr, ptr, ptr, ptr }
53 %struct.TriggerStack = type { ptr, i32, i32, i32, i32, i32, i32, ptr, ptr }
54 %struct.TriggerStep = type { i32, i32, ptr, ptr, %struct..4sPragmaType, ptr, ptr, ptr, ptr, ptr }
55 %struct.Vdbe = type { ptr, ptr, ptr, i32, i32, ptr, i32, i32, ptr, ptr, ptr, i32, ptr, i32, ptr, ptr, i32, i32, i32, ptr, i32, i32, %struct.Fifo, i32, i32, ptr, i32, i32, i32, i32, i32, [25 x i32], i32, i32, ptr, ptr, ptr, i8, i8, i8, i8, i8, i8, i32, i64, i32, %struct.BtreeMutexArray, i32, ptr, i32 }
56 %struct.VdbeFunc = type { ptr, i32, [1 x %struct.AuxData] }
57 %struct._OvflCell = type { ptr, i16 }
58 %struct._ht = type { i32, ptr }
59 %struct.anon = type { double }
60 %struct.sColMap = type { i32, ptr }
61 %struct.sqlite3 = type { ptr, i32, ptr, i32, i32, i32, i32, i8, i8, i8, i8, i32, ptr, i64, i64, i32, i32, i32, ptr, %struct.sqlite3InitInfo, i32, ptr, ptr, i32, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, %struct.anon, ptr, ptr, ptr, ptr, i32, %struct.Hash, ptr, ptr, i32, %struct.Hash, %struct.Hash, %struct.BusyHandler, i32, [2 x %struct.Db], i8 }
62 %struct.sqlite3InitInfo = type { i32, i32, i8 }
63 %struct.sqlite3_context = type { ptr, ptr, %struct.Mem, ptr, i32, ptr }
64 %struct.sqlite3_file = type { ptr }
65 %struct.sqlite3_index_constraint = type { i32, i8, i8, i32 }
66 %struct.sqlite3_index_constraint_usage = type { i32, i8 }
67 %struct.sqlite3_index_info = type { i32, ptr, i32, ptr, ptr, i32, ptr, i32, i32, double }
68 %struct.sqlite3_io_methods = type { i32, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr }
69 %struct.sqlite3_module = type { i32, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr }
70 %struct.sqlite3_mutex = type opaque
71 %struct.sqlite3_vfs = type { i32, i32, i32, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr }
72 %struct.sqlite3_vtab = type { ptr, i32, ptr }
73 %struct.sqlite3_vtab_cursor = type { ptr }
75 define fastcc void @sqlite3Insert(ptr %pParse, ptr %pTabList, ptr %pList, ptr %pSelect, ptr %pColumn, i32 %onError) nounwind {
77 br i1 false, label %bb54, label %bb69.loopexit
79 bb54: ; preds = %entry
80 br label %bb69.loopexit
82 bb59: ; preds = %bb63.preheader
83 %0 = load ptr, ptr %3, align 4 ; <ptr> [#uses=0]
86 bb65: ; preds = %bb63.preheader, %bb59
87 %1 = load ptr, ptr %4, align 4 ; <ptr> [#uses=0]
88 br i1 false, label %bb67, label %bb63.preheader
91 %2 = getelementptr %struct.IdList, ptr %pColumn, i32 0, i32 0 ; <ptr> [#uses=0]
94 bb69.loopexit: ; preds = %bb54, %entry
95 %3 = getelementptr %struct.IdList, ptr %pColumn, i32 0, i32 0 ; <ptr> [#uses=1]
96 %4 = getelementptr %struct.IdList, ptr %pColumn, i32 0, i32 0 ; <ptr> [#uses=1]
97 br label %bb63.preheader
99 bb63.preheader: ; preds = %bb69.loopexit, %bb65
100 br i1 false, label %bb59, label %bb65