NetBSD-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: port-mips/57680: printf("%.1f") shows wrong results on R3000mipseb
The following reply was made to PR port-mips/57680; it has been noted by GNATS.
From: Izumi Tsutsui <tsutsui%ceres.dti.ne.jp@localhost>
To: rvp%SDF.ORG@localhost
Cc: gnats-bugs%netbsd.org@localhost, tsutsui%ceres.dti.ne.jp@localhost
Subject: Re: port-mips/57680: printf("%.1f") shows wrong results on R3000mipseb
Date: Fri, 3 Nov 2023 20:38:45 +0900
> > Can you show the output of this program? (Instructions in source)
> >
> > ```
> > /**
> > * Little-Endian 32-bit:
> > * cc -I/usr/src/lib/libc/gdtoa/ -I/usr/src/lib/libc/arch/i386/gdtoa/ \
> > * -DDEBUG -DHonor_FLT_ROUNDS -DNO_LONG_LONG -o m \
> > * m.c /usr/src/lib/libc/gdtoa/dtoa.c /usr/src/lib/libc/gdtoa/dmisc.c
> > *
> > * Big-Endian 32-bit:
> > * cc -I/usr/src/lib/libc/gdtoa/ -I/usr/src/lib/libc/arch/mips/gdtoa/ \
> > * -DDEBUG -DHonor_FLT_ROUNDS -DNO_LONG_LONG -o m \
> > * m.c /usr/src/lib/libc/gdtoa/dtoa.c /usr/src/lib/libc/gdtoa/dmisc.c
> > */
>
> I have not tried this yet, but git bisect shows
Now I've tried it on both NWS-3470 (R3000 + R3010) and NWS-5000 (R4400):
On NWS-3470:
---
news3470-% cc -I/s/netbsd-9/src/lib/libc/gdtoa/ -I/s/netbsd-9/src/lib/libc/arch/mips/gdtoa/ -DDEBUG -DHonor_FLT_ROUNDS -DNO_LONG_LONG -o m m.c /s/netbsd-9/src/lib/libc/gdtoa/gdtoa.c /s/netbsd-9/src/lib/libc/gdtoa/dmisc.c
news3470-% ./m
.O
40490FD0
3.0
439D145A
?.0
44C45970
news3470-% grep ^cpu0 /var/run/dmesg.boot
cpu0 at mainbus0: MIPS R3000 CPU (0x220) Rev. 2.0 with MIPS R3010 FPC Rev. 2.0
cpu0: 64KB/4B direct-mapped Instruction cache, 64 TLB entries
cpu0: 64KB/4B direct-mapped write-through Data cache
news3470-%
---
On NWS-5000:
---
(copy the above "m" binary from NWS-3470)
news5000-% ./m
3.1
40490FD0
314.1
439D145A
1570.7
44C45970
news5000-% % grep ^cpu0 /var/run/dmesg.boot
cpu0 at mainbus0: MIPS R4400 CPU (0x450) Rev. 5.0 with MIPS R4010 FPC Rev. 0.0
cpu0: 48 TLB entries, 16MB max page size
cpu0: 16KB/16B direct-mapped L1 instruction cache
cpu0: 16KB/16B direct-mapped write-back L1 data cache
cpu0: 1024KB/64B direct-mapped write-back L2 unified cache
news5000-%
---
Izumi Tsutsui
Home |
Main Index |
Thread Index |
Old Index