src/share/vm/interpreter/interpreterRuntime.cpp

changeset 7419
d3f3f7677537
parent 7181
134f18d0174b
child 7535
7ae4e26cb1e0
child 7600
cae03a88934b
     1.1 --- a/src/share/vm/interpreter/interpreterRuntime.cpp	Thu Dec 11 10:38:17 2014 +0000
     1.2 +++ b/src/share/vm/interpreter/interpreterRuntime.cpp	Tue Nov 25 17:33:59 2014 +0100
     1.3 @@ -398,6 +398,18 @@
     1.4    int                handler_bci;
     1.5    int                current_bci = bci(thread);
     1.6  
     1.7 +  if (thread->frames_to_pop_failed_realloc() > 0) {
     1.8 +    // Allocation of scalar replaced object used in this frame
     1.9 +    // failed. Unconditionally pop the frame.
    1.10 +    thread->dec_frames_to_pop_failed_realloc();
    1.11 +    thread->set_vm_result(h_exception());
    1.12 +    // If the method is synchronized we already unlocked the monitor
    1.13 +    // during deoptimization so the interpreter needs to skip it when
    1.14 +    // the frame is popped.
    1.15 +    thread->set_do_not_unlock_if_synchronized(true);
    1.16 +    return Interpreter::remove_activation_entry();
    1.17 +  }
    1.18 +
    1.19    // Need to do this check first since when _do_not_unlock_if_synchronized
    1.20    // is set, we don't want to trigger any classloading which may make calls
    1.21    // into java, or surprisingly find a matching exception handler for bci 0

mercurial