Mercurial > hg > truffle
comparison src/share/vm/oops/method.hpp @ 7458:4daebd4cc1dd
Merge
author | minqi |
---|---|
date | Mon, 24 Dec 2012 11:46:38 -0800 |
parents | 35431a769282 fd74228fd5ca |
children | ade95d680b42 |
comparison
equal
deleted
inserted
replaced
7457:35431a769282 | 7458:4daebd4cc1dd |
---|---|
71 // | access_flags | | 71 // | access_flags | |
72 // | vtable_index | | 72 // | vtable_index | |
73 // |------------------------------------------------------| | 73 // |------------------------------------------------------| |
74 // | result_index (C++ interpreter only) | | 74 // | result_index (C++ interpreter only) | |
75 // |------------------------------------------------------| | 75 // |------------------------------------------------------| |
76 // | method_size | max_locals | | 76 // | method_size | intrinsic_id| flags | |
77 // | size_of_parameters | intrinsic_id| flags | | |
78 // |------------------------------------------------------| | 77 // |------------------------------------------------------| |
79 // | throwout_count | num_breakpoints | | 78 // | throwout_count | num_breakpoints | |
80 // |------------------------------------------------------| | 79 // |------------------------------------------------------| |
81 // | invocation_counter | | 80 // | invocation_counter | |
82 // | backedge_counter | | 81 // | backedge_counter | |
114 // note: can have vtables with >2**16 elements (because of inheritance) | 113 // note: can have vtables with >2**16 elements (because of inheritance) |
115 #ifdef CC_INTERP | 114 #ifdef CC_INTERP |
116 int _result_index; // C++ interpreter needs for converting results to/from stack | 115 int _result_index; // C++ interpreter needs for converting results to/from stack |
117 #endif | 116 #endif |
118 u2 _method_size; // size of this object | 117 u2 _method_size; // size of this object |
119 u2 _max_locals; // Number of local variables used by this method | |
120 u2 _size_of_parameters; // size of the parameter block (receiver + arguments) in words | |
121 u1 _intrinsic_id; // vmSymbols::intrinsic_id (0 == _none) | 118 u1 _intrinsic_id; // vmSymbols::intrinsic_id (0 == _none) |
122 u1 _jfr_towrite : 1, // Flags | 119 u1 _jfr_towrite : 1, // Flags |
123 _force_inline : 1, | 120 _force_inline : 1, |
124 _hidden : 1, | 121 _hidden : 1, |
125 _dont_inline : 1, | 122 _dont_inline : 1, |
297 int verifier_max_stack() const { return constMethod()->max_stack(); } | 294 int verifier_max_stack() const { return constMethod()->max_stack(); } |
298 int max_stack() const { return constMethod()->max_stack() + extra_stack_entries(); } | 295 int max_stack() const { return constMethod()->max_stack() + extra_stack_entries(); } |
299 void set_max_stack(int size) { constMethod()->set_max_stack(size); } | 296 void set_max_stack(int size) { constMethod()->set_max_stack(size); } |
300 | 297 |
301 // max locals | 298 // max locals |
302 int max_locals() const { return _max_locals; } | 299 int max_locals() const { return constMethod()->max_locals(); } |
303 void set_max_locals(int size) { _max_locals = size; } | 300 void set_max_locals(int size) { constMethod()->set_max_locals(size); } |
304 | 301 |
305 int highest_comp_level() const; | 302 int highest_comp_level() const; |
306 void set_highest_comp_level(int level); | 303 void set_highest_comp_level(int level); |
307 int highest_osr_comp_level() const; | 304 int highest_osr_comp_level() const; |
308 void set_highest_osr_comp_level(int level); | 305 void set_highest_osr_comp_level(int level); |
316 | 313 |
317 int interpreter_throwout_count() const { return _interpreter_throwout_count; } | 314 int interpreter_throwout_count() const { return _interpreter_throwout_count; } |
318 void set_interpreter_throwout_count(int count) { _interpreter_throwout_count = count; } | 315 void set_interpreter_throwout_count(int count) { _interpreter_throwout_count = count; } |
319 | 316 |
320 // size of parameters | 317 // size of parameters |
321 int size_of_parameters() const { return _size_of_parameters; } | 318 int size_of_parameters() const { return constMethod()->size_of_parameters(); } |
319 void set_size_of_parameters(int size) { constMethod()->set_size_of_parameters(size); } | |
322 | 320 |
323 bool has_stackmap_table() const { | 321 bool has_stackmap_table() const { |
324 return constMethod()->has_stackmap_table(); | 322 return constMethod()->has_stackmap_table(); |
325 } | 323 } |
326 | 324 |
593 static ByteSize const_offset() { return byte_offset_of(Method, _constMethod ); } | 591 static ByteSize const_offset() { return byte_offset_of(Method, _constMethod ); } |
594 static ByteSize access_flags_offset() { return byte_offset_of(Method, _access_flags ); } | 592 static ByteSize access_flags_offset() { return byte_offset_of(Method, _access_flags ); } |
595 #ifdef CC_INTERP | 593 #ifdef CC_INTERP |
596 static ByteSize result_index_offset() { return byte_offset_of(Method, _result_index ); } | 594 static ByteSize result_index_offset() { return byte_offset_of(Method, _result_index ); } |
597 #endif /* CC_INTERP */ | 595 #endif /* CC_INTERP */ |
598 static ByteSize size_of_locals_offset() { return byte_offset_of(Method, _max_locals ); } | |
599 static ByteSize size_of_parameters_offset() { return byte_offset_of(Method, _size_of_parameters); } | |
600 static ByteSize from_compiled_offset() { return byte_offset_of(Method, _from_compiled_entry); } | 596 static ByteSize from_compiled_offset() { return byte_offset_of(Method, _from_compiled_entry); } |
601 static ByteSize code_offset() { return byte_offset_of(Method, _code); } | 597 static ByteSize code_offset() { return byte_offset_of(Method, _code); } |
602 static ByteSize invocation_counter_offset() { return byte_offset_of(Method, _invocation_counter); } | 598 static ByteSize invocation_counter_offset() { return byte_offset_of(Method, _invocation_counter); } |
603 static ByteSize backedge_counter_offset() { return byte_offset_of(Method, _backedge_counter); } | 599 static ByteSize backedge_counter_offset() { return byte_offset_of(Method, _backedge_counter); } |
604 static ByteSize method_data_offset() { | 600 static ByteSize method_data_offset() { |
801 Array<AnnotationArray*>* methods_annotations, | 797 Array<AnnotationArray*>* methods_annotations, |
802 Array<AnnotationArray*>* methods_parameter_annotations, | 798 Array<AnnotationArray*>* methods_parameter_annotations, |
803 Array<AnnotationArray*>* methods_default_annotations, | 799 Array<AnnotationArray*>* methods_default_annotations, |
804 Array<AnnotationArray*>* methods_type_annotations, | 800 Array<AnnotationArray*>* methods_type_annotations, |
805 bool idempotent = false); | 801 bool idempotent = false); |
806 | |
807 // size of parameters | |
808 void set_size_of_parameters(int size) { _size_of_parameters = size; } | |
809 | 802 |
810 // Deallocation function for redefine classes or if an error occurs | 803 // Deallocation function for redefine classes or if an error occurs |
811 void deallocate_contents(ClassLoaderData* loader_data); | 804 void deallocate_contents(ClassLoaderData* loader_data); |
812 | 805 |
813 // Printing | 806 // Printing |