Class: LLVM::Instruction
Class Method Summary
collapse
Instance Method Summary
collapse
Methods inherited from User
#operands
Methods inherited from Value
#add_attribute, #allocated_type, #allocated_type?, #constant?, #dump, from_ptr_kind, #gep_source_element_type, #gep_source_element_type?, #global_parent, #kind, #name, #name=, #null?, #poison?, #remove_attribute, to_ptr, #to_s, #type, type, #undef?
#==, #eql?, #hash, #to_ptr
Class Method Details
.from_ptr(ptr) ⇒ Object
1186
1187
1188
1189
|
# File 'lib/llvm/core/value.rb', line 1186
def self.from_ptr(ptr)
kind = C.get_value_kind(ptr)
kind == :instruction ? super : LLVM::Value.from_ptr_kind(ptr)
end
|
Instance Method Details
#clear_exact! ⇒ Object
1242
1243
1244
1245
|
# File 'lib/llvm/core/value.rb', line 1242
def clear_exact!
C.set_exact(self, false)
self
end
|
#clear_nsw! ⇒ Object
1222
1223
1224
1225
|
# File 'lib/llvm/core/value.rb', line 1222
def clear_nsw!
C.set_nsw(self, false)
self
end
|
#clear_nuw! ⇒ Object
1232
1233
1234
1235
|
# File 'lib/llvm/core/value.rb', line 1232
def clear_nuw!
C.set_nuw(self, false)
self
end
|
#exact! ⇒ Object
1237
1238
1239
1240
|
# File 'lib/llvm/core/value.rb', line 1237
def exact!
C.set_exact(self, true)
self
end
|
#inspect ⇒ Object
1213
1214
1215
|
# File 'lib/llvm/core/value.rb', line 1213
def inspect
{ self.class.name => { opcode: opcode, ptr: @ptr } }.to_s
end
|
#next ⇒ Object
Returns the next instruction after this one.
#nsw! ⇒ Object
1217
1218
1219
1220
|
# File 'lib/llvm/core/value.rb', line 1217
def nsw!
C.set_nsw(self, true)
self
end
|
#nuw! ⇒ Object
1227
1228
1229
1230
|
# File 'lib/llvm/core/value.rb', line 1227
def nuw!
C.set_nuw(self, true)
self
end
|
#parent ⇒ Object
Returns the parent of the instruction (a BasicBlock).
#previous ⇒ Object
Returns the previous instruction before this one.