1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

endbr64 is fine

This commit is contained in:
Alan Wu 2020-09-24 19:26:21 -04:00
parent c718bfc89c
commit 27bc57b6eb

View file

@ -122,7 +122,7 @@ module RubyVM::MicroJIT
raise 'rip reference in example makes copying unsafe' if handler_instructions.any? { |_, _, full_line| full_line.downcase.include?('rip') }
acceptable_mnemonics = %w(mov jmp lea call)
acceptable_mnemonics = %w(mov jmp lea call endbr64)
unrecognized = nil
handler_instructions.each { |i| unrecognized = i unless acceptable_mnemonics.include?(i[1]) }
raise "found an unrecognized \"#{unrecognized[1]}\" instruction in the example. List of recognized instructions: #{acceptable_mnemonics.join(', ')}" if unrecognized