226 // runtime calls (for example, used to allocate new objects/arrays |
226 // runtime calls (for example, used to allocate new objects/arrays |
227 // on slow code path) and any other calls generated in compiled code. |
227 // on slow code path) and any other calls generated in compiled code. |
228 // It is not guaranteed that we can get such information here only |
228 // It is not guaranteed that we can get such information here only |
229 // by analyzing bytecode in deoptimized frames. This is why this flag |
229 // by analyzing bytecode in deoptimized frames. This is why this flag |
230 // is set during method compilation (see Compile::Process_OopMap_Node()). |
230 // is set during method compilation (see Compile::Process_OopMap_Node()). |
231 bool save_oop_result = chunk->at(0)->scope()->return_oop(); |
231 // If the previous frame was popped, we don't have a result. |
|
232 bool save_oop_result = chunk->at(0)->scope()->return_oop() && !thread->popframe_forcing_deopt_reexecution(); |
232 Handle return_value; |
233 Handle return_value; |
233 if (save_oop_result) { |
234 if (save_oop_result) { |
234 // Reallocation may trigger GC. If deoptimization happened on return from |
235 // Reallocation may trigger GC. If deoptimization happened on return from |
235 // call which returns oop we need to save it since it is not in oopmap. |
236 // call which returns oop we need to save it since it is not in oopmap. |
236 oop result = deoptee.saved_oop_result(&map); |
237 oop result = deoptee.saved_oop_result(&map); |