comparison src/cpu/x86/vm/frame_x86.inline.hpp @ 1137:97125851f396

6829187: compiler optimizations required for JSR 292 Summary: C2 implementation for invokedynamic support. Reviewed-by: kvn, never
author twisti
date Tue, 05 Jan 2010 13:05:58 +0100
parents 0fbdb4381b99
children ba263cfb7611
comparison
equal deleted inserted replaced
1136:4b84186a8248 1137:97125851f396
223 } 223 }
224 224
225 // top of expression stack 225 // top of expression stack
226 inline intptr_t* frame::interpreter_frame_tos_address() const { 226 inline intptr_t* frame::interpreter_frame_tos_address() const {
227 intptr_t* last_sp = interpreter_frame_last_sp(); 227 intptr_t* last_sp = interpreter_frame_last_sp();
228 if (last_sp == NULL ) { 228 if (last_sp == NULL) {
229 return sp(); 229 return sp();
230 } else { 230 } else {
231 // sp() may have been extended by an adapter 231 // sp() may have been extended or shrunk by an adapter. At least
232 assert(last_sp < fp() && last_sp >= sp(), "bad tos"); 232 // check that we don't fall behind the legal region.
233 assert(last_sp < (intptr_t*) interpreter_frame_monitor_begin(), "bad tos");
233 return last_sp; 234 return last_sp;
234 } 235 }
235 } 236 }
236 237
237 #endif /* CC_INTERP */ 238 #endif /* CC_INTERP */