Definicon DSI-32 co-processor emulation

Definicon DSI-32 coprocessor card

Well this is a little interesting thing.  Back in the 1980’s people were increasingly frustrated with the limitations of the 8086 processor in their IBM PC/XT computers, and wanted a way to get the latest & greatest 16 bit, and 32bit processors.  One such hot processor was the  National Semiconductor NS32032.

Enter the Definicon DSI-32 co-processor card.  It’s a simple 8bit ISA card containing the NS32032 processor, some memory an sockets for both a math co-processor, and a MMU.  The NS32032 is also somewhat infamous as being rather ‘VAX like’, and being difficult for compilers of the era to properly optimize for.  As mentioned in Michael Tiemann’s interview in the O’Riley book Open Sources .

The real bombshell came in June of 1987, when Stallman released the GNU C Compiler (GCC) Version 1.0. I downloaded it immediately, and I used all the tricks I’d read about in the Emacs and GDB manuals to quickly learn its 110,000 lines of code. Stallman’s compiler supported two platforms in its first release: the venerable VAX and the new Sun3 workstation. It handily generated better code on these platforms than the respective vendors’ compilers could muster. In two weeks, I had ported GCC to a new microprocessor (the 32032 from National Semiconductor), and the resulting port was 20% faster than the proprietary compiler supplied by National. With another two weeks of hacking, I had raised the delta to 40%. (It was often said that the reason the National chip faded from existence was because it was supposed to be a 1 MIPS chip, to compete with Motorola’s 68020, but when it was released, it only clocked .75 MIPS on application benchmarks. Note that 140% * 0.75 MIPS = 1.05 MIPS. How much did poor compiler technology cost National?) 

Such was the fate of the NS32032.  Getting back to the Definicon card, it has no real IO of it’s own, instead it relies on being able to copy memory in and out of a window to program the CPU, much like how LIM EMS stores more than 64kb onto a card.  MS-DOS provides all the I/O operations though a simple software interrupt driven system, allowing the host to open and read files, tell the time, and even simple EGA graphics.

Unfortunately, the window of interest in these types of boards waned pretty quick, so the only development tools available are the original Green Hills Software packages, along with a simple PD (no sources) LISP & FORTH interpreter.  The board has support for C, Assembly, Fortran and Pascal.  Naturally the user is expected to invoke each component of the tool chain manually, as was the case for many micro hosted tools of the day.  What is kind of interesting is that the environment isn’t a strict 8086 MS-DOS based cross compiler, rather the tools run on the NS32032 co-processor allowing seemingly large programs to run on machines from the early 1980s.

In addition to PC ISA boards, the NS32032 was popular as a secondary processor for various machines, including the 6502 based Acorn.

BBC Second Processor NS32032

This module could plug into the back of the Acorn, and then much like the Definicon DSI-32, let Acorn users run full 32bit program on their 8bit machines.  There has been an ongoing effort to emulate the Second Processor in a FPGA.  Flipping that on it’s head, a NS32032 emulator was found, and using a FPGA Acorn, the second processor was then emulated on a raspberry pi, using a C based emulator for the NS32032.

FPGA Acorn with raspberry pi second processor

Taking that CPU core, and finding the source code to the load program allowed for a 32bit Linux or Windows based load program to feed the C CPU core emulator.  I made some minor tweeks regarding it’s handling of files, and have a version that runs on Windows.

