ext/internal/vm/instruction/insns_info.h in ruby-internal-0.7.2 vs ext/internal/vm/instruction/insns_info.h in ruby-internal-0.7.3
- old
+ new
@@ -11,11 +11,11 @@
#include "vm.h"
#endif
/** -*-c-*-
This file contains YARV instructions list.
-
+
----
This file is auto generated by insns2vm.rb
DO NOT TOUCH!
If you want to fix something, you must edit 'template/insns.inc.tmpl'
@@ -169,34 +169,36 @@
BIN(opt_aset) = 70,
BIN(opt_length) = 71,
- BIN(opt_succ) = 72,
+ BIN(opt_size) = 72,
- BIN(opt_not) = 73,
+ BIN(opt_succ) = 73,
- BIN(opt_regexpmatch1) = 74,
+ BIN(opt_not) = 74,
- BIN(opt_regexpmatch2) = 75,
+ BIN(opt_regexpmatch1) = 75,
- BIN(opt_call_c_function) = 76,
+ BIN(opt_regexpmatch2) = 76,
- BIN(bitblt) = 77,
+ BIN(opt_call_c_function) = 77,
- BIN(answer) = 78,
+ BIN(bitblt) = 78,
- VM_INSTRUCTION_SIZE = 79
+ BIN(answer) = 79,
+
+ VM_INSTRUCTION_SIZE = 80
};
/** -*-c-*-
This file contains instruction information for yarv instruction sequence.
-
+
----
This file is auto generated by insns2vm.rb
DO NOT TOUCH!
-
+
If you want to fix something, you must edit 'template/insns_info.inc.tmpl'
or insns2vm.rb
*/
#define TS_OFFSET 'O'
@@ -283,10 +285,11 @@
"opt_ge",
"opt_ltlt",
"opt_aref",
"opt_aset",
"opt_length",
+ "opt_size",
"opt_succ",
"opt_not",
"opt_regexpmatch1",
"opt_regexpmatch2",
"opt_call_c_function",
@@ -301,16 +304,16 @@
"L",
"VN",
"V",
"DN",
"DN",
+ "IC",
+ "IC",
"I",
"I",
"I",
"I",
- "I",
- "I",
"G",
"G",
"",
"",
"V",
@@ -346,32 +349,33 @@
"",
"N",
"O",
"O",
"O",
- "CO",
- "CO",
- "O",
+ "OC",
+ "OC",
+ "C",
"HO",
"",
- "",
- "",
- "",
- "",
- "",
"C",
+ "C",
+ "C",
+ "C",
+ "C",
+ "C",
"CC",
- "",
- "",
- "",
- "",
- "",
- "",
- "",
- "",
- "",
"C",
+ "C",
+ "C",
+ "C",
+ "C",
+ "C",
+ "C",
+ "C",
+ "C",
+ "C",
+ "C",
"V",
"",
"F",
"",
"",
@@ -384,18 +388,18 @@
2,
3,
2,
3,
3,
+ 3,
+ 3,
2,
2,
2,
2,
2,
2,
- 2,
- 2,
1,
1,
2,
2,
2,
@@ -434,28 +438,29 @@
3,
3,
2,
3,
1,
- 1,
- 1,
- 1,
- 1,
- 1,
2,
+ 2,
+ 2,
+ 2,
+ 2,
+ 2,
3,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
2,
2,
+ 2,
+ 2,
+ 2,
+ 2,
+ 2,
+ 2,
+ 2,
+ 2,
+ 2,
+ 2,
1,
2,
1,
1,
@@ -537,10 +542,11 @@
1,
1,
1,
1,
1,
+ 1,
0,
1,
1,
};
@@ -614,36 +620,36 @@
case BIN(putstring):{
return depth + 1;
}
case BIN(concatstrings):{
int inc = 0;
- rb_num_t num = FIX2INT(opes[0]);
+ int num = FIX2INT(opes[0]);
inc += 1 - num;;
return depth + inc;
}
case BIN(tostring):{
return depth + 0;
}
case BIN(toregexp):{
int inc = 0;
- rb_num_t cnt = FIX2INT(opes[1]);
+ int cnt = FIX2INT(opes[1]);
inc += 1 - cnt;;
return depth + inc;
}
case BIN(newarray):{
int inc = 0;
- rb_num_t num = FIX2INT(opes[0]);
+ int num = FIX2INT(opes[0]);
inc += 1 - num;;
return depth + inc;
}
case BIN(duparray):{
return depth + 1;
}
case BIN(expandarray):{
int inc = 0;
- rb_num_t num = FIX2INT(opes[0]);
- rb_num_t flag = FIX2INT(opes[1]);
+ int num = FIX2INT(opes[0]);
+ int flag = FIX2INT(opes[1]);
inc += num - 1 + (flag & 1 ? 1 : 0);;
return depth + inc;
}
case BIN(concatarray):{
return depth + -1;
@@ -654,11 +660,11 @@
case BIN(checkincludearray):{
return depth + 0;
}
case BIN(newhash):{
int inc = 0;
- rb_num_t num = FIX2INT(opes[0]);
+ int num = FIX2INT(opes[0]);
inc += 1 - num;;
return depth + inc;
}
case BIN(newrange):{
return depth + -1;
@@ -669,11 +675,11 @@
case BIN(dup):{
return depth + 1;
}
case BIN(dupn):{
int inc = 0;
- rb_num_t n = FIX2INT(opes[0]);
+ int n = FIX2INT(opes[0]);
inc += n;;
return depth + inc;
}
case BIN(swap):{
return depth + 0;
@@ -693,11 +699,11 @@
inc += 0;
return depth + inc;
}
case BIN(adjuststack):{
int inc = 0;
- rb_num_t n = FIX2INT(opes[0]);
+ int n = FIX2INT(opes[0]);
inc -= n;
return depth + inc;
}
case BIN(defined):{
return depth + 0;
@@ -708,25 +714,25 @@
case BIN(defineclass):{
return depth + -1;
}
case BIN(send):{
int inc = 0;
- rb_num_t op_argc = FIX2INT(opes[1]);
- rb_num_t op_flag = FIX2INT(opes[3]);
- inc += - (op_argc + ((op_flag & VM_CALL_ARGS_BLOCKARG_BIT) ? 1 : 0));;
+ int op_argc = FIX2INT(opes[1]);
+ int op_flag = FIX2INT(opes[3]);
+ inc += - (int)(op_argc + ((op_flag & VM_CALL_ARGS_BLOCKARG_BIT) ? 1 : 0));;
return depth + inc;
}
case BIN(invokesuper):{
int inc = 0;
- rb_num_t op_argc = FIX2INT(opes[0]);
- rb_num_t op_flag = FIX2INT(opes[2]);
- inc += - (op_argc + ((op_flag & VM_CALL_ARGS_BLOCKARG_BIT) ? 1 : 0));;
+ int op_argc = FIX2INT(opes[0]);
+ int op_flag = FIX2INT(opes[2]);
+ inc += - (int)(op_argc + ((op_flag & VM_CALL_ARGS_BLOCKARG_BIT) ? 1 : 0));;
return depth + inc;
}
case BIN(invokeblock):{
int inc = 0;
- rb_num_t num = FIX2INT(opes[0]);
+ int num = FIX2INT(opes[0]);
inc += 1 - num;;
return depth + inc;
}
case BIN(leave):{
return depth + 0;
@@ -806,10 +812,13 @@
return depth + -2;
}
case BIN(opt_length):{
return depth + 0;
}
+ case BIN(opt_size):{
+ return depth + 0;
+ }
case BIN(opt_succ):{
return depth + 0;
}
case BIN(opt_not):{
return depth + 0;
@@ -838,43 +847,43 @@
#endif
/* some utilities */
static int
-insn_len(int insn)
+insn_len(VALUE insn)
{
- return insn_len_info[insn];
+ return insn_len_info[(int)insn];
}
static const char *
-insn_name(int insn)
+insn_name(VALUE insn)
{
- return insn_name_info[insn];
+ return insn_name_info[(int)insn];
}
static const char *
-insn_op_types(int insn)
+insn_op_types(VALUE insn)
{
- return insn_operand_info[insn];
+ return insn_operand_info[(int)insn];
}
static int
-insn_op_type(int insn, int pos)
+insn_op_type(VALUE insn, long pos)
{
int len = insn_len(insn) - 1;
if(pos < len){
- return insn_operand_info[insn][pos];
+ return insn_operand_info[(int)insn][pos];
}
else{
return 0;
}
}
#ifdef USE_INSN_RET_NUM
static int
-insn_ret_num(int insn)
+insn_ret_num(VALUE insn)
{
- return insn_stack_push_num_info[insn];
+ return insn_stack_push_num_info[(int)insn];
}
#endif
void
make_compile_option(rb_compile_option_t *option, VALUE opt);
void