Computer Old Farts Forum
 help / color / mirror / Atom feed
* [COFF] Wanted: 16-bit big-endian Unix-like environment and/or libc
@ 2023-07-25  7:41 Warren Toomey via COFF
  2023-07-25 14:07 ` [COFF] " Clem Cole
  0 siblings, 1 reply; 2+ messages in thread
From: Warren Toomey via COFF @ 2023-07-25  7:41 UTC (permalink / raw)
  To: coff

Hi all, I'm looking for a 16-bit big-endian Unix-like development
environment with a reasonably new C compiler and a symbolic debugger.
And/or, a libc with source code suitable for a 16-bit big-endian environment.

Rationale: I've designed and built a 6809 single board computer (SBC) with
8K ROM, 2K I/O space for a UART and block storage, and 56K RAM. It's a
big-endian platform and the C compiler has 16-bit ints by default. I've
been able to take the filesystem code from XV6 and get it to fit into
the ROM with a hundred bytes spare. The available Unix-like system calls are:

	dup, read, write, close, fstat, link,
	unlink, open, mkdir, chdir, exit, spawn

and the spawn is like exec(). There is no fork() and no multitasking.
I've got many of the existing XV6 userland programs to run along with a
small shell that can do basic redirection.

Now I'm trying to bring up a libc on the platform. I'm currently trying
the libc from FUZIX but I'm not wedded to it, so alternative libc
recommendations are most welcome.

There's no debugging environment on this SBC. I do have a simulator that
matches the hardware, but I can only breakpoint at addresses and single-step
instructions. It makes debugging pretty tedious! So I was thinking of
using an existing Unix-like platform to bring up the libc. That way, if
there are bugs, I can use an existing symbolic debugger on the platform.

I could use 2.11BSD as the dev platform but it's little-endian; I'm worried
that there might be endian issues that stop me finding bugs that will arise
on the 16-bit 6809 platform.

As for which libc: I looked at the 2.11BSD libc/include and there's so
much stuff I don't need (networking etc.) that it's hard to winnow down
to just what I need. The FUZIX libc looks good. I just came across Elks
and that might be a possible alternative. Are there others to consider?

Anyway, thanks in advance for your suggestions.

Cheers, Warren

References:

XV6:   https://github.com/mit-pdos/xv6-public
FUXIZ: https://github.com/EtchedPixels/FUZIX/tree/master/Library
Elks:  https://github.com/jbruchon/elks/tree/master/libc

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2023-07-25 14:08 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-07-25  7:41 [COFF] Wanted: 16-bit big-endian Unix-like environment and/or libc Warren Toomey via COFF
2023-07-25 14:07 ` [COFF] " Clem Cole

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).