Mercurial > hg > truffle
comparison src/cpu/x86/vm/interpreter_x86_64.cpp @ 1108:85f13cdfbc1d
6829192: JSR 292 needs to support 64-bit x86
Summary: changes for method handles and invokedynamic
Reviewed-by: kvn
author | twisti |
---|---|
date | Wed, 16 Dec 2009 12:48:04 +0100 |
parents | e5b0439ef4ae |
children | c18cbe5936b8 |
comparison
equal
deleted
inserted
replaced
1102:6dc5471e0f66 | 1108:85f13cdfbc1d |
---|---|
275 // r13: sender SP | 275 // r13: sender SP |
276 | 276 |
277 address entry_point = __ pc(); | 277 address entry_point = __ pc(); |
278 | 278 |
279 // abstract method entry | 279 // abstract method entry |
280 // remove return address. Not really needed, since exception | 280 |
281 // handling throws away expression stack | 281 // pop return address, reset last_sp to NULL |
282 __ pop(rbx); | 282 __ empty_expression_stack(); |
283 | 283 __ restore_bcp(); // rsi must be correct for exception handler (was destroyed) |
284 // adjust stack to what a normal return would do | 284 __ restore_locals(); // make sure locals pointer is correct as well (was destroyed) |
285 __ mov(rsp, r13); | |
286 | 285 |
287 // throw exception | 286 // throw exception |
288 __ call_VM(noreg, CAST_FROM_FN_PTR(address, | 287 __ call_VM(noreg, CAST_FROM_FN_PTR(address, |
289 InterpreterRuntime::throw_AbstractMethodError)); | 288 InterpreterRuntime::throw_AbstractMethodError)); |
290 // the call_VM checks for exception, so we should never return here. | 289 // the call_VM checks for exception, so we should never return here. |
298 // Dispatch a method of the form java.dyn.MethodHandles::invoke(...) | 297 // Dispatch a method of the form java.dyn.MethodHandles::invoke(...) |
299 address InterpreterGenerator::generate_method_handle_entry(void) { | 298 address InterpreterGenerator::generate_method_handle_entry(void) { |
300 if (!EnableMethodHandles) { | 299 if (!EnableMethodHandles) { |
301 return generate_abstract_entry(); | 300 return generate_abstract_entry(); |
302 } | 301 } |
303 return generate_abstract_entry(); //6815692// | 302 |
303 address entry_point = MethodHandles::generate_method_handle_interpreter_entry(_masm); | |
304 | |
305 return entry_point; | |
304 } | 306 } |
305 | 307 |
306 | 308 |
307 // Empty method, generate a very fast return. | 309 // Empty method, generate a very fast return. |
308 | 310 |