author | Jan Vrany <jan.vrany@fit.cvut.cz> |
Wed, 06 Jul 2016 22:40:59 +0100 | |
changeset 71 | ab03b0a6d037 |
parent 68 | a760b8536631 |
child 78 | 7a4c769a9fea |
permissions | -rw-r--r-- |
14
c7dea3fcc5a7
Added short README, license.txt and updated copyright information
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13
diff
changeset
|
1 |
" |
c7dea3fcc5a7
Added short README, license.txt and updated copyright information
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13
diff
changeset
|
2 |
Copyright (C) 2015-now Jan Vrany |
c7dea3fcc5a7
Added short README, license.txt and updated copyright information
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13
diff
changeset
|
3 |
|
c7dea3fcc5a7
Added short README, license.txt and updated copyright information
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13
diff
changeset
|
4 |
This code is not an open-source (yet). You may use this code |
c7dea3fcc5a7
Added short README, license.txt and updated copyright information
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13
diff
changeset
|
5 |
for your own experiments and projects, given that: |
c7dea3fcc5a7
Added short README, license.txt and updated copyright information
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13
diff
changeset
|
6 |
|
c7dea3fcc5a7
Added short README, license.txt and updated copyright information
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13
diff
changeset
|
7 |
* all modification to the code will be sent to the |
c7dea3fcc5a7
Added short README, license.txt and updated copyright information
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13
diff
changeset
|
8 |
original author for inclusion in future releases |
c7dea3fcc5a7
Added short README, license.txt and updated copyright information
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13
diff
changeset
|
9 |
* this is not used in any commercial software |
c7dea3fcc5a7
Added short README, license.txt and updated copyright information
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13
diff
changeset
|
10 |
|
c7dea3fcc5a7
Added short README, license.txt and updated copyright information
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13
diff
changeset
|
11 |
This license is provisional and may (will) change in |
c7dea3fcc5a7
Added short README, license.txt and updated copyright information
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13
diff
changeset
|
12 |
a future. |
c7dea3fcc5a7
Added short README, license.txt and updated copyright information
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13
diff
changeset
|
13 |
" |
12
f98e97fd02ef
Package renamed from jv:libllvms to jv:llvm_s
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
5
diff
changeset
|
14 |
"{ Package: 'jv:llvm_s' }" |
0 | 15 |
|
16 |
"{ NameSpace: Smalltalk }" |
|
17 |
||
1
e3dcb6272f0b
Introduced abstract superclasses LLVMObject and LLVMDisposableObject
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
0
diff
changeset
|
18 |
LLVMObject subclass:#LLVMValue |
5 | 19 |
instanceVariableNames:'type' |
0 | 20 |
classVariableNames:'' |
21 |
poolDictionaries:'' |
|
13
fa967c0e1827
Renamed class categories to begin with LLVM-S
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
12
diff
changeset
|
22 |
category:'LLVM-S-Core' |
0 | 23 |
! |
24 |
||
14
c7dea3fcc5a7
Added short README, license.txt and updated copyright information
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13
diff
changeset
|
25 |
!LLVMValue class methodsFor:'documentation'! |
c7dea3fcc5a7
Added short README, license.txt and updated copyright information
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13
diff
changeset
|
26 |
|
c7dea3fcc5a7
Added short README, license.txt and updated copyright information
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13
diff
changeset
|
27 |
copyright |
c7dea3fcc5a7
Added short README, license.txt and updated copyright information
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13
diff
changeset
|
28 |
" |
c7dea3fcc5a7
Added short README, license.txt and updated copyright information
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13
diff
changeset
|
29 |
Copyright (C) 2015-now Jan Vrany |
c7dea3fcc5a7
Added short README, license.txt and updated copyright information
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13
diff
changeset
|
30 |
|
c7dea3fcc5a7
Added short README, license.txt and updated copyright information
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13
diff
changeset
|
31 |
This code is not an open-source (yet). You may use this code |
c7dea3fcc5a7
Added short README, license.txt and updated copyright information
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13
diff
changeset
|
32 |
for your own experiments and projects, given that: |
c7dea3fcc5a7
Added short README, license.txt and updated copyright information
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13
diff
changeset
|
33 |
|
c7dea3fcc5a7
Added short README, license.txt and updated copyright information
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13
diff
changeset
|
34 |
* all modification to the code will be sent to the |
c7dea3fcc5a7
Added short README, license.txt and updated copyright information
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13
diff
changeset
|
35 |
original author for inclusion in future releases |
c7dea3fcc5a7
Added short README, license.txt and updated copyright information
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13
diff
changeset
|
36 |
* this is not used in any commercial software |
c7dea3fcc5a7
Added short README, license.txt and updated copyright information
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13
diff
changeset
|
37 |
|
c7dea3fcc5a7
Added short README, license.txt and updated copyright information
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13
diff
changeset
|
38 |
This license is provisional and may (will) change in |
c7dea3fcc5a7
Added short README, license.txt and updated copyright information
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13
diff
changeset
|
39 |
a future. |
c7dea3fcc5a7
Added short README, license.txt and updated copyright information
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13
diff
changeset
|
40 |
" |
c7dea3fcc5a7
Added short README, license.txt and updated copyright information
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13
diff
changeset
|
41 |
! ! |
c7dea3fcc5a7
Added short README, license.txt and updated copyright information
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13
diff
changeset
|
42 |
|
4 | 43 |
!LLVMValue methodsFor:'accessing'! |
44 |
||
68
a760b8536631
Added LLVMValue>>initilizer: to allow constanv value fixups.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
61
diff
changeset
|
45 |
initializer: value |
a760b8536631
Added LLVMValue>>initilizer: to allow constanv value fixups.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
61
diff
changeset
|
46 |
self assert: self isGlobalVariable description: 'Receiver is not a global variable'. |
a760b8536631
Added LLVMValue>>initilizer: to allow constanv value fixups.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
61
diff
changeset
|
47 |
self assert: value isConstant description: 'Initializer is not a constant value'. |
a760b8536631
Added LLVMValue>>initilizer: to allow constanv value fixups.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
61
diff
changeset
|
48 |
|
a760b8536631
Added LLVMValue>>initilizer: to allow constanv value fixups.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
61
diff
changeset
|
49 |
LLVM SetInitializer: self _: value |
a760b8536631
Added LLVMValue>>initilizer: to allow constanv value fixups.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
61
diff
changeset
|
50 |
|
a760b8536631
Added LLVMValue>>initilizer: to allow constanv value fixups.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
61
diff
changeset
|
51 |
"Created: / 20-06-2016 / 08:03:03 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
a760b8536631
Added LLVMValue>>initilizer: to allow constanv value fixups.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
61
diff
changeset
|
52 |
! |
a760b8536631
Added LLVMValue>>initilizer: to allow constanv value fixups.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
61
diff
changeset
|
53 |
|
4 | 54 |
name |
55 |
^ LLVM GetValueName: self |
|
56 |
||
57 |
"Created: / 11-07-2015 / 07:28:49 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
58 |
! |
|
59 |
||
60 |
name: aString |
|
61 |
^ LLVM SetValueName: self _: aString |
|
62 |
||
63 |
"Created: / 11-07-2015 / 07:31:17 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
5 | 64 |
! |
65 |
||
61
c2e287d54de5
Added support for PHI nodes.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
43
diff
changeset
|
66 |
parent |
c2e287d54de5
Added support for PHI nodes.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
43
diff
changeset
|
67 |
"Return owning LLVMBasicBlock for this instruction. If the receiver is not |
c2e287d54de5
Added support for PHI nodes.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
43
diff
changeset
|
68 |
an instruction (i.e., #isInstruction returns false), then an error is raised" |
c2e287d54de5
Added support for PHI nodes.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
43
diff
changeset
|
69 |
self isInstruction ifTrue:[ |
c2e287d54de5
Added support for PHI nodes.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
43
diff
changeset
|
70 |
^ LLVM GetInstructionParent: self. |
c2e287d54de5
Added support for PHI nodes.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
43
diff
changeset
|
71 |
]. |
c2e287d54de5
Added support for PHI nodes.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
43
diff
changeset
|
72 |
self error: 'Not an instruction value' |
c2e287d54de5
Added support for PHI nodes.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
43
diff
changeset
|
73 |
|
c2e287d54de5
Added support for PHI nodes.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
43
diff
changeset
|
74 |
"Created: / 21-04-2016 / 22:37:29 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
c2e287d54de5
Added support for PHI nodes.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
43
diff
changeset
|
75 |
"Modified: / 22-04-2016 / 08:42:24 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
c2e287d54de5
Added support for PHI nodes.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
43
diff
changeset
|
76 |
! |
c2e287d54de5
Added support for PHI nodes.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
43
diff
changeset
|
77 |
|
5 | 78 |
type |
79 |
type isNil ifTrue:[ |
|
80 |
type := LLVM TypeOf: self. |
|
81 |
]. |
|
82 |
^ type |
|
83 |
||
84 |
"Created: / 11-07-2015 / 14:53:17 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
4 | 85 |
! ! |
86 |
||
22
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
87 |
!LLVMValue methodsFor:'converting'! |
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
88 |
|
61
c2e287d54de5
Added support for PHI nodes.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
43
diff
changeset
|
89 |
asLLVMBasicBlock |
22
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
90 |
"Return the underlying basic block if the value represents |
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
91 |
a basic block. Otherwise raise an error" |
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
92 |
|
43
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
93 |
self isBasicBlock ifFalse:[ |
22
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
94 |
self error: 'Not a basic block value'. |
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
95 |
]. |
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
96 |
^ LLVM ValueAsBasicBlock: self |
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
97 |
|
61
c2e287d54de5
Added support for PHI nodes.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
43
diff
changeset
|
98 |
"Created: / 21-04-2016 / 22:10:23 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
22
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
99 |
! |
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
100 |
|
33
feabf14b6c1d
Initial support for generating (DWARF) debug info.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
23
diff
changeset
|
101 |
asLLVMMetadata |
feabf14b6c1d
Initial support for generating (DWARF) debug info.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
23
diff
changeset
|
102 |
^ LLVMCEXT ValueAsMetadata: self |
feabf14b6c1d
Initial support for generating (DWARF) debug info.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
23
diff
changeset
|
103 |
|
feabf14b6c1d
Initial support for generating (DWARF) debug info.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
23
diff
changeset
|
104 |
"Created: / 15-08-2015 / 06:41:18 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
feabf14b6c1d
Initial support for generating (DWARF) debug info.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
23
diff
changeset
|
105 |
! |
feabf14b6c1d
Initial support for generating (DWARF) debug info.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
23
diff
changeset
|
106 |
|
22
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
107 |
asLLVMValue |
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
108 |
^ self |
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
109 |
|
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
110 |
"Created: / 08-08-2015 / 02:28:23 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
111 |
! ! |
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
112 |
|
0 | 113 |
!LLVMValue methodsFor:'debugging'! |
114 |
||
2
53abac7217de
Added support for creating execution engines and fetching function addresses.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
115 |
inspectorExtraAttributes |
53abac7217de
Added support for creating execution engines and fetching function addresses.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
116 |
| d | |
53abac7217de
Added support for creating execution engines and fetching function addresses.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
117 |
|
53abac7217de
Added support for creating execution engines and fetching function addresses.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
118 |
d := super inspectorExtraAttributes. |
53abac7217de
Added support for creating execution engines and fetching function addresses.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
119 |
d add: '-dump' -> [ self dumpString ]. |
53abac7217de
Added support for creating execution engines and fetching function addresses.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
120 |
^ d |
53abac7217de
Added support for creating execution engines and fetching function addresses.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
121 |
|
53abac7217de
Added support for creating execution engines and fetching function addresses.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
122 |
"Created: / 10-07-2015 / 14:36:41 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
53abac7217de
Added support for creating execution engines and fetching function addresses.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
123 |
! ! |
53abac7217de
Added support for creating execution engines and fetching function addresses.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
124 |
|
53abac7217de
Added support for creating execution engines and fetching function addresses.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
125 |
!LLVMValue methodsFor:'debugging-dumping'! |
0 | 126 |
|
2
53abac7217de
Added support for creating execution engines and fetching function addresses.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
127 |
dumpOn: aStream |
53abac7217de
Added support for creating execution engines and fetching function addresses.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
128 |
aStream nextPutAll: self dumpString |
53abac7217de
Added support for creating execution engines and fetching function addresses.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
129 |
|
53abac7217de
Added support for creating execution engines and fetching function addresses.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
130 |
"Created: / 10-07-2015 / 14:32:18 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
53abac7217de
Added support for creating execution engines and fetching function addresses.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
131 |
! |
53abac7217de
Added support for creating execution engines and fetching function addresses.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
132 |
|
53abac7217de
Added support for creating execution engines and fetching function addresses.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
133 |
dumpString |
53abac7217de
Added support for creating execution engines and fetching function addresses.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
134 |
| cstr str| |
53abac7217de
Added support for creating execution engines and fetching function addresses.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
135 |
|
53abac7217de
Added support for creating execution engines and fetching function addresses.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
136 |
cstr := LLVM PrintValueToString: self. |
53abac7217de
Added support for creating execution engines and fetching function addresses.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
137 |
str := cstr copyCStringFromHeap. |
53abac7217de
Added support for creating execution engines and fetching function addresses.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
138 |
LLVM DisposeMessage: cstr. |
53abac7217de
Added support for creating execution engines and fetching function addresses.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
139 |
^ str |
53abac7217de
Added support for creating execution engines and fetching function addresses.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
140 |
|
53abac7217de
Added support for creating execution engines and fetching function addresses.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
1
diff
changeset
|
141 |
"Created: / 10-07-2015 / 14:31:23 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
4 | 142 |
! |
0 | 143 |
|
4 | 144 |
printOn: aStream |
22
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
145 |
| name | |
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
146 |
|
4 | 147 |
super printOn: aStream. |
22
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
148 |
aStream nextPut: $(. |
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
149 |
name := self name. |
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
150 |
name notEmptyOrNil ifTrue:[ |
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
151 |
aStream nextPutAll: name |
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
152 |
] ifFalse:[ |
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
153 |
aStream nextPutAll: '<anon>' |
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
154 |
]. |
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
155 |
aStream space. |
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
156 |
aStream nextPutAll: self type dumpString. |
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
157 |
aStream nextPut: $) |
0 | 158 |
|
4 | 159 |
"Created: / 11-07-2015 / 07:09:31 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
22
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
160 |
"Modified: / 08-08-2015 / 04:22:02 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
0 | 161 |
! ! |
162 |
||
43
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
163 |
!LLVMValue methodsFor:'initialization'! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
164 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
165 |
initialize |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
166 |
self class == LLVMValue ifTrue:[ |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
167 |
self isFunction ifTrue:[ |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
168 |
self changeClassTo: LLVMFunction. |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
169 |
]. |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
170 |
]. |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
171 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
172 |
"Created: / 18-09-2015 / 06:14:30 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
173 |
! ! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
174 |
|
5 | 175 |
!LLVMValue methodsFor:'testing'! |
176 |
||
43
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
177 |
isAddrSpaceCastInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
178 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
179 |
^ LLVM IsAAddrSpaceCastInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
180 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
181 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
182 |
isAllocaInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
183 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
184 |
^ LLVM IsAAllocaInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
185 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
186 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
187 |
isArgument |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
188 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
189 |
^ LLVM IsAArgument: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
190 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
191 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
192 |
isBasicBlock |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
193 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
194 |
^ LLVM IsABasicBlock: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
195 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
196 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
197 |
isBinaryOperator |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
198 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
199 |
^ LLVM IsABinaryOperator: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
200 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
201 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
202 |
isBitCastInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
203 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
204 |
^ LLVM IsABitCastInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
205 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
206 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
207 |
isBlockAddress |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
208 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
209 |
^ LLVM IsABlockAddress: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
210 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
211 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
212 |
isBranchInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
213 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
214 |
^ LLVM IsABranchInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
215 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
216 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
217 |
isCallInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
218 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
219 |
^ LLVM IsACallInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
220 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
221 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
222 |
isCastInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
223 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
224 |
^ LLVM IsACastInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
225 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
226 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
227 |
isCatchEndPadInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
228 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
229 |
^ LLVM IsACatchEndPadInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
230 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
231 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
232 |
isCatchPadInst |
16
23e82cf19788
Tests refactored to be actually a testcase. Introduced LLVMConstant class
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14
diff
changeset
|
233 |
|
43
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
234 |
^ LLVM IsACatchPadInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
235 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
236 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
237 |
isCatchReturnInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
238 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
239 |
^ LLVM IsACatchReturnInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
240 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
241 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
242 |
isCleanupPadInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
243 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
244 |
^ LLVM IsACleanupPadInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
245 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
246 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
247 |
isCleanupReturnInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
248 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
249 |
^ LLVM IsACleanupReturnInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
250 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
251 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
252 |
isCmpInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
253 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
254 |
^ LLVM IsACmpInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
255 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
256 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
257 |
isConstant |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
258 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
259 |
^ LLVM IsAConstant: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
260 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
261 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
262 |
isConstantAggregateZero |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
263 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
264 |
^ LLVM IsAConstantAggregateZero: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
265 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
266 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
267 |
isConstantArray |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
268 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
269 |
^ LLVM IsAConstantArray: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
270 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
271 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
272 |
isConstantDataArray |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
273 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
274 |
^ LLVM IsAConstantDataArray: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
275 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
276 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
277 |
isConstantDataSequential |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
278 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
279 |
^ LLVM IsAConstantDataSequential: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
280 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
281 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
282 |
isConstantDataVector |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
283 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
284 |
^ LLVM IsAConstantDataVector: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
285 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
286 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
287 |
isConstantExpr |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
288 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
289 |
^ LLVM IsAConstantExpr: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
290 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
291 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
292 |
isConstantFP |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
293 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
294 |
^ LLVM IsAConstantFP: self |
16
23e82cf19788
Tests refactored to be actually a testcase. Introduced LLVMConstant class
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14
diff
changeset
|
295 |
! |
23e82cf19788
Tests refactored to be actually a testcase. Introduced LLVMConstant class
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14
diff
changeset
|
296 |
|
43
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
297 |
isConstantInt |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
298 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
299 |
^ LLVM IsAConstantInt: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
300 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
301 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
302 |
isConstantPointerNull |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
303 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
304 |
^ LLVM IsAConstantPointerNull: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
305 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
306 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
307 |
isConstantStruct |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
308 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
309 |
^ LLVM IsAConstantStruct: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
310 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
311 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
312 |
isConstantVector |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
313 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
314 |
^ LLVM IsAConstantVector: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
315 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
316 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
317 |
isDbgDeclareInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
318 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
319 |
^ LLVM IsADbgDeclareInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
320 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
321 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
322 |
isDbgInfoIntrinsic |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
323 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
324 |
^ LLVM IsADbgInfoIntrinsic: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
325 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
326 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
327 |
isExtractElementInst |
22
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
328 |
|
43
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
329 |
^ LLVM IsAExtractElementInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
330 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
331 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
332 |
isExtractValueInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
333 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
334 |
^ LLVM IsAExtractValueInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
335 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
336 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
337 |
isFCmpInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
338 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
339 |
^ LLVM IsAFCmpInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
340 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
341 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
342 |
isFPExtInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
343 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
344 |
^ LLVM IsAFPExtInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
345 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
346 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
347 |
isFPToSIInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
348 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
349 |
^ LLVM IsAFPToSIInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
350 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
351 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
352 |
isFPToUIInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
353 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
354 |
^ LLVM IsAFPToUIInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
355 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
356 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
357 |
isFPTruncInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
358 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
359 |
^ LLVM IsAFPTruncInst: self |
22
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
360 |
! |
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
361 |
|
43
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
362 |
isFunction |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
363 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
364 |
^ LLVM IsAFunction: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
365 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
366 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
367 |
isGetElementPtrInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
368 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
369 |
^ LLVM IsAGetElementPtrInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
370 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
371 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
372 |
isGlobalAlias |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
373 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
374 |
^ LLVM IsAGlobalAlias: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
375 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
376 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
377 |
isGlobalObject |
5 | 378 |
|
43
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
379 |
^ LLVM IsAGlobalObject: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
380 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
381 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
382 |
isGlobalValue |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
383 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
384 |
^ LLVM IsAGlobalValue: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
385 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
386 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
387 |
isGlobalVariable |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
388 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
389 |
^ LLVM IsAGlobalVariable: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
390 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
391 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
392 |
isICmpInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
393 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
394 |
^ LLVM IsAICmpInst: self |
5 | 395 |
! |
396 |
||
43
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
397 |
isIndirectBrInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
398 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
399 |
^ LLVM IsAIndirectBrInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
400 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
401 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
402 |
isInlineAsm |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
403 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
404 |
^ LLVM IsAInlineAsm: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
405 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
406 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
407 |
isInsertElementInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
408 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
409 |
^ LLVM IsAInsertElementInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
410 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
411 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
412 |
isInsertValueInst |
5 | 413 |
|
43
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
414 |
^ LLVM IsAInsertValueInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
415 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
416 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
417 |
isInstruction |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
418 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
419 |
^ LLVM IsAInstruction: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
420 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
421 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
422 |
isIntToPtrInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
423 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
424 |
^ LLVM IsAIntToPtrInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
425 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
426 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
427 |
isIntrinsicInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
428 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
429 |
^ LLVM IsAIntrinsicInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
430 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
431 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
432 |
isInvokeInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
433 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
434 |
^ LLVM IsAInvokeInst: self |
22
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
435 |
! |
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
436 |
|
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
437 |
isLLVMValue |
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
438 |
^ true |
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
439 |
|
789a35bd30ac
Added example for compiling conditional. Added convenience API to simply code generation.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16
diff
changeset
|
440 |
"Created: / 08-08-2015 / 03:28:22 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
43
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
441 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
442 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
443 |
isLandingPadInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
444 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
445 |
^ LLVM IsALandingPadInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
446 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
447 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
448 |
isLoadInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
449 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
450 |
^ LLVM IsALoadInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
451 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
452 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
453 |
isMDNode |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
454 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
455 |
^ LLVM IsAMDNode: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
456 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
457 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
458 |
isMDString |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
459 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
460 |
^ LLVM IsAMDString: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
461 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
462 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
463 |
isMemCpyInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
464 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
465 |
^ LLVM IsAMemCpyInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
466 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
467 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
468 |
isMemIntrinsic |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
469 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
470 |
^ LLVM IsAMemIntrinsic: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
471 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
472 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
473 |
isMemMoveInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
474 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
475 |
^ LLVM IsAMemMoveInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
476 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
477 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
478 |
isMemSetInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
479 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
480 |
^ LLVM IsAMemSetInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
481 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
482 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
483 |
isPHINode |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
484 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
485 |
^ LLVM IsAPHINode: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
486 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
487 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
488 |
isPtrToIntInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
489 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
490 |
^ LLVM IsAPtrToIntInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
491 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
492 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
493 |
isResumeInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
494 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
495 |
^ LLVM IsAResumeInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
496 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
497 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
498 |
isReturnInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
499 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
500 |
^ LLVM IsAReturnInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
501 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
502 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
503 |
isSExtInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
504 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
505 |
^ LLVM IsASExtInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
506 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
507 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
508 |
isSIToFPInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
509 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
510 |
^ LLVM IsASIToFPInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
511 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
512 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
513 |
isSelectInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
514 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
515 |
^ LLVM IsASelectInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
516 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
517 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
518 |
isShuffleVectorInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
519 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
520 |
^ LLVM IsAShuffleVectorInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
521 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
522 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
523 |
isStoreInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
524 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
525 |
^ LLVM IsAStoreInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
526 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
527 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
528 |
isSwitchInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
529 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
530 |
^ LLVM IsASwitchInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
531 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
532 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
533 |
isTerminatePadInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
534 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
535 |
^ LLVM IsATerminatePadInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
536 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
537 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
538 |
isTerminatorInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
539 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
540 |
^ LLVM IsATerminatorInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
541 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
542 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
543 |
isTruncInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
544 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
545 |
^ LLVM IsATruncInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
546 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
547 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
548 |
isUIToFPInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
549 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
550 |
^ LLVM IsAUIToFPInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
551 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
552 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
553 |
isUnaryInstruction |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
554 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
555 |
^ LLVM IsAUnaryInstruction: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
556 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
557 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
558 |
isUndefValue |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
559 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
560 |
^ LLVM IsAUndefValue: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
561 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
562 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
563 |
isUnreachableInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
564 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
565 |
^ LLVM IsAUnreachableInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
566 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
567 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
568 |
isUser |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
569 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
570 |
^ LLVM IsAUser: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
571 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
572 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
573 |
isVAArgInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
574 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
575 |
^ LLVM IsAVAArgInst: self |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
576 |
! |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
577 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
578 |
isZExtInst |
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
579 |
|
597181c496f0
Added value-kind testing functions to LLVMValue
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
33
diff
changeset
|
580 |
^ LLVM IsAZExtInst: self |
5 | 581 |
! ! |
582 |
||
23
0744cd9c0acc
Added an example of iterative factorial function
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
22
diff
changeset
|
583 |
!LLVMValue class methodsFor:'documentation'! |
0744cd9c0acc
Added an example of iterative factorial function
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
22
diff
changeset
|
584 |
|
0744cd9c0acc
Added an example of iterative factorial function
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
22
diff
changeset
|
585 |
version_HG |
0744cd9c0acc
Added an example of iterative factorial function
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
22
diff
changeset
|
586 |
|
0744cd9c0acc
Added an example of iterative factorial function
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
22
diff
changeset
|
587 |
^ '$Changeset: <not expanded> $' |
0744cd9c0acc
Added an example of iterative factorial function
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
22
diff
changeset
|
588 |
! ! |
0744cd9c0acc
Added an example of iterative factorial function
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
22
diff
changeset
|
589 |