Port-mips archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Does umimplemnted insn emulation work in -current?



I wrote:

> > > - lw      a0, 0(a2)                       # a0 = coproc instruction
> > > + lw              a0, 4(a2)               # a0 = coproc instruction
>  :
> > I'll revert the above line in a few days if there is no objection.
> 
> The attached patch also fixes PR 35326 (FPU siginfo),

One more regression in fp.S:

Index: mips/fp.S
===================================================================
RCS file: /cvsroot/src/sys/arch/mips/mips/fp.S,v
retrieving revision 1.37
diff -u -p -r1.37 fp.S
--- mips/fp.S   14 Dec 2009 00:46:06 -0000      1.37
+++ mips/fp.S   29 Jan 2011 01:24:36 -0000
@@ -2529,6 +2532,8 @@ inexact_nobias_d:
        PTR_L   v0, L_PCB(MIPS_CURLWP)          # get pcb of current process
        #nop
        INT_S   a2, PCB_FPREGS+FRAME_FSR(v0)
+#else
+       ctc1    a2, MIPS_FPU_CSR                # save exceptions
 #endif
        b       done

 
Now all tests in src/tests/lib/libc/ieeefp are passed
on R4400 ews4800mips and R5000 sgimips.

As I noted in PR 35326, it looks FP underflow in mul.s and mul.d
instructions triggers MIPS_FPU_EXCEPTION_UNIMPL instead of
MIPS_FPU_EXCEPTION_UNDERFLOW, and that's the reason why
ieeefp tests are affected by MachEmulateFP() implementation
even on machines that have the real FP unit.
(at least on R4400/R5000/Rm5230)

---
Izumi Tsutsui


Home | Main Index | Thread Index | Old Index