Discussion:
NetBSD-9 on 80486?
(too old to reply)
John Klos
2021-07-30 00:14:16 UTC
Permalink
Hi,

I'm trying to boot NetBSD-9 on an ISA system with a Cyrix 486DLC. The
system boots NetBSD 4.0.1 just fine:

https://www.klos.com/~john/dmesg_cyrix_4.0.1

I've compiled a NetBSD-9 LEGACY kernel as well as a custom kernel without
ACPI (also tried COPTS="-march=i486"), but all kernels I try to boot
(using the 4.0.1 bootloader) hang right after they finish loading:

5451728+95136+670816 [429136+342778]=0x6aac58
(hangs)

I know gcc, and therefore NetBSD, stopped supporting 80386 CPUs due to the
lack of certain atomic instructions, but I thought 80486 CPUs were still
supported.

I also tried NetBSD 5, 6 and 7 kernels, but they do the same thing. It
seems that "vga0 at isa?" was removed before NetBSD 8, so I'd expect them
to work.

Any ideas?

John Klos

--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-***@muc.de
Rin Okuyama
2021-07-30 01:37:49 UTC
Permalink
Hi,

NetBSD requires 486 instructions *and* x87 FPU; MATH_EMULATE option
was removed back in 2008 before 5.0 was released:

http://cvsweb.netbsd.org/bsdweb.cgi/src/sys/arch/i386/i386/Attic/math_emulate.c?hideattic=0

According to Wikipedia, Cx486DLC lacks internal FPU. This should be
why it does not work. Does the system have slot for external FPU?

Thanks,
rin
Post by John Klos
Hi,
https://www.klos.com/~john/dmesg_cyrix_4.0.1
5451728+95136+670816 [429136+342778]=0x6aac58
(hangs)
I know gcc, and therefore NetBSD, stopped supporting 80386 CPUs due to the lack of certain atomic instructions, but I thought 80486 CPUs were still supported.
I also tried NetBSD 5, 6 and 7 kernels, but they do the same thing. It seems that "vga0 at isa?" was removed before NetBSD 8, so I'd expect them to work.
Any ideas?
John Klos
--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-***@muc.de
John Klos
2021-07-30 02:21:25 UTC
Permalink
Hi,
Post by Rin Okuyama
NetBSD requires 486 instructions *and* x87 FPU; MATH_EMULATE option
http://cvsweb.netbsd.org/bsdweb.cgi/src/sys/arch/i386/i386/Attic/math_emulate.c?hideattic=0
According to Wikipedia, Cx486DLC lacks internal FPU. This should be
why it does not work. Does the system have slot for external FPU?
The board has an FPU installed (ULSI "DX/DLC"), and even though the dmesg
doesn't show it, NetBSD makes use of it as evidenced by
pkgsrc/benchmarks/flops, plus sysctl gives machdep.fpu_present = 1.

Hmmm...

John



--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-***@muc.de
Rin Okuyama
2021-07-30 02:49:05 UTC
Permalink
Hi,
Post by Rin Okuyama
NetBSD requires 486 instructions *and* x87 FPU; MATH_EMULATE option
http://cvsweb.netbsd.org/bsdweb.cgi/src/sys/arch/i386/i386/Attic/math_emulate.c?hideattic=0
According to Wikipedia, Cx486DLC lacks internal FPU. This should be
why it does not work. Does the system have slot for external FPU?
The board has an FPU installed (ULSI "DX/DLC"), and even though the dmesg doesn't show it, NetBSD makes use of it as evidenced by pkgsrc/benchmarks/flops, plus sysctl gives machdep.fpu_present = 1.
Hmmm...
Hmm, NetBSD 5.0 is the first release after i386 support was removed:

http://gnats.netbsd.org/36163

Cx486DLC may not fully support i486 instructions. Linux seems to drop
its support along with i386:

https://lkml.org/lkml/2012/12/11/131

Thanks,
rin

--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-***@muc.de
John Klos
2021-07-30 16:17:25 UTC
Permalink
I renamed the subject since this may be an issue with the 486DLC, but not
with 80486 in general.
Post by Rin Okuyama
http://gnats.netbsd.org/36163
Cx486DLC may not fully support i486 instructions. Linux seems to drop
https://lkml.org/lkml/2012/12/11/131
The Cyrix and TI 486DLC support the atomic operations of the Intel 80486,
according to their datasheets, although I'm not

"The LOCK prefix can be used with the following instructions:
Bit Test Instructions (BTS, BTR, BTC)
Exchange Instructions (XADD, XCHG, CMPXCHG)
One-operand Arithmetic and Logical Instructions
(DEC, INC, NEG, NOT)
Two-operand Arithmetic and Logical Instructions
(ADC, ADD, AND, OR, SBB, SUB, XOR)."

Now I can't help but wonder what else might've changed... I'll keep trying
different things.

Thanks!
John

--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-***@muc.de
John Klos
2021-08-02 18:34:53 UTC
Permalink
Hello, Ben,
I have NetBSD 4 installed on an Intel 486, and it works well. I recall
about 5 years ago trying to install 6.1.4 on it as well, but I don't think
I was even able to boot. I'll try a newer version and see what happens.
I see you have 32MB of memory, which I have run 7 generic on before
(different CPU though).
Is yours an 80486SX or DX? That's one issue. I've seen dmesgs from true
80486 systems (the 486DLC is a 486-class CPU made to work in an 80386
socket), like so:

https://dmesgd.nycbug.org/index.cgi?do=view&id=5832

I expect you'd need more than 16 megs just to boot, considering the size
of a GENERIC kernel. Paired down, 16 megs should be plenty. I'm running
NetBSD 9.2 on an m68030 system with just 10 megs :)

Thanks,
John

--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-***@muc.de
ben bisel
2021-08-02 17:43:14 UTC
Permalink
John,

I have NetBSD 4 installed on an Intel 486, and it works well. I recall
about 5 years ago trying to install 6.1.4 on it as well, but I don't think
I was even able to boot. I'll try a newer version and see what happens.
I see you have 32MB of memory, which I have run 7 generic on before
(different CPU though).

Ben
Post by John Klos
I renamed the subject since this may be an issue with the 486DLC, but not
with 80486 in general.
Post by Rin Okuyama
http://gnats.netbsd.org/36163
Cx486DLC may not fully support i486 instructions. Linux seems to drop
https://lkml.org/lkml/2012/12/11/131
The Cyrix and TI 486DLC support the atomic operations of the Intel 80486,
according to their datasheets, although I'm not
Bit Test Instructions (BTS, BTR, BTC)
Exchange Instructions (XADD, XCHG, CMPXCHG)
One-operand Arithmetic and Logical Instructions
(DEC, INC, NEG, NOT)
Two-operand Arithmetic and Logical Instructions
(ADC, ADD, AND, OR, SBB, SUB, XOR)."
Now I can't help but wonder what else might've changed... I'll keep trying
different things.
Thanks!
John
Loading...