Revision 8dd4983c target-ppc/translate.c
b/target-ppc/translate.c | ||
---|---|---|
1370 | 1370 |
gen_op_load_gpr_T0(ra); |
1371 | 1371 |
} |
1372 | 1372 |
gen_op_set_T1(nb); |
1373 |
/* NIP cannot be restored if the memory exception comes from an helper */ |
|
1374 |
gen_op_update_nip((ctx)->nip - 4); |
|
1373 | 1375 |
op_ldsts(lswi, start); |
1374 | 1376 |
} |
1375 | 1377 |
|
... | ... | |
1388 | 1390 |
gen_op_add(); |
1389 | 1391 |
} |
1390 | 1392 |
gen_op_load_xer_bc(); |
1393 |
/* NIP cannot be restored if the memory exception comes from an helper */ |
|
1394 |
gen_op_update_nip((ctx)->nip - 4); |
|
1391 | 1395 |
op_ldstsx(lswx, rD(ctx->opcode), ra, rb); |
1392 | 1396 |
} |
1393 | 1397 |
|
... | ... | |
1404 | 1408 |
if (nb == 0) |
1405 | 1409 |
nb = 32; |
1406 | 1410 |
gen_op_set_T1(nb); |
1411 |
/* NIP cannot be restored if the memory exception comes from an helper */ |
|
1412 |
gen_op_update_nip((ctx)->nip - 4); |
|
1407 | 1413 |
op_ldsts(stsw, rS(ctx->opcode)); |
1408 | 1414 |
} |
1409 | 1415 |
|
... | ... | |
1421 | 1427 |
gen_op_add(); |
1422 | 1428 |
} |
1423 | 1429 |
gen_op_load_xer_bc(); |
1430 |
/* NIP cannot be restored if the memory exception comes from an helper */ |
|
1431 |
gen_op_update_nip((ctx)->nip - 4); |
|
1424 | 1432 |
op_ldsts(stsw, rS(ctx->opcode)); |
1425 | 1433 |
} |
1426 | 1434 |
|
... | ... | |
2123 | 2131 |
} |
2124 | 2132 |
|
2125 | 2133 |
/* mtcrf */ |
2126 |
GEN_HANDLER(mtcrf, 0x1F, 0x10, 0x04, 0x00100801, PPC_MISC) |
|
2134 |
/* The mask should be 0x00100801, but Mac OS X 10.4 use an alternate form */ |
|
2135 |
GEN_HANDLER(mtcrf, 0x1F, 0x10, 0x04, 0x00000801, PPC_MISC) |
|
2127 | 2136 |
{ |
2128 | 2137 |
gen_op_load_gpr_T0(rS(ctx->opcode)); |
2129 | 2138 |
gen_op_store_cr(CRM(ctx->opcode)); |
... | ... | |
3312 | 3321 |
ctx.exception != EXCP_TRAP)) { |
3313 | 3322 |
RET_EXCP(ctxp, EXCP_TRACE, 0); |
3314 | 3323 |
} |
3324 |
if (ctx.exception != EXCP_NONE) |
|
3325 |
break; |
|
3315 | 3326 |
/* if we reach a page boundary, stop generation */ |
3316 | 3327 |
if ((ctx.nip & (TARGET_PAGE_SIZE - 1)) == 0) { |
3317 |
RET_EXCP(ctxp, EXCP_BRANCH, 0); |
|
3318 |
} |
|
3328 |
gen_op_b((long)ctx.tb, ctx.nip); |
|
3329 |
ctx.exception = EXCP_BRANCH; |
|
3330 |
break; |
|
3331 |
} |
|
3319 | 3332 |
} |
3320 | 3333 |
if (ctx.exception == EXCP_NONE) { |
3321 | 3334 |
gen_op_b((unsigned long)ctx.tb, ctx.nip); |
Also available in: Unified diff