Mercurial > hg > graal-compiler
comparison src/cpu/sparc/vm/templateInterpreter_sparc.cpp @ 7183:b2dbd323c668
8003848: Make ConstMethod::generic_signature_index optional and move Method::_max_stack to ConstMethod.
Summary: Make ConstMethod::generic_signature_index optional and move Method::_max_stack to ConstMethod.
Reviewed-by: bdelsart, sspitsyn, coleenp
author | jiangli |
---|---|
date | Tue, 27 Nov 2012 17:03:56 -0500 |
parents | da91efe96a93 |
children | d2f8c38e543d |
comparison
equal
deleted
inserted
replaced
7165:e1d42ba865de | 7183:b2dbd323c668 |
---|---|
494 // (gri - 2/25/2000) | 494 // (gri - 2/25/2000) |
495 | 495 |
496 | 496 |
497 const Address size_of_parameters(G5_method, Method::size_of_parameters_offset()); | 497 const Address size_of_parameters(G5_method, Method::size_of_parameters_offset()); |
498 const Address size_of_locals (G5_method, Method::size_of_locals_offset()); | 498 const Address size_of_locals (G5_method, Method::size_of_locals_offset()); |
499 const Address max_stack (G5_method, Method::max_stack_offset()); | 499 const Address constMethod (G5_method, Method::const_offset()); |
500 int rounded_vm_local_words = round_to( frame::interpreter_frame_vm_local_words, WordsPerLong ); | 500 int rounded_vm_local_words = round_to( frame::interpreter_frame_vm_local_words, WordsPerLong ); |
501 | 501 |
502 const int extra_space = | 502 const int extra_space = |
503 rounded_vm_local_words + // frame local scratch space | 503 rounded_vm_local_words + // frame local scratch space |
504 //6815692//Method::extra_stack_words() + // extra push slots for MH adapters | 504 //6815692//Method::extra_stack_words() + // extra push slots for MH adapters |
536 __ sll( Glocals_size, Interpreter::logStackElementSize, Glocals_size ); | 536 __ sll( Glocals_size, Interpreter::logStackElementSize, Glocals_size ); |
537 | 537 |
538 // see if the frame is greater than one page in size. If so, | 538 // see if the frame is greater than one page in size. If so, |
539 // then we need to verify there is enough stack space remaining | 539 // then we need to verify there is enough stack space remaining |
540 // Frame_size = (max_stack + extra_space) * BytesPerWord; | 540 // Frame_size = (max_stack + extra_space) * BytesPerWord; |
541 __ lduh( max_stack, Gframe_size ); | 541 __ ld_ptr( constMethod, Gframe_size ); |
542 __ lduh( Gframe_size, in_bytes(ConstMethod::max_stack_offset()), Gframe_size ); | |
542 __ add( Gframe_size, extra_space, Gframe_size ); | 543 __ add( Gframe_size, extra_space, Gframe_size ); |
543 __ round_to( Gframe_size, WordsPerLong ); | 544 __ round_to( Gframe_size, WordsPerLong ); |
544 __ sll( Gframe_size, Interpreter::logStackElementSize, Gframe_size); | 545 __ sll( Gframe_size, Interpreter::logStackElementSize, Gframe_size); |
545 | 546 |
546 // Add in java locals size for stack overflow check only | 547 // Add in java locals size for stack overflow check only |