コード例 #1
0
ファイル: blockOop.cpp プロジェクト: ardeujho/self
frame* blockOopClass::scope(bool orNone) {
  UsedOnlyInAssert(orNone);
  blockOopClass *b= addr();
  frame* f= b->homeFr();
  if (NLRSupport::is_bad_home_reference((char*)f)) {
    // prototype block or non-LIFO block
    f = NULL;
  }
  assert(f || orNone, "blockMap::scope: block is dead");
  return f;
}
コード例 #2
0
ファイル: nlrSupport.cpp プロジェクト: AdamSpitz/self
volatile void NLRSupport::continue_NLR_into_compiled_Self(bool remove_patches, frame* vmf) {
  reset_have_NLR_through_C(); // normally clear this when resuming NLR in compiled code
  char* ret_addr = vmf->sender()->real_return_addr();
  char* vm_addr  = vmf->return_addr();
  assert(!remove_patches || (ret_addr == vmf->sender()->return_addr() &&
                              vm_addr == vmf->real_return_addr()),
         "patches not removed");
  UsedOnlyInAssert(remove_patches);
  // Need to use two different ways to return:
  // 1) if VM was called through a normal Self inline cache (i.e. lookup)
  // 2)  "  "  "    "       "    " stack ovfl test or other primitive
  // This is because the "prim call inline cache" has a different format.
  // On SPARC, the return pointer is increased at a prim call site so a normal return
  // will skip in the inline cache.
  // All lookup routines are between Low- and HighReturnAddress.
  
  // On PPC, is_Self_IC flag ignored, and do not have to put lookup routines
  // between Low and HighReturnAddress.
  bool is_Self_IC = is_Self_return_address(vm_addr);  
  ContinueNLRFromC(ret_addr, false, is_Self_IC);
  ShouldNotReachHere(); // should not return to here
}