aboutsummaryrefslogtreecommitdiffstats
path: root/tool/ruby_vm/views/_mjit_compile_insn.erb
diff options
context:
space:
mode:
Diffstat (limited to 'tool/ruby_vm/views/_mjit_compile_insn.erb')
-rw-r--r--tool/ruby_vm/views/_mjit_compile_insn.erb5
1 files changed, 5 insertions, 0 deletions
diff --git a/tool/ruby_vm/views/_mjit_compile_insn.erb b/tool/ruby_vm/views/_mjit_compile_insn.erb
index 90127aa330..e0955687cc 100644
--- a/tool/ruby_vm/views/_mjit_compile_insn.erb
+++ b/tool/ruby_vm/views/_mjit_compile_insn.erb
@@ -20,6 +20,11 @@
MAYBE_UNUSED(<%= ope.fetch(:decl) %>) = (<%= ope.fetch(:type) %>)operands[<%= i %>];
% end
%
+% # JIT: Declare stack_size to be used in some macro of _mjit_compile_insn_body.erb
+ if (status->local_stack_p) {
+ fprintf(f, " MAYBE_UNUSED(unsigned int) stack_size = %u;\n", b->stack_size);
+ }
+%
% # JIT: Declare variables for operands, popped values and return values
% insn.declarations.each do |decl|
fprintf(f, " <%= decl %>;\n");