diff options
author | aurel32 <aurel32@c046a42c-6fe2-441c-8c8c-71466251a162> | 2008-11-24 11:28:19 +0000 |
---|---|---|
committer | aurel32 <aurel32@c046a42c-6fe2-441c-8c8c-71466251a162> | 2008-11-24 11:28:19 +0000 |
commit | cab3bee2d6f1d6eb6ad74006b8a63562cda9ba4d (patch) | |
tree | 6c874d4b6f4a80c682e87ceaa31a326513e9ba2b /target-ppc/op_helper.c | |
parent | fe1e5c53fdd4e07fd217077dc6e03ad7d01d9839 (diff) |
target-ppc: convert trap instructions to TCG
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5788 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'target-ppc/op_helper.c')
-rw-r--r-- | target-ppc/op_helper.c | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/target-ppc/op_helper.c b/target-ppc/op_helper.c index fd36423854..6addc7429a 100644 --- a/target-ppc/op_helper.c +++ b/target-ppc/op_helper.c @@ -1424,25 +1424,25 @@ void do_hrfid (void) #endif #endif -void do_tw (int flags) +void helper_tw (target_ulong arg1, target_ulong arg2, uint32_t flags) { - if (!likely(!(((int32_t)T0 < (int32_t)T1 && (flags & 0x10)) || - ((int32_t)T0 > (int32_t)T1 && (flags & 0x08)) || - ((int32_t)T0 == (int32_t)T1 && (flags & 0x04)) || - ((uint32_t)T0 < (uint32_t)T1 && (flags & 0x02)) || - ((uint32_t)T0 > (uint32_t)T1 && (flags & 0x01))))) { + if (!likely(!(((int32_t)arg1 < (int32_t)arg2 && (flags & 0x10)) || + ((int32_t)arg1 > (int32_t)arg2 && (flags & 0x08)) || + ((int32_t)arg1 == (int32_t)arg2 && (flags & 0x04)) || + ((uint32_t)arg1 < (uint32_t)arg2 && (flags & 0x02)) || + ((uint32_t)arg1 > (uint32_t)arg2 && (flags & 0x01))))) { raise_exception_err(env, POWERPC_EXCP_PROGRAM, POWERPC_EXCP_TRAP); } } #if defined(TARGET_PPC64) -void do_td (int flags) +void helper_td (target_ulong arg1, target_ulong arg2, uint32_t flags) { - if (!likely(!(((int64_t)T0 < (int64_t)T1 && (flags & 0x10)) || - ((int64_t)T0 > (int64_t)T1 && (flags & 0x08)) || - ((int64_t)T0 == (int64_t)T1 && (flags & 0x04)) || - ((uint64_t)T0 < (uint64_t)T1 && (flags & 0x02)) || - ((uint64_t)T0 > (uint64_t)T1 && (flags & 0x01))))) + if (!likely(!(((int64_t)arg1 < (int64_t)arg2 && (flags & 0x10)) || + ((int64_t)arg1 > (int64_t)arg2 && (flags & 0x08)) || + ((int64_t)arg1 == (int64_t)arg2 && (flags & 0x04)) || + ((uint64_t)arg1 < (uint64_t)arg2 && (flags & 0x02)) || + ((uint64_t)arg1 > (uint64_t)arg2 && (flags & 0x01))))) raise_exception_err(env, POWERPC_EXCP_PROGRAM, POWERPC_EXCP_TRAP); } #endif |