< prev index next >

src/hotspot/share/runtime/vframeArray.cpp

Print this page
*** 85,21 ***
  
        // Allocate monitor chunk
        _monitors = new MonitorChunk(list->length());
        vf->thread()->add_monitor_chunk(_monitors);
  
!       // Migrate the BasicLocks from the stack to the monitor chunk
        for (index = 0; index < list->length(); index++) {
          MonitorInfo* monitor = list->at(index);
          assert(!monitor->owner_is_scalar_replaced() || realloc_failures, "object should be reallocated already");
          BasicObjectLock* dest = _monitors->at(index);
          if (monitor->owner_is_scalar_replaced()) {
            dest->set_obj(NULL);
          } else {
            assert(monitor->owner() == NULL || !monitor->owner()->is_unlocked(), "object must be null or locked");
            dest->set_obj(monitor->owner());
-           monitor->lock()->move_to(monitor->owner(), dest->lock());
          }
        }
      }
    }
  
--- 85,20 ---
  
        // Allocate monitor chunk
        _monitors = new MonitorChunk(list->length());
        vf->thread()->add_monitor_chunk(_monitors);
  
!       // Migrate the BasicObjectLocks from the stack to the monitor chunk
        for (index = 0; index < list->length(); index++) {
          MonitorInfo* monitor = list->at(index);
          assert(!monitor->owner_is_scalar_replaced() || realloc_failures, "object should be reallocated already");
          BasicObjectLock* dest = _monitors->at(index);
          if (monitor->owner_is_scalar_replaced()) {
            dest->set_obj(NULL);
          } else {
            assert(monitor->owner() == NULL || !monitor->owner()->is_unlocked(), "object must be null or locked");
            dest->set_obj(monitor->owner());
          }
        }
      }
    }
  

*** 306,11 ***
    BasicObjectLock* top = iframe()->interpreter_frame_monitor_begin();
    for (int index = 0; index < locks; index++) {
      top = iframe()->previous_monitor_in_interpreter_frame(top);
      BasicObjectLock* src = _monitors->at(index);
      top->set_obj(src->obj());
-     src->lock()->move_to(src->obj(), top->lock());
    }
    if (ProfileInterpreter) {
      iframe()->interpreter_frame_set_mdp(0); // clear out the mdp.
    }
    iframe()->interpreter_frame_set_bcp(bcp);
--- 305,10 ---
< prev index next >