Plain Text Paste by naryl
Description: simple.ll
Hide line numbers

Create new paste
Post a reply
View replies

Paste:
1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
14  
15  
16  
17  
18  
19  
20  
21  
22  
23  
24  
25  
26  
27  
28  
29  
30  
31  
32  
33  
34  
35  
36  
37  
38  
39  
40  
41  
42  
43  
44  
45  
46  
47  
48  
49  
50  
51  
52  
53  
54  
55  
56  
57  
58  
59  
60  
61  
62  
63  
64  
65  
66  
67  
68  
69  
70  
71  
72  
73  
74  
75  
76  
77  
78  
79  
80  
81  
82  
83  
84  
85  
86  
87  
88  
89  
90  
91  
92  
93  
94  
95  
96  
; ModuleID = 'simple'
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:32:32"
target triple = "i686-pc-linux-gnu"
    type { i32, i32, i8*, i32, %1 }        ; type %0
    type { i32, i32 }        ; type %1
    type opaque        ; type %2
    type opaque        ; type %3
    type { %object.ModuleInfo.__vtbl*, i8*, %"byte[]", %5, %6, i32, void ()*, void ()*, void ()*, i8*, void ()* }        ; type %4
    type { i32, %object.ModuleInfo* }        ; type %5
    type { i32, %object.ClassInfo* }        ; type %6
    type { i32, void ()* }        ; type %7
    %"ClassInfo[]" = type { i32, %object.ClassInfo** }
    %D_CRITICAL_SECTION = type { %D_CRITICAL_SECTION*, %0 }
    %"Interface[]" = type { i32, %object.Interface* }
    %"ModuleInfo[]" = type { i32, %object.ModuleInfo** }
    %ModuleReference = type { %ModuleReference*, %object.ModuleInfo* }
    %"OffsetTypeInfo[]" = type { i32, %object.OffsetTypeInfo* }
    %"byte[]" = type { i32, i8* }
    %"char[]" = type { i32, i8* }
    %"char[][]" = type { i32, %"byte[]"* }
    %"int delegate(ref ModuleInfo)" = type { i8*, i32 (i8*, %object.ModuleInfo**)* }
    %object.ClassInfo = type { %object.ClassInfo.__vtbl*, i8*, %"byte[]", %"byte[]", %"void*[]", %"Interface[]", %object.ClassInfo*, i8*, i8*, i32, i8*, %"OffsetTypeInfo[]", i8*, %object.TypeInfo* }
    %object.ClassInfo.__vtbl = type { %object.ClassInfo*, %"byte[]" (%object.Object*)*, i32 (%object.Object*)*, i32 (%object.Object*, %object.Object*)*, i32 (%object.Object*, %object.Object*)*, %object.Object* (%object.ClassInfo*)* }
    %object.Interface = type { %object.ClassInfo*, %"void*[]", i32 }
    %object.ModuleInfo = type { %object.ModuleInfo.__vtbl*, i8*, %"byte[]", %"ModuleInfo[]", %"ClassInfo[]", i32, void ()*, void ()*, void ()*, i8*, void ()* }
    %object.ModuleInfo.__vtbl = type { %object.ClassInfo*, %"byte[]" (%object.Object*)*, i32 (%object.Object*)*, i32 (%object.Object*, %object.Object*)*, i32 (%object.Object*, %object.Object*)* }
    %object.Object = type { %object.ModuleInfo.__vtbl*, i8* }
    %object.Object.Monitor = type { %object.Object.Monitor.__vtbl* }
    %object.Object.Monitor.__vtbl = type { %object.ClassInfo*, void (%object.Object.Monitor*)*, void (%object.Object.Monitor*)* }
    %object.Object.__vtbl = type { %object.ClassInfo*, %"byte[]" (%object.Object*)*, i32 (%object.Object*)*, i32 (%object.Object*, %object.Object*)*, i32 (%object.Object*, %object.Object*)* }
    %object.OffsetTypeInfo = type { i32, %object.TypeInfo* }
    %object.TypeInfo = type { %object.TypeInfo.__vtbl*, i8* }
    %object.TypeInfo.__vtbl = type { %object.ClassInfo*, %"byte[]" (%object.Object*)*, i32 (%object.Object*)*, i32 (%object.Object*, %object.Object*)*, i32 (%object.Object*, %object.Object*)*, i32 (%object.TypeInfo*, i8*)*, i32 (%object.TypeInfo*, i8*, i8*)*, i32 (%object.TypeInfo*, i8*, i8*)*, i32 (%object.TypeInfo*)*, void (%object.TypeInfo*, i8*, i8*)*, %object.TypeInfo* (%object.TypeInfo*)*, %"byte[]" (%object.TypeInfo*)*, i32 (%object.TypeInfo*)*, %"OffsetTypeInfo[]" (%object.TypeInfo*)* }
    %"void*[]" = type { i32, i8** }
    %"void[]" = type { i32, i8* }