Series 32000 Emulator 4Mb Version 1.0b(MinGW32) of 8 Sep 2017
C-32000 1.6.12 Copyright(c)1985 Green Hills Software, Inc.
Series 32000 Emulator 4Mb Version 1.0b(MinGW32) of 8 Sep 2017
CSD-32000 Assembler V1.00a, Computer Systems Design
Pass 1 in progress
Pass 2 in progress
Pass 3 in progress
0 Assembly error(s) detected.
Series 32000 Emulator 4Mb Version 1.0b(MinGW32) of 8 Sep 2017
DSI-32000 Linker V1.03c, Definicon Systems Inc
@ FILE=LIB\CMAIN
@ LIBRARY=LIB\CLIB
@ NOCOMM
@ MOD=80
@ MODULE=CLIB/CODE_START=3600,NOCOPY
@ MODULE=CLIB/LINK_START=35E0,NOCOPY
@ MODULE=CRTLIB.C/CODE_START=4000,NOCOPY
@ MODULE=CRTLIB.C/LINK_START=7500,NOCOPY
@ MODULE=CRTLIB.C/SB_START=7000,NOCOPY
@ STACK=+40
@ CODE=A000
@ RAM=0..FFFFF
Series 32000 Emulator 4Mb Version 1.0b(MinGW32) of 8 Sep 2017
Dhrystone(1.1) time for 50000 passes = 1
This machine benchmarks at 50000 dhrystones/second

I was unable to get either the Pascal  or Fortran compilers to generate output that the assembler liked, however the C compiler works.  Other ISA NS32032 cards include the Opus, which could be configured to run SYSV unix!

For a while, these types of second processor cards were quite common, even being used as upgrade cards, like the Microsoft Mach-20, or giving access to a completly different CPU/OS combination like the CP/M z80 card for the Commodore 64, to the incredible Amiga BridgeBoard.

One thing to keep in mind is that the DSI-32 board came out in 1985.  The GNU project wouldn’t launch in earnest until 1988, which may not seem like that big of a window but in reality it really is.  3 years is a substantial time in the industry.  And like many things GNU in the 1980’s it was focused on bigger minicomputers like the SUN-2/SUN-3, VAX etc, not common machines like the Apple Macintosh, Commodore Amiga, Atari ST, although it’s 68000 was common subset of the 68010 in the SUN-2 and 68020 of the SUN-3.  Even the 32-bit giant of them all, the 80386 didn’t begin to get support until GCC 1.23 (the summer of 1988.  Early GCC had incredibly rapid progress).  But by the late 1980’s people with NS32032’s were using them in full systems, they weren’t the typical ‘brain in a jar’ type users that had these fancy CPU co-processor cards.

I did built a copy of GCC 1.39 & GAS 1.38 for the NS32K, although since it’s unable to link in any format the DSI-32 would understand it did seem kind of pointless.  The assembler syntax is quite different.  Perhaps if it were the 1980’s something like the x68000 port of GCC which modified GCC to use a syntax that the platform’s native assembler & linker were comfortable with.

Using the 1987 Infocom Interpreter source code, I was able to cross compile it to the NS32k.

Series 32000 Emulator 4Mb Version 1.0b(MinGW32) of 8 Sep 2017
DSI-32000 Linker V1.03c, Definicon Systems Inc
@ FILE=LIB\CMAIN
@ LIBRARY=LIB\CLIB
@ NOCOMM
@ MOD=80
@ MODULE=CLIB/CODE_START=3600,NOCOPY
@ MODULE=CLIB/LINK_START=35E0,NOCOPY
@ MODULE=CRTLIB.C/CODE_START=4000,NOCOPY
@ MODULE=CRTLIB.C/LINK_START=7500,NOCOPY
@ MODULE=CRTLIB.C/SB_START=7000,NOCOPY
@ STACK=+40
@ CODE=A000
@ RAM=0..FFFFF

C:\dsi\set021387>emu.exe infocom -a planetfa-37.z3
Series 32000 Emulator 4Mb Version 1.0b(MinGW32) of 8 Sep 2017
PLANETFALL
Infocom interactive fiction – a science fiction story
Copyright (c) 1983 by Infocom, Inc. All rights reserved.
PLANETFALL is a trademark of Infocom, Inc.
Release 37 / Serial number 851003

Another routine day of drudgery aboard the Stellar Patrol Ship Feinstein. This
morning’s assignment for a certain lowly Ensign Seventh Class: scrubbing the
filthy metal deck at the port end of Level Nine. With your Patrol-issue
self-contained multi-purpose all-weather scrub brush you shine the floor with a
diligence born of the knowledge that at any moment dreaded Ensign First Class
Blather, the bane of your shipboard existence, could appear.

