YJIT: Do not refer to an undefined constant (#7112)
This commit is contained in:
parent
8d3ff66389
commit
da7e5c7b77
Notes:
git
2023-01-12 20:09:59 +00:00
Merged-By: maximecb <maximecb@ruby-lang.org>
7
yjit.rb
7
yjit.rb
@ -195,14 +195,11 @@ module RubyVM::YJIT
|
|||||||
|
|
||||||
# Produce a list of instructions compiled by YJIT for an iseq
|
# Produce a list of instructions compiled by YJIT for an iseq
|
||||||
def self.insns_compiled(iseq)
|
def self.insns_compiled(iseq)
|
||||||
|
return nil unless self.enabled?
|
||||||
|
|
||||||
# If a method or proc is passed in, get its iseq
|
# If a method or proc is passed in, get its iseq
|
||||||
iseq = RubyVM::InstructionSequence.of(iseq)
|
iseq = RubyVM::InstructionSequence.of(iseq)
|
||||||
|
|
||||||
if self.enabled?
|
|
||||||
Primitive.rb_yjit_insns_compiled(iseq)
|
Primitive.rb_yjit_insns_compiled(iseq)
|
||||||
else
|
|
||||||
Qnil
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
|
|
||||||
# Free and recompile all existing JIT code
|
# Free and recompile all existing JIT code
|
||||||
|
Loading…
x
Reference in New Issue
Block a user