summaryrefslogtreecommitdiff
path: root/tool/ruby_vm/views
diff options
context:
space:
mode:
authorshyouhei <shyouhei@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-01-10 01:53:24 +0000
committershyouhei <shyouhei@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-01-10 01:53:24 +0000
commit5ad95486e63675b2bb3ad665bb2b84eb260c6f29 (patch)
tree9ed7d02028ba1edd4a74e090fb4c7155b55aafd6 /tool/ruby_vm/views
parent7c7d47d2369881f8ea22da34077459771276786a (diff)
merge revisions 61753:61750 61747:61740 61737:61728
Revert all the VM generator rewrites; requested by naruse git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61755 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'tool/ruby_vm/views')
-rw-r--r--tool/ruby_vm/views/_attributes.erb34
-rw-r--r--tool/ruby_vm/views/_c_expr.erb17
-rw-r--r--tool/ruby_vm/views/_copyright.erb31
-rw-r--r--tool/ruby_vm/views/_insn_entry.erb50
-rw-r--r--tool/ruby_vm/views/_insn_len_info.erb23
-rw-r--r--tool/ruby_vm/views/_insn_name_info.erb47
-rw-r--r--tool/ruby_vm/views/_insn_operand_info.erb59
-rw-r--r--tool/ruby_vm/views/_insn_stack_increase.erb53
-rw-r--r--tool/ruby_vm/views/_insn_type_chars.erb12
-rw-r--r--tool/ruby_vm/views/_notice.erb22
-rw-r--r--tool/ruby_vm/views/_trace_instruction.erb16
-rw-r--r--tool/ruby_vm/views/insns.inc.erb26
-rw-r--r--tool/ruby_vm/views/insns_info.inc.erb19
-rw-r--r--tool/ruby_vm/views/opt_sc.inc.erb40
-rw-r--r--tool/ruby_vm/views/optinsn.inc.erb71
-rw-r--r--tool/ruby_vm/views/optunifs.inc.erb21
-rw-r--r--tool/ruby_vm/views/vm.inc.erb30
-rw-r--r--tool/ruby_vm/views/vmtc.inc.erb21
18 files changed, 0 insertions, 592 deletions
diff --git a/tool/ruby_vm/views/_attributes.erb b/tool/ruby_vm/views/_attributes.erb
deleted file mode 100644
index 258bf02906..0000000000
--- a/tool/ruby_vm/views/_attributes.erb
+++ /dev/null
@@ -1,34 +0,0 @@
-%# -*- mode:c; style:ruby; coding: utf-8; indent-tabs-mode: nil -*-
-%# Copyright (c) 2017 Urabe, Shyouhei. 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
-%#
-typedef long OFFSET;
-typedef unsigned long lindex_t;
-typedef VALUE GENTRY;
-typedef rb_iseq_t *ISEQ;
-
-#define CALL_ATTRIBUTE(name, insn, ...) attr_ ## name ## _ ## insn(__VA_ARGS__)
-
-% attrs = RubyVM::Instructions.map(&:attributes).flatten
-%
-% attrs.each do |a|
-PUREFUNC(MAYBE_UNUSED(static <%= a.declaration %>));
-% end
-%
-% attrs.each do |a|
-
-/* <%= a.pretty_name %> */
-<%= a.definition %>
-{
-% str = render_c_expr a.expr
-% case str when /\A#/ then
- return
-<%= str -%>
-% else
- return <%= str -%>
-% end
-}
-% end
diff --git a/tool/ruby_vm/views/_c_expr.erb b/tool/ruby_vm/views/_c_expr.erb
deleted file mode 100644
index cebe4d7a5d..0000000000
--- a/tool/ruby_vm/views/_c_expr.erb
+++ /dev/null
@@ -1,17 +0,0 @@
-%# -*- mode:c; style:ruby; coding: utf-8; indent-tabs-mode: nil -*-
-%# Copyright (c) 2017 Urabe, Shyouhei. 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.
-%;
-% if expr.blank?
-% # empty
-% elsif ! expr.__LINE__
-<%= expr.expr %>
-% else
-#line <%= expr.__LINE__ %> <%=cstr expr.__FILE__ %>
-<%= expr.expr %>
-#pragma RubyVM reset source
-% end
diff --git a/tool/ruby_vm/views/_copyright.erb b/tool/ruby_vm/views/_copyright.erb
deleted file mode 100644
index a449b0b735..0000000000
--- a/tool/ruby_vm/views/_copyright.erb
+++ /dev/null
@@ -1,31 +0,0 @@
-%# -*- mode: c; style: ruby; coding: utf-8; indent-tabs-mode: nil -*-
-%# Copyright (c) 2017 Urabe, Shyouhei. 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.
-%;
-%;
-%# Below is the licensing term for the generated output, not this erb file.
-/* This is an auto-generated file and is a part of the programming language
- * Ruby. The person who created a program to generate this file (``I''
- * hereafter) would like to refrain from defining licensing of this generated
- * source code.
- *
- * This file consist of many small parts of codes copyrighted by each authors,
- * not only the ``I'' person. Those original authors agree with some
- * open-source license. I believe that the license we agree is the condition
- * mentioned in the file COPYING. It states "4. You may modify and include
- * the part of the software into any other software ...". But the problem is,
- * the license never makes it clear if such modified parts still remain in the
- * same license, or not. The fact that we agree with the source code's
- * licensing terms do not automatically define that of generated ones. This is
- * the reason why this file is under unclear situation. All that I know is
- * that above provision guarantees this file to exist.
- *
- * Please let me hesitate to declare something about this nuanced contract. I
- * am not in the position to take over other authors' license to merge into my
- * one. Changing them to (say) GPLv3 is not doable by myself. Perhaps someday
- * it might turn out to be okay to say this file is under a license. I wish the
- * situation would become more clear in the future. */
diff --git a/tool/ruby_vm/views/_insn_entry.erb b/tool/ruby_vm/views/_insn_entry.erb
deleted file mode 100644
index cebca8b8d0..0000000000
--- a/tool/ruby_vm/views/_insn_entry.erb
+++ /dev/null
@@ -1,50 +0,0 @@
-%# -*- mode:c; style:ruby; coding: utf-8; indent-tabs-mode: nil -*-
-%# Copyright (c) 2017 Urabe, Shyouhei. 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.
-%;
-
-/* insn <%= insn.pretty_name %> */
-#define NAME_OF_CURRENT_INSN <%= insn.name %>
-INSN_ENTRY(<%= insn.name %>)
-{
-% unless insn.declarations.empty?
- <%= insn.declarations.join(";\n ") %>;
-
-% end
- START_OF_ORIGINAL_INSN(<%= insn.name %>);
-% insn.preamble.each do |konst|
-<%= render_c_expr konst -%>
-% end
-%
-% insn.opes.each_with_index do |ope, i|
- <%= ope[:name] %> = (<%= ope[:type] %>)GET_OPERAND(<%= i + 1 %>);
-% end
-%
-% insn.pops.reverse_each.with_index.reverse_each do |pop, i|
- <%= pop[:name] %> = <%= insn.cast_from_VALUE pop, "TOPN(#{i})"%>;
-% end
- DEBUG_ENTER_INSN(<%=cstr insn.name %>);
- ADD_PC(<%= insn.width %>);
- PREFETCH(GET_PC());
-% unless insn.pops.empty?
- POPN(<%= insn.pops.size %>);
-% end
- COLLECT_USAGE_INSN(<%= insn.bin %>);
-% insn.opes.each_with_index do |ope, i|
- COLLECT_USAGE_OPERAND(<%= insn.bin %>, <%= i %>, <%= ope[:name] %>);
-% end
-<%= render_c_expr insn.expr -%>
-% unless insn.rets.empty?
- CHECK_VM_STACK_OVERFLOW_FOR_INSN(VM_REG_CFP, <%= insn.rets.size %>);
-% insn.rets.each_with_index do |ret, i|
- PUSH(<%= insn.cast_to_VALUE ret %>);
-% end
-% end
-%
- END_INSN(<%= insn.name %>);
-}
-#undef NAME_OF_CURRENT_INSN
diff --git a/tool/ruby_vm/views/_insn_len_info.erb b/tool/ruby_vm/views/_insn_len_info.erb
deleted file mode 100644
index abbdb2e92c..0000000000
--- a/tool/ruby_vm/views/_insn_len_info.erb
+++ /dev/null
@@ -1,23 +0,0 @@
-%# -*- mode:c; style:ruby; coding: utf-8; indent-tabs-mode: nil -*-
-%# Copyright (c) 2017 Urabe, Shyouhei. 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.
-CONSTFUNC(MAYBE_UNUSED(static int insn_len(VALUE insn)));
-extern const char rb_vm_insn_len_info[];
-
-#ifdef RUBY_VM_INSNS_INFO
-const char rb_vm_insn_len_info[] = {
-% RubyVM::Instructions.each_slice 25 do |a|
- <%= a.map(&:width).join(', ') -%>,
-% end
-};
-#endif
-
-int
-insn_len(VALUE i)
-{
- return rb_vm_insn_len_info[i];
-}
diff --git a/tool/ruby_vm/views/_insn_name_info.erb b/tool/ruby_vm/views/_insn_name_info.erb
deleted file mode 100644
index 79a48cd9cb..0000000000
--- a/tool/ruby_vm/views/_insn_name_info.erb
+++ /dev/null
@@ -1,47 +0,0 @@
-%# -*- mode:c; style:ruby; coding: utf-8; indent-tabs-mode: nil -*-
-%# Copyright (c) 2017 Urabe, Shyouhei. 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.
-%
-% a = RubyVM::Instructions.map {|i| i.name }
-% b = (0...a.size)
-% c = a.inject([0]) {|r, i| r << (r[-1] + i.length + 1) }
-% c.pop
-%
-CONSTFUNC(MAYBE_UNUSED(static const char *insn_name(VALUE insn)));
-extern const char *rb_vm_insn_name_info;
-extern const unsigned short rb_vm_insn_name_offset[];
-
-#ifdef RUBY_VM_INSNS_INFO
-const unsigned short rb_vm_insn_name_offset[] = {
-% c.each_slice 12 do |d|
- <%= d.map {|i| sprintf("%4d", i) }.join(', ') %>,
-% end
-};
-ASSERT_VM_INSTRUCTION_SIZE(rb_vm_insn_name_offset);
-
-PACKED_STRUCT(struct rb_vm_insn_name_info_tag {
-% b.each_slice 3 do |d|
- <%= d.map {|i|
- sprintf("const char L%03d[%2d]", i, a[i].length + 1)
- }.join('; ') %>;
-% end
-});
-
-static const struct rb_vm_insn_name_info_tag rb_vm_insn_name_base = {
-% a.each_slice 2 do |d|
- <%= d.map {|i| sprintf("%-30s", cstr(i)) }.join(', ') %>,
-% end
-};
-
-const char *rb_vm_insn_name_info = (const char *)&rb_vm_insn_name_base;
-#endif
-
-const char *
-insn_name(VALUE i)
-{
- return &rb_vm_insn_name_info[rb_vm_insn_name_offset[i]];
-}
diff --git a/tool/ruby_vm/views/_insn_operand_info.erb b/tool/ruby_vm/views/_insn_operand_info.erb
deleted file mode 100644
index f6b6565d59..0000000000
--- a/tool/ruby_vm/views/_insn_operand_info.erb
+++ /dev/null
@@ -1,59 +0,0 @@
-%# -*- mode:c; style:ruby; coding: utf-8; indent-tabs-mode: nil -*-
-%# Copyright (c) 2017 Urabe, Shyouhei. 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.
-%
-% a = RubyVM::Instructions.map {|i| i.operands_info }
-% b = (0...a.size)
-% c = a.inject([0]) {|r, i| r << (r[-1] + i.length + 1) }
-% c.pop
-%
-CONSTFUNC(MAYBE_UNUSED(static const char *insn_op_types(VALUE insn)));
-CONSTFUNC(MAYBE_UNUSED(static int insn_op_type(VALUE insn, long pos)));
-extern const char *rb_vm_insn_op_info;
-extern const unsigned short rb_vm_insn_op_offset[];
-
-#ifdef RUBY_VM_INSNS_INFO
-const unsigned short rb_vm_insn_op_offset[] = {
-% c.each_slice 14 do |d|
- <%= d.map {|i| sprintf("%3d", i) }.join(', ') %>,
-% end
-};
-ASSERT_VM_INSTRUCTION_SIZE(rb_vm_insn_op_offset);
-
-PACKED_STRUCT(struct rb_vm_insn_op_info_tag {
-% b.each_slice 3 do |d|
- <%= d.map {|i|
- sprintf("const char L%03d[%2d]", i, a[i].length + 1)
- }.join('; ') %>;
-% end
-});
-
-static const struct rb_vm_insn_op_info_tag rb_vm_insn_op_base = {
-% a.each_slice 8 do |d|
- <%= d.map {|i| sprintf("%-6s", cstr(i)) }.join(', ') %>,
-% end
-};
-
-const char *rb_vm_insn_op_info = (const char *)&rb_vm_insn_op_base;
-#endif
-
-const char *
-insn_op_types(VALUE i)
-{
- return &rb_vm_insn_op_info[rb_vm_insn_op_offset[i]];
-}
-
-int
-insn_op_type(VALUE i, long j)
-{
- if (j >= insn_len(i)) {
- return 0;
- }
- else {
- return insn_op_types(i)[j];
- }
-}
diff --git a/tool/ruby_vm/views/_insn_stack_increase.erb b/tool/ruby_vm/views/_insn_stack_increase.erb
deleted file mode 100644
index bfe0a3dc6b..0000000000
--- a/tool/ruby_vm/views/_insn_stack_increase.erb
+++ /dev/null
@@ -1,53 +0,0 @@
-%# -*- mode:c; style:ruby; coding: utf-8; indent-tabs-mode: nil -*-
-%# Copyright (c) 2017 Urabe, Shyouhei. 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.
-%#
-PUREFUNC(MAYBE_UNUSED(static int insn_stack_increase(int depth, int insn, const VALUE *opes)));
-PUREFUNC(static rb_snum_t insn_stack_increase_dispatch(enum ruby_vminsn_type insn, const VALUE *opes));
-
-rb_snum_t
-insn_stack_increase_dispatch(enum ruby_vminsn_type insn, const VALUE *opes)
-{
- static const signed char t[] = {
-% RubyVM::Instructions.each_slice 8 do |a|
- <%= a.map { |i|
- if i.has_attribute?('sp_inc')
- '-127'
- else
- sprintf("%4d", i.rets.size - i.pops.size)
- end
- }.join(', ') -%>,
-% end
- };
- signed char c = t[insn];
-
- ASSERT_VM_INSTRUCTION_SIZE(t);
- if (c != -127) {
- return c;
- }
- else switch(insn) {
- default:
- UNREACHABLE;
-% RubyVM::Instructions.each do |i|
-% next unless i.has_attribute?('sp_inc')
- case <%= i.bin %>:
- return CALL_ATTRIBUTE(sp_inc, <%= i.name %><%=
- i.opes.map.with_index do |v, j|
- k = i.cast_from_VALUE v, "opes[#{j}]"
- next ", #{k}"
- end.join
- %>);
-% end
- }
-}
-
-int
-insn_stack_increase(int depth, int insn, const VALUE *opes)
-{
- enum ruby_vminsn_type itype = (enum ruby_vminsn_type)insn;
- return depth + (int)insn_stack_increase_dispatch(itype, opes);
-}
diff --git a/tool/ruby_vm/views/_insn_type_chars.erb b/tool/ruby_vm/views/_insn_type_chars.erb
deleted file mode 100644
index b3eff5624f..0000000000
--- a/tool/ruby_vm/views/_insn_type_chars.erb
+++ /dev/null
@@ -1,12 +0,0 @@
-%# -*- mode:c; style:ruby; coding: utf-8; indent-tabs-mode: nil -*-
-%# Copyright (c) 2017 Urabe, Shyouhei. 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.
-%
-% map = RubyVM::Typemap.each_pair.map {|k, (c, t)| sprintf "%s = '%s'", t, c }
-enum ruby_insn_type_chars {
- <%= map.join(",\n ") %>
-};
diff --git a/tool/ruby_vm/views/_notice.erb b/tool/ruby_vm/views/_notice.erb
deleted file mode 100644
index 8c6cdaf533..0000000000
--- a/tool/ruby_vm/views/_notice.erb
+++ /dev/null
@@ -1,22 +0,0 @@
-%# -*- mode: c; style: ruby; coding: utf-8; indent-tabs-mode: nil -*-
-%# Copyright (c) 2017 Urabe, Shyouhei. 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.
-%;
-%;
-/*******************************************************************/
-/*******************************************************************/
-/*******************************************************************/
-/**
- This file <%= this_file %>.
-
- ----
- This file is auto generated by insns2vm.rb
- DO NOT TOUCH!
-
- If you want to fix something, you must edit <%= cstr edit %>
- or tool/insns2vm.rb
- */
diff --git a/tool/ruby_vm/views/_trace_instruction.erb b/tool/ruby_vm/views/_trace_instruction.erb
deleted file mode 100644
index 30933a6f5a..0000000000
--- a/tool/ruby_vm/views/_trace_instruction.erb
+++ /dev/null
@@ -1,16 +0,0 @@
-%# -*- mode:c; style:ruby; coding: utf-8; indent-tabs-mode: nil -*-
-%# Copyright (c) 2017 Urabe, Shyouhei. 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.
-%;
-
-/* insn <%= insn.pretty_name %> */
-INSN_ENTRY(<%= insn.name %>)
-{
- vm_trace(ec, GET_CFP(), GET_PC());
- DISPATCH_ORIGINAL_INSN(<%= insn.jump_destination %>);
- END_INSN(<%= insn.name %>);
-}
diff --git a/tool/ruby_vm/views/insns.inc.erb b/tool/ruby_vm/views/insns.inc.erb
deleted file mode 100644
index 78dddd69d1..0000000000
--- a/tool/ruby_vm/views/insns.inc.erb
+++ /dev/null
@@ -1,26 +0,0 @@
-/* -*- mode:c; style:ruby; coding: utf-8; indent-tabs-mode: nil -*- */
-
-%# Copyright (c) 2017 Urabe, Shyouhei. 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 YARV instruction list',
- edit: __FILE__,
-} -%>
-
-/* BIN : Basic Instruction Name */
-#define BIN(n) YARVINSN_##n
-
-enum ruby_vminsn_type {
-% RubyVM::Instructions.each do |i|
- <%= i.bin %>,
-% end
- VM_INSTRUCTION_SIZE
-};
-
-#define ASSERT_VM_INSTRUCTION_SIZE(array) \
- STATIC_ASSERT(numberof_##array, numberof(array) == VM_INSTRUCTION_SIZE)
diff --git a/tool/ruby_vm/views/insns_info.inc.erb b/tool/ruby_vm/views/insns_info.inc.erb
deleted file mode 100644
index e08a15e5ef..0000000000
--- a/tool/ruby_vm/views/insns_info.inc.erb
+++ /dev/null
@@ -1,19 +0,0 @@
-/* -*- mode:c; style:ruby; coding: utf-8; indent-tabs-mode: nil -*- */
-
-%# Copyright (c) 2017 Urabe, Shyouhei. 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 instruction information for yarv instruction sequence.',
- edit: __FILE__,
-} %>
-<%= render 'insn_type_chars' %>
-<%= render 'insn_name_info' %>
-<%= render 'insn_len_info' %>
-<%= render 'insn_operand_info' %>
-<%= render 'attributes' %>
-<%= render 'insn_stack_increase' %>
diff --git a/tool/ruby_vm/views/opt_sc.inc.erb b/tool/ruby_vm/views/opt_sc.inc.erb
deleted file mode 100644
index fdc9ee3d08..0000000000
--- a/tool/ruby_vm/views/opt_sc.inc.erb
+++ /dev/null
@@ -1,40 +0,0 @@
-/* -*- mode:c; style:ruby; coding: utf-8; indent-tabs-mode: nil -*- */
-
-%# Copyright (c) 2017 Urabe, Shyouhei. 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.
-% raise ':FIXME:TBW' if RubyVM::VmOptsH['STACK_CACHING']
-<%= render 'copyright' %>
-<%= render 'notice', locals: {
- this_file: 'is for threaded code',
- edit: __FILE__,
-} -%>
-
-#define SC_STATE_SIZE 6
-
-#define SCS_XX 1
-#define SCS_AX 2
-#define SCS_BX 3
-#define SCS_AB 4
-#define SCS_BA 5
-
-#define SC_ERROR 0xffffffff
-
-static const VALUE sc_insn_info[][SC_STATE_SIZE] = {
-#define NO_SC { SC_ERROR, SC_ERROR, SC_ERROR, SC_ERROR, SC_ERROR, SC_ERROR }
-% RubyVM::Instructions.each_slice 8 do |a|
- <%= a.map{|i| 'NO_SC' }.join(', ') %>,
-% end
-#undef NO_SC
-};
-
-static const VALUE sc_insn_next[] = {
-% RubyVM::Instructions.each_slice 8 do |a|
- <%= a.map{|i| 'SCS_XX' }.join(', ') %>,
-% end
-};
-
-ASSERT_VM_INSTRUCTION_SIZE(sc_insn_next);
diff --git a/tool/ruby_vm/views/optinsn.inc.erb b/tool/ruby_vm/views/optinsn.inc.erb
deleted file mode 100644
index 1cb09d4809..0000000000
--- a/tool/ruby_vm/views/optinsn.inc.erb
+++ /dev/null
@@ -1,71 +0,0 @@
-/* -*- mode:c; style:ruby; coding: utf-8; indent-tabs-mode: nil -*- */
-
-%# Copyright (c) 2017 Urabe, Shyouhei. 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: 'is for threaded code',
- edit: __FILE__,
-} -%>
-
-static INSN *
-insn_operands_unification(INSN *iobj)
-{
-#ifdef OPT_OPERANDS_UNIFICATION
- VALUE *op = iobj->operands;
-
- switch (iobj->insn_id) {
- default:
- /* do nothing */;
- break;
-
-% RubyVM::OperandsUnifications.each_group do |orig, unifs|
- case <%= orig.bin %>:
-% unifs.each do |insn|
-
- /* <%= insn.pretty_name %> */
- if ( <%= insn.condition('op') %> ) {
-% insn.opes.each_with_index do |o, x|
-% n = insn.operand_shift_of(o)
-% if n != 0 then
- op[<%= x %>] = op[<%= x + n %>];
-% end
-% end
- iobj->insn_id = <%= insn.bin %>;
- iobj->operand_size = <%= insn.opes.size %>;
- break;
- }
-% end
-
- break;
-% end
- }
-#endif
- return iobj;
-}
-
-int
-rb_insn_unified_local_var_level(VALUE insn)
-{
-#ifdef OPT_OPERANDS_UNIFICATION
- /* optimize rule */
- switch (insn) {
- default:
- return -1; /* do nothing */;
-% RubyVM::OperandsUnifications.each_group do |orig, unifs|
-% unifs.each do|insn|
- case <%= insn.bin %>:
-% insn.spec.map{|(var,val)|val}.reject{|i| i == '*' }.each do |val|
- return <%= val %>;
-% break
-% end
-% end
-% end
- }
-#endif
- return -1;
-}
diff --git a/tool/ruby_vm/views/optunifs.inc.erb b/tool/ruby_vm/views/optunifs.inc.erb
deleted file mode 100644
index 29d8ca2855..0000000000
--- a/tool/ruby_vm/views/optunifs.inc.erb
+++ /dev/null
@@ -1,21 +0,0 @@
-/* -*- mode:c; style:ruby; coding: utf-8; indent-tabs-mode: nil -*- */
-
-%# Copyright (c) 2017 Urabe, Shyouhei. 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.
-% raise ':FIXME:TBW' if RubyVM::VmOptsH['INSTRUCTIONS_UNIFICATION']
-% n = RubyVM::Instructions.size
-<%= render 'copyright' %>
-<%= render 'notice', locals: {
- this_file: 'is for threaded code',
- edit: __FILE__,
-} -%>
-
-/* Let .bss section automatically initialize this variable */
-/* cf. Section 6.7.8 of ISO/IEC 9899:1999 */
-static const int *const *const unified_insns_data[<%= n %>];
-
-ASSERT_VM_INSTRUCTION_SIZE(unified_insns_data);
diff --git a/tool/ruby_vm/views/vm.inc.erb b/tool/ruby_vm/views/vm.inc.erb
deleted file mode 100644
index 24181fab95..0000000000
--- a/tool/ruby_vm/views/vm.inc.erb
+++ /dev/null
@@ -1,30 +0,0 @@
-/* -*- mode:c; style:ruby; coding: utf-8; indent-tabs-mode: nil -*- */
-
-%# Copyright (c) 2017 Urabe, Shyouhei. 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: 'is VM main loop',
- edit: __FILE__,
-} -%>
-
-#include "vm_insnhelper.h"
-% RubyVM::BareInstructions.to_a.each do |insn|
-<%= render 'insn_entry', locals: { insn: insn } -%>
-% end
-%
-% RubyVM::OperandsUnifications.to_a.each do |insn|
-<%= render 'insn_entry', locals: { insn: insn } -%>
-% end
-%
-% RubyVM::InstructionsUnifications.to_a.each do |insn|
-<%= render 'insn_entry', locals: { insn: insn } -%>
-% end
-%
-% RubyVM::TraceInstructions.to_a.each do |insn|
-<%= render 'trace_instruction', locals: { insn: insn } -%>
-% end
diff --git a/tool/ruby_vm/views/vmtc.inc.erb b/tool/ruby_vm/views/vmtc.inc.erb
deleted file mode 100644
index 16886a1ea6..0000000000
--- a/tool/ruby_vm/views/vmtc.inc.erb
+++ /dev/null
@@ -1,21 +0,0 @@
-/* -*- mode:c; style:ruby; coding: utf-8; indent-tabs-mode: nil -*- */
-
-%# Copyright (c) 2017 Urabe, Shyouhei. 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: 'is for threaded code',
- edit: __FILE__,
-} -%>
-
-static const void *const insns_address_table[] = {
-% RubyVM::Instructions.each do |i|
- LABEL_PTR(<%= i.name %>),
-% end
-};
-
-ASSERT_VM_INSTRUCTION_SIZE(insns_address_table);