summaryrefslogtreecommitdiff
path: root/vm_core.h
diff options
context:
space:
mode:
authormame <mame@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-01-01 13:18:55 (GMT)
committermame <mame@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-01-01 13:18:55 (GMT)
commit691b05e83c41d089c4f6c7a8bbac9dd63f36a144 (patch)
tree4249c7e94be29d751b88ed1936600493bfcb4059 /vm_core.h
parent295838e6eb1d063c64f7cde5bbbd13c7768908fd (diff)
vm_core.h: make the algorithm of get_insn_info selectable
Currently, VM_INSN_INFO_TABLE_IMPL == 0 means linear search, and VM_INSN_INFO_TABLE_IMPL == 1 means binary search. I plan to add succinct bitvector algorithm later. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61537 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'vm_core.h')
-rw-r--r--vm_core.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/vm_core.h b/vm_core.h
index 0d08875..16ee74b 100644
--- a/vm_core.h
+++ b/vm_core.h
@@ -56,6 +56,13 @@
#define RUBY_VM_THREAD_MODEL 2
+/*
+ * implementation selector of get_insn_info algorithm
+ * 0: linear search
+ * 1: binary search
+ */
+#define VM_INSN_INFO_TABLE_IMPL 1
+
#include "ruby/ruby.h"
#include "ruby/st.h"