aboutsummaryrefslogtreecommitdiffstats
path: root/target-ppc/op_helper.c
diff options
context:
space:
mode:
authorj_mayer <j_mayer@c046a42c-6fe2-441c-8c8c-71466251a162>2007-09-17 08:21:54 +0000
committerj_mayer <j_mayer@c046a42c-6fe2-441c-8c8c-71466251a162>2007-09-17 08:21:54 +0000
commit3608160206ed55c35be916df0f5d43dccc183513 (patch)
tree0766f900d5635fb7c8b39bf0b9995f26eda55ffa /target-ppc/op_helper.c
parent3b46e6242767a2c770c0aba0a6595e9511623c92 (diff)
Coding style fixes in PowerPC related code (no functional change):
- avoid useless blanks at EOL. - avoid tabs. - fix wrapping lines on 80 chars terminals. - add missing ';' at macros EOL to avoid confusing auto-identers. - fix identation. - Remove historical macros in micro-ops (PARAM, SPARAM, PPC_OP, regs) git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3178 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'target-ppc/op_helper.c')
-rw-r--r--target-ppc/op_helper.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/target-ppc/op_helper.c b/target-ppc/op_helper.c
index 558a3dd70..e584e1c65 100644
--- a/target-ppc/op_helper.c
+++ b/target-ppc/op_helper.c
@@ -88,7 +88,7 @@ void do_store_cr (uint32_t mask)
{
int i, sh;
- for (i = 0, sh = 7; i < 8; i++, sh --) {
+ for (i = 0, sh = 7; i < 8; i++, sh--) {
if (mask & (1 << sh))
env->crf[i] = (T0 >> (sh * 4)) & 0xFUL;
}
@@ -216,8 +216,8 @@ static void add128 (uint64_t *plow, uint64_t *phigh, uint64_t a, uint64_t b)
static void neg128 (uint64_t *plow, uint64_t *phigh)
{
- *plow = ~ *plow;
- *phigh = ~ *phigh;
+ *plow = ~*plow;
+ *phigh = ~*phigh;
add128(plow, phigh, 1, 0);
}
@@ -258,6 +258,7 @@ void do_mul64 (uint64_t *plow, uint64_t *phigh)
static void imul64 (uint64_t *plow, uint64_t *phigh, int64_t a, int64_t b)
{
int sa, sb;
+
sa = (a < 0);
if (sa)
a = -a;
@@ -2493,14 +2494,14 @@ void do_4xx_tlbre_hi (void)
void do_4xx_tlbsx (void)
{
- T0 = ppcemb_tlb_search(env, T0);
+ T0 = ppcemb_tlb_search(env, T0, env->spr[SPR_40x_PID]);
}
void do_4xx_tlbsx_ (void)
{
int tmp = xer_ov;
- T0 = ppcemb_tlb_search(env, T0);
+ T0 = ppcemb_tlb_search(env, T0, env->spr[SPR_40x_PID]);
if (T0 != -1)
tmp |= 0x02;
env->crf[0] = tmp;