@_D6Object7__ClassZ = external global %object.ClassInfo        ; <%object.ClassInfo*> [#uses=0]
@_D6Object6__initZ = external constant %2, align 4        ; <%2*> [#uses=0]
@_D6Object6__vtblZ = external constant %object.ModuleInfo.__vtbl        ; <%object.ModuleInfo.__vtbl*> [#uses=0]
@_D6Object7Monitor11__InterfaceZ = external global %object.ClassInfo        ; <%object.ClassInfo*> [#uses=0]
@_D10ModuleInfo7__ClassZ = external global %object.ClassInfo        ; <%object.ClassInfo*> [#uses=0]
@_D10ModuleInfo6__initZ = external constant %3, align 4        ; <%3*> [#uses=0]
@_D10ModuleInfo6__vtblZ = external constant %object.ModuleInfo.__vtbl        ; <%object.ModuleInfo.__vtbl*> [#uses=1]
@.str = internal constant [7 x i8] c"simple\00"        ; <[7 x i8]*> [#uses=1]
@_D6simple8__ModuleZ = global %4 { %object.ModuleInfo.__vtbl* @_D10ModuleInfo6__vtblZ, i8* null, %"byte[]" { i32 6, i8* getelementptr ([7 x i8]* @.str, i32 0, i32 0) }, %5 zeroinitializer, %6 zeroinitializer, i32 4, void ()* null, void ()* null, void ()* null, i8* null, void ()* null }        ; <%4*> [#uses=1]
@_D6simple11__moduleRefZ = internal global %ModuleReference { %ModuleReference* null, %object.ModuleInfo* bitcast (%4* @_D6simple8__ModuleZ to %object.ModuleInfo*) }        ; <%ModuleReference*> [#uses=2]
@_Dmodule_ref = external global %ModuleReference*        ; <%ModuleReference**> [#uses=2]
@llvm.global_ctors = appending constant [1 x %7] [%7 { i32 65535, void ()* @_D6simple16__moduleinfoCtorZ }]        ; <[1 x %7]*> [#uses=0]

define x86_stdcallcc i32 @_D6simple4funcFZi() {
entry:
    ret i32 42

afterreturn:        ; No predecessors!
    ret i32 undef
}

define x86_stdcallcc i32 @_D6simple4funcFiZi(i32 inreg %i_arg) {
entry:
    %i = alloca i32        ; <i32*> [#uses=2]
    store i32 %i_arg, i32* %i
    %tmp = load i32* %i        ; <i32> [#uses=1]
    ret i32 %tmp

afterreturn:        ; No predecessors!
    ret i32 undef
}

define x86_stdcallcc i32 @_Dmain(%"char[][]" %unnamed) {
entry:
    %a = alloca i32, align 4        ; <i32*> [#uses=1]
    %tmp = call x86_stdcallcc i32 @_D6simple4funcFZi()        ; <i32> [#uses=1]
    store i32 %tmp, i32* %a
    ret i32 0

afterreturn:        ; No predecessors!
    ret i32 0
}

declare x86_stdcallcc %"byte[]" @_D6object6Object8toStringMFZAa(%object.Object* inreg)

declare x86_stdcallcc i32 @_D6object6Object6toHashMFZk(%object.Object* inreg)

declare x86_stdcallcc i32 @_D6object6Object5opCmpMFC6ObjectZi(%object.Object* inreg, %object.Object*)

declare x86_stdcallcc i32 @_D6object6Object8opEqualsMFC6ObjectZi(%object.Object* inreg, %object.Object*)

declare x86_stdcallcc i32 @_D6object10ModuleInfo7opApplyFDFKC10ModuleInfoZiZi(%"int delegate(ref ModuleInfo)")

define internal void @_D6simple16__moduleinfoCtorZ() {
moduleinfoCtorEntry:
    %current = load %ModuleReference** @_Dmodule_ref        ; <%ModuleReference*> [#uses=1]
    store %ModuleReference* %current, %ModuleReference** getelementptr (%ModuleReference* @_D6simple11__moduleRefZ, i32 0, i32 0)
    store %ModuleReference* @_D6simple11__moduleRefZ, %ModuleReference** @_Dmodule_ref
    ret void
}

Replies:

    (some replies deleted)