Mercurial > hg > truffle
comparison src/share/vm/interpreter/bytecodeInterpreter.cpp @ 1078:8e7adf982378
6896043: first round of zero fixes
Reviewed-by: kvn
Contributed-by: Gary Benson <gbenson@redhat.com>
author | twisti |
---|---|
date | Fri, 27 Nov 2009 07:56:58 -0800 |
parents | 354d3184f6b2 |
children | f61d795ce6de |
comparison
equal
deleted
inserted
replaced
1073:de44705e6b33 | 1078:8e7adf982378 |
---|---|
279 // skip is delta from current bcp/bci for target, branch_pc is pre-branch bcp | 279 // skip is delta from current bcp/bci for target, branch_pc is pre-branch bcp |
280 | 280 |
281 | 281 |
282 #define DO_BACKEDGE_CHECKS(skip, branch_pc) \ | 282 #define DO_BACKEDGE_CHECKS(skip, branch_pc) \ |
283 if ((skip) <= 0) { \ | 283 if ((skip) <= 0) { \ |
284 if (UseCompiler && UseLoopCounter) { \ | 284 if (UseLoopCounter) { \ |
285 bool do_OSR = UseOnStackReplacement; \ | 285 bool do_OSR = UseOnStackReplacement; \ |
286 BACKEDGE_COUNT->increment(); \ | 286 BACKEDGE_COUNT->increment(); \ |
287 if (do_OSR) do_OSR = BACKEDGE_COUNT->reached_InvocationLimit(); \ | 287 if (do_OSR) do_OSR = BACKEDGE_COUNT->reached_InvocationLimit(); \ |
288 if (do_OSR) { \ | 288 if (do_OSR) { \ |
289 nmethod* osr_nmethod; \ | 289 nmethod* osr_nmethod; \ |
290 OSR_REQUEST(osr_nmethod, branch_pc); \ | 290 OSR_REQUEST(osr_nmethod, branch_pc); \ |
291 if (osr_nmethod != NULL && osr_nmethod->osr_entry_bci() != InvalidOSREntryBci) { \ | 291 if (osr_nmethod != NULL && osr_nmethod->osr_entry_bci() != InvalidOSREntryBci) { \ |
292 intptr_t* buf; \ | 292 intptr_t* buf = SharedRuntime::OSR_migration_begin(THREAD); \ |
293 CALL_VM(buf=SharedRuntime::OSR_migration_begin(THREAD), handle_exception); \ | |
294 istate->set_msg(do_osr); \ | 293 istate->set_msg(do_osr); \ |
295 istate->set_osr_buf((address)buf); \ | 294 istate->set_osr_buf((address)buf); \ |
296 istate->set_osr_entry(osr_nmethod->osr_entry()); \ | 295 istate->set_osr_entry(osr_nmethod->osr_entry()); \ |
297 return; \ | 296 return; \ |
298 } \ | 297 } \ |
299 } else { \ | |
300 INCR_INVOCATION_COUNT; \ | |
301 SAFEPOINT; \ | |
302 } \ | 298 } \ |
303 } /* UseCompiler ... */ \ | 299 } /* UseCompiler ... */ \ |
304 INCR_INVOCATION_COUNT; \ | 300 INCR_INVOCATION_COUNT; \ |
305 SAFEPOINT; \ | 301 SAFEPOINT; \ |
306 } | 302 } |
1279 CASE(_f2d): /* convert top of stack float to double */ | 1275 CASE(_f2d): /* convert top of stack float to double */ |
1280 { | 1276 { |
1281 jfloat f; | 1277 jfloat f; |
1282 jdouble r; | 1278 jdouble r; |
1283 f = STACK_FLOAT(-1); | 1279 f = STACK_FLOAT(-1); |
1284 #ifdef IA64 | |
1285 // IA64 gcc bug | |
1286 r = ( f == 0.0f ) ? (jdouble) f : (jdouble) f + ia64_double_zero; | |
1287 #else | |
1288 r = (jdouble) f; | 1280 r = (jdouble) f; |
1289 #endif | |
1290 MORE_STACK(-1); // POP | 1281 MORE_STACK(-1); // POP |
1291 SET_STACK_DOUBLE(r, 1); | 1282 SET_STACK_DOUBLE(r, 1); |
1292 UPDATE_PC_AND_TOS_AND_CONTINUE(1, 2); | 1283 UPDATE_PC_AND_TOS_AND_CONTINUE(1, 2); |
1293 } | 1284 } |
1294 | 1285 |