Deck Nine
This is a featureless corridor similar to every other corridor on the ship. It
curves away to starboard, and a gangway leads up. To port is the entrance to
one of the ship’s primary escape pods. The pod bulkhead is closed.

Deck Nine Score: 0/4451
>

Although the The DSI-32 was followd up by 68020 based DSI-780, which was nearly three times faster.  As with the Amiga Bridge board, and cards like the SunPCi, these types of cards became more and more of an addon to run IBM PC software, and less about trying out new and exciting processors.  But now thanks to emulation you can try them all out without any additional messy hardware.

Anyone who cares, my dump of what I found and messed around with is here:

ns32032_dsi-32.7z

Great resources can be found:

Thanks to Alexander Voropay for giving me some heads up & materials for this interesting side trek!

This entry was posted in NS32032 by neozeed. Bookmark the permalink.
avatar

About neozeed

What is there to tell? I've loved UNIX like things since I was first exposed to QNX in highschool (we had the Unisys ICONS!), and spent the better time of my teenage years trying to get my own UNIX... I should have bought Coherent in retrospect.. Anyways latched onto Linux in 1992, and then got some old BSD admin books and have been hooked on the VAX BSD & other big/ancient things since...!

6 thoughts on “Definicon DSI-32 co-processor emulation

  1. “For a while, these types of second processor cards were quite common, even being used as upgrade cards…”

    Don’t forget the venerable ShaBLAMM Nitro “upgrade” VLB card, which allowed to convert your “old” 486 into a full working RISC system, driven by a MIPS processor.

    • Wow, I always wanted something like that, I didn’t know that one was a thing. Damn if I’d known MIPS on a stick would have been awesome, although considering software support for MIPS/NT … Maybe it was just as well. I only got the RISC version of Visual C++ some 7 or so years ago.

      Did you have one? It sure sounds pretty damned awesome.

      • Unfortunately no :-(.

        Actually, like 6 years ago, I saw one being auctioned at eBay, when eBay didn’t sucked nuts like it does now.
        No one has surfaced since then… But like happened with the mythic Desktation, i guess is just matter of time and patience to see one again, some good day :-).

      • I’ve read on vogons that the MIPS board over VL would drive Quake at around 5-6FPS, while a Pentium 60 with the asm optimization would yield 5-6FPS.

        And this would be the long term problem with not only the MIPS, but PowerPC & DEC Alpha. While Pentium performance in the 486 era would be awesome, Intel was always driving on the tail end of the RISC wave.

        Nobody was ever able to put together a system that basically was 3-5x the performance of a 486 in the time of 486’s or Pentium in the time of the Pentium at a comparable price to a Pentium. Big companies, will of course happily pay whatever it is, to run things faster where needed, but it kills any hope of real world adoption.

        But as they say, this is all academic.

        The Itanium, or it’s threat basically killed almost all the other RISC chips, such as the MIPS, HPPA, PowerPC in non IBM machines, and Oracle’s desire to win a lawsuit against Google, much how SUN sued Microsoft over Java lead to the death of the SPARC. And the x86_64 from AMD killed the Itanium before it even really got started.

  2. Thank you, Mr. Neozeed!

    Big Thanks for David Rand also, the original author of the DSI-32 software (you may know him by MRTG package). He has put together an old DSI-32 loader and NS32016 emulator.

    It would be interesting to port early GCC 1.x to this board (using existing Green Hills compiler) to compare a performance.

    P.S.
    There was also Motorola 88000 ISA coprocessor board from Opus system:
    https://books.google.ru/books?id=nDAEAAAAMBAJ&pg=PA40&lpg=PA40#v=onepage&q&f=false

    • We live in such a strange era where we can effectively emulate them all, and much faster than the real thing.

      It’s still very interested

Leave a Reply

Your email address will not be published.

Notify me of followup comments via e-mail. You can also subscribe without commenting.