138 void CompiledRFrame::init() {
139 RegisterMap map(thread(), false);
140 vframe* vf = vframe::new_vframe(&_fr, &map, thread());
141 assert(vf->is_compiled_frame(), "must be compiled");
142 _nm = compiledVFrame::cast(vf)->code();
143 vf = vf->top();
144 _vf = javaVFrame::cast(vf);
145 _method = CodeCache::find_nmethod(_fr.pc())->method();
146 assert(_method, "should have found a method");
147 #ifndef PRODUCT
148 _invocations = _method->compiled_invocation_count();
149 #endif
150 }
151
152 void InterpretedRFrame::init() {
153 _invocations = _method->invocation_count() + _method->backedge_count();
154 }
155
156 void RFrame::print(const char* kind) {
157 #ifndef PRODUCT
158 #ifdef COMPILER2
159 int cnt = top_method()->interpreter_invocation_count();
160 #else
161 int cnt = top_method()->invocation_count();
162 #endif
163 tty->print("%3d %s ", _num, is_interpreted() ? "I" : "C");
164 top_method()->print_short_name(tty);
165 tty->print_cr(": inv=%5d(%d) cst=%4d", _invocations, cnt, cost());
166 #endif
167 }
168
169 void CompiledRFrame::print() {
170 RFrame::print("comp");
171 }
172
173 void InterpretedRFrame::print() {
174 RFrame::print("int.");
175 }
176
177 void DeoptimizedRFrame::print() {
178 RFrame::print("deopt.");
|
138 void CompiledRFrame::init() {
139 RegisterMap map(thread(), false);
140 vframe* vf = vframe::new_vframe(&_fr, &map, thread());
141 assert(vf->is_compiled_frame(), "must be compiled");
142 _nm = compiledVFrame::cast(vf)->code();
143 vf = vf->top();
144 _vf = javaVFrame::cast(vf);
145 _method = CodeCache::find_nmethod(_fr.pc())->method();
146 assert(_method, "should have found a method");
147 #ifndef PRODUCT
148 _invocations = _method->compiled_invocation_count();
149 #endif
150 }
151
152 void InterpretedRFrame::init() {
153 _invocations = _method->invocation_count() + _method->backedge_count();
154 }
155
156 void RFrame::print(const char* kind) {
157 #ifndef PRODUCT
158 #if defined(COMPILER2) || INCLUDE_JVMCI
159 int cnt = top_method()->interpreter_invocation_count();
160 #else
161 int cnt = top_method()->invocation_count();
162 #endif
163 tty->print("%3d %s ", _num, is_interpreted() ? "I" : "C");
164 top_method()->print_short_name(tty);
165 tty->print_cr(": inv=%5d(%d) cst=%4d", _invocations, cnt, cost());
166 #endif
167 }
168
169 void CompiledRFrame::print() {
170 RFrame::print("comp");
171 }
172
173 void InterpretedRFrame::print() {
174 RFrame::print("int.");
175 }
176
177 void DeoptimizedRFrame::print() {
178 RFrame::print("deopt.");
|