blob: 9409c996b11016554158f24b78ea315a3a397bec (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
/* -*- C -*- */
%# Copyright (c) 2020 Wu, Alan. All rights reserved.
%#
%# This file is a part of the programming language Ruby. Permission is hereby
%# granted, to either redistribute and/or modify this file, provided that the
%# conditions mentioned in the file COPYING are met. Consult the file for
%# details.
<%= render 'copyright' %>
<%= render 'notice', locals: {
this_file: 'contains raw instruction bytes that helps MicroJIT generate code',
edit: __FILE__,
} -%>
% success, byte_arrays = RubyVM::MicroJIT.scrape
static const uint8_t ujit_scrape_successful = <%= success %>;
% byte_arrays.each do |(prefix, scrape_result)|
// Disassembly:
% scrape_result.disassembly_lines.each do |line|
// <%= line %>
% end
static const uint8_t <%= prefix %>_pre_call_bytes[] = { <%= scrape_result.pre_call_bytes %> };
static const uint8_t <%= prefix %>_post_call_bytes[] = { <%= scrape_result.post_call_bytes %> };
% end
|