Module: YTLJit::VM::Node::MethodTopCodeGen
- Includes:
- AbsArch
- Included in:
- BlockTopNode, ClassTopNode, MethodTopNode, TopTopNode
- Defined in:
- lib/ytljit/vm_codegen.rb
Constant Summary
Constants included from AbsArch
AbsArch::AL, AbsArch::BL, AbsArch::CL, AbsArch::DL, AbsArch::FUNC_ARG, AbsArch::FUNC_ARG_YTL, AbsArch::FUNC_FLOAT_ARG, AbsArch::FUNC_FLOAT_ARG_YTL, AbsArch::INDIRECT_BPR, AbsArch::INDIRECT_RETR, AbsArch::INDIRECT_SPR, AbsArch::INDIRECT_TMPR, AbsArch::INDIRECT_TMPR2, AbsArch::INDIRECT_TMPR3
Constants included from SSE
SSE::XMM0, SSE::XMM1, SSE::XMM2, SSE::XMM3, SSE::XMM4, SSE::XMM5, SSE::XMM6, SSE::XMM7
Instance Method Summary collapse
Instance Method Details
#gen_method_prologue(context) ⇒ Object
552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 |
# File 'lib/ytljit/vm_codegen.rb', line 552 def gen_method_prologue(context) asm = context.assembler asm.with_retry do # Make linkage of frame pointer asm.push(BPR) asm.mov(BPR, SPR) asm.push(TMPR) asm.push(THEPR) asm.push(BPR) asm.mov(BPR, SPR) end context.set_reg_content(BPR, :old_ptr) context.cpustack_push(BPR) context.set_reg_content(TMPR, :num_of_args) context.cpustack_push(TMPR) context.set_reg_content(THEPR, :local_heap) context.cpustack_push(THEPR) context.set_reg_content(BPR, :frame_ptr) context.cpustack_push(BPR) context end |