1.1 --- a/src/share/vm/runtime/deoptimization.cpp Wed Aug 11 01:17:27 2010 -0700 1.2 +++ b/src/share/vm/runtime/deoptimization.cpp Wed Aug 11 05:51:21 2010 -0700 1.3 @@ -254,6 +254,7 @@ 1.4 1.5 } 1.6 1.7 +#ifndef SHARK 1.8 // Compute the caller frame based on the sender sp of stub_frame and stored frame sizes info. 1.9 CodeBlob* cb = stub_frame.cb(); 1.10 // Verify we have the right vframeArray 1.11 @@ -270,6 +271,10 @@ 1.12 assert(cb->is_deoptimization_stub() || cb->is_uncommon_trap_stub(), "just checking"); 1.13 Events::log("fetch unroll sp " INTPTR_FORMAT, unpack_sp); 1.14 #endif 1.15 +#else 1.16 + intptr_t* unpack_sp = stub_frame.sender(&dummy_map).unextended_sp(); 1.17 +#endif // !SHARK 1.18 + 1.19 // This is a guarantee instead of an assert because if vframe doesn't match 1.20 // we will unpack the wrong deoptimized frame and wind up in strange places 1.21 // where it will be very difficult to figure out what went wrong. Better 1.22 @@ -380,7 +385,9 @@ 1.23 1.24 frame_pcs[0] = deopt_sender.raw_pc(); 1.25 1.26 +#ifndef SHARK 1.27 assert(CodeCache::find_blob_unsafe(frame_pcs[0]) != NULL, "bad pc"); 1.28 +#endif // SHARK 1.29 1.30 UnrollBlock* info = new UnrollBlock(array->frame_size() * BytesPerWord, 1.31 caller_adjustment * BytesPerWord, 1.32 @@ -1073,7 +1080,7 @@ 1.33 JRT_END 1.34 1.35 1.36 -#ifdef COMPILER2 1.37 +#if defined(COMPILER2) || defined(SHARK) 1.38 void Deoptimization::load_class_by_index(constantPoolHandle constant_pool, int index, TRAPS) { 1.39 // in case of an unresolved klass entry, load the class. 1.40 if (constant_pool->tag_at(index).is_unresolved_klass()) { 1.41 @@ -1835,7 +1842,7 @@ 1.42 if (xtty != NULL) xtty->tail("statistics"); 1.43 } 1.44 } 1.45 -#else // COMPILER2 1.46 +#else // COMPILER2 || SHARK 1.47 1.48 1.49 // Stubs for C1 only system. 1.50 @@ -1871,4 +1878,4 @@ 1.51 return buf; 1.52 } 1.53 1.54 -#endif // COMPILER2 1.55 +#endif // COMPILER2 || SHARK