public inbox for linux-8086@vger.kernel.org
 help / color / mirror / Atom feed
From: David Given <dg@cowlark.com>
To: linux-8086@vger.kernel.org
Subject: Re: Future of ELKS
Date: Fri, 21 May 2004 17:30:45 +0100	[thread overview]
Message-ID: <200405211730.45239.dg@cowlark.com> (raw)
In-Reply-To: <20040521132425.GP24490@duckman.distro.conectiva>

On Friday 21 May 2004 14:24, Eduardo Pereira Habkost wrote:
[...]
> What I mean is: do we want and have people that could do the work
> of making or porting a good compiler work on the 8086?
[...]
> but my question is:
> the ELKS project is interested in spending efforts directed to creating a
> good development environment (read: a good compiler, a 'make', linker,
> > and their friends, and that makes the work of creating and porting 
> applications not so expensive) that runs on ELKS?

Well... Minix has all this. It all works, it's all debugged, it's all open 
source. It all runs self-hosted on Minix with a 64/64 split address space.

The only problem is that Minix' compiler, bcc, only supports K&R C. However, 
there are tools available that will convert ANSI C into K&R C; that's how 
ELKS is currently built. Admittedly, you don't get the superior type checking 
that ANSI C gives you, but it does build.

As I see it, there are three real options here:

a) Put quite a lot of effort into writing an ANSI C compiler that will run 
self-hosted on ELKS (and Minix).

b) Give up on building anything self-hosted and cross-compile everything using 
gcc or Turbo C++ (which produces good code, and has been released for free by 
Borland: http://community.borland.com/article/0,1410,20841,00.html).

c) Do both. Cross-compile with an ANSI C compiler, but build self-hosted using 
bcc and unprotoize. This has the advantage that we get the advanced type 
checking of ANSI C if we cross-compile, but the lightweight toolchain of K&R 
if it's built self-hosted.

Interestingly enough, (c) is already what we have. It's just that nobody has 
really got around to setting up a self-hosted system. There's nothing 
technically stopping it from working, except for the occasional minor bug.

(BTW, if you look at the mailing list archives, way back in the mists of time 
there was a six-month discussion on what compiler to use. Let's not do that 
again...)

On Friday 21 May 2004 15:15, Jody wrote:
[...]
> The 8086/88's biggest limitation has to be the segmented memory model to
> retain compatibility with some old CPU (8085?) and these compatibility
> efforts have hindered Intel CPUs for a long time...

Segmentation is also what makes ELKS work at all on the 8086. It acts as a 
poor-man's MMU. Without segmentation, you wouldn't be able to have 
relocatable processes; you wouldn't be able to do any kind of swapping or 
move code around at run time.

(Remember that a 64/64 process is using 16-bit points for everything. It never 
touches its segment registers. If you copy the process onto disk, reload it 
elsewhere, restore its registers but make sure that the segment registers 
point to its new location in memory, it'll never even notice.)

Yes, we *could* use some kind of larger memory model with bigger pointers, but 
I wouldn't recommend it. Using multiple segments makes stuff far more 
complicated --- particularly as ints and pointers will now be different sizes 
--- and any 8086 program that needs more than 128kB is probably too big 
anyway.

If you think 128kB of RAM is too small to do anything useful, I strongly urge 
you to go out and look into CP/M. Your average CP/M system had about 60kB 
free for user applications, shared between code and data. 8080 and Z80 code 
is significantly more verbose than 8086 code. But look at all those 
applications...

-- 
+- David Given --McQ-+ "I can handle myself. I've been in a fire fight.
|  dg@cowlark.com    | Well, I was in a fire.... Actually I was fired.
| (dg@tao-group.com) | from a fry cook opertunity." --- Firefly, _War
+- www.cowlark.com --+ Stories_

  reply	other threads:[~2004-05-21 16:30 UTC|newest]

Thread overview: 37+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-05-19 20:55 Future of ELKS Miguel Bolanos
2004-05-20  3:39 ` I'm in Void
2004-05-20 14:47   ` Miguel Bolanos
2004-05-20 11:42 ` Javier Sedano
2004-05-20 15:15   ` Miguel Bolanos
2004-05-20 15:37     ` Eduardo Pereira Habkost
2004-05-20 16:06       ` Andrey Romanenko
2004-05-21  5:51         ` Dan Olson
2004-05-20 17:30       ` Javier Sedano
2004-05-21  8:32         ` Gábor Lénárt
2004-05-21 14:15           ` Jody
2004-05-24  9:29             ` Gábor Lénárt
2004-05-24 18:20               ` Alan Cox
2004-05-20 23:43       ` David Given
2004-05-21  1:04         ` Stefan de Konink
2004-05-21  3:39           ` Chad Page
2004-05-29 16:58             ` Gregg C Levine
2004-05-21  5:55         ` Dan Olson
2004-05-21  6:08         ` Jody
2004-05-21 13:24         ` Eduardo Pereira Habkost
2004-05-21 16:30           ` David Given [this message]
2004-05-21 16:59             ` Michael McConnell
2004-05-22 12:12               ` David Given
2004-05-22 17:29                 ` Chad Page
2004-05-21 18:38             ` Jody
2004-05-22  8:53               ` jb1
2004-05-22 17:00                 ` Chad Page
2004-05-24  9:42               ` Gábor Lénárt
2004-05-20 16:54     ` Javier Sedano
2004-05-21  5:50     ` Dan Olson
2004-05-21  9:08       ` Arnaldo Carvalho de Melo
2004-05-21 10:24         ` Alan Cox
2004-05-24 12:20         ` Gábor Lénárt
  -- strict thread matches above, loose matches on Subject: below --
2004-05-20 13:40 Pat Gilliland
2004-05-21 17:53 ` Miguel Bolanos
2004-05-20 20:18 Tommy McCabe
2004-05-24 13:17 BODRATO Stefano

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200405211730.45239.dg@cowlark.com \
    --to=dg@cowlark.com \
    --cc=linux-8086@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox