Alternate implementation languages
Alternate implementation languages
There's plenty of people writing OS' in C, asm, and Pascal. But what about other languages?
Lisp-style languages and Haskell seem unsuited for direct hardware access.
But what about, say, D - http://www.digitalmars.com/d/ - a garbage-collected, compiled language with a GCC frontend? Would that be suitable? D is like C++ done right, IMO it fixes all the idiocy C++ has embedded in its core, and reveals a good language. Heck, it even has lazy evaluation. Plus, it finally does the right thing as char - char == utf-8 character, not a byte.
Thoughts welcome
Lisp-style languages and Haskell seem unsuited for direct hardware access.
But what about, say, D - http://www.digitalmars.com/d/ - a garbage-collected, compiled language with a GCC frontend? Would that be suitable? D is like C++ done right, IMO it fixes all the idiocy C++ has embedded in its core, and reveals a good language. Heck, it even has lazy evaluation. Plus, it finally does the right thing as char - char == utf-8 character, not a byte.
Thoughts welcome
Last edited by ehird on Sat Apr 07, 2007 2:33 pm, edited 1 time in total.
I think there's someone on this forum that has an OS written in D. (Or was that elsewhere?...) It's possible, but I think most stay away from it, because of D's almost closed status.
As for Lisp and Haskell, mystran, I think, is writing an OS in his own dialect of Scheme. So under certain circumstances, it is possible. I think I might try my own Haskell OS sometime....Although, I might use it at a higher level and use assembly for access to hardware......
That covers imperative and functional languages.....Anyone for Prolog? (Logical Languages)
As for Lisp and Haskell, mystran, I think, is writing an OS in his own dialect of Scheme. So under certain circumstances, it is possible. I think I might try my own Haskell OS sometime....Although, I might use it at a higher level and use assembly for access to hardware......
That covers imperative and functional languages.....Anyone for Prolog? (Logical Languages)
C8H10N4O2 | #446691 | Trust the nodes.
I've been talking in #d for a bit, and I recognized hakware from this forum. Yeah, it seems his OS is in D.Alboin wrote:I think there's someone on this forum that has an OS written in D. (Or was that elsewhere?...) It's possible, but I think most stay away from it, because of D's almost closed status.
What I like about D is its inline asm syntax...
asm { statement; statement }
or
asm {
mov blah;
yada yada;
}
It's Intel syntax embedded right into a regular block. This means that you wouldn't need a seperate asm-only file, because it wouldn't be all annoying strings for inline asm.
I also have been trying to implement a C-like language of my own, to help in programming complex code blocks in assembly. But it currently is too dependent to x86 because it uses its register names (to make it practically a direct assembly language with C syntax).
If well I was doing my kernel in it, it's more a pseudocode representation to further translate to traditional assembly.
I don't use it very much now, unless there is something far too complex to design directly in assembly.
If somebody had some ASM code to show this pseudolanguage (if there's interest) I would do the translation. Something short preferably.
If well I was doing my kernel in it, it's more a pseudocode representation to further translate to traditional assembly.
I don't use it very much now, unless there is something far too complex to design directly in assembly.
If somebody had some ASM code to show this pseudolanguage (if there's interest) I would do the translation. Something short preferably.
Yeah, XANA is in D. Though the executable format is in a language I'm working on called EPL (dunno if that name's taken already though). It's an enfiladal / link-oriented graphical bytecode whose structure is built into the filesystem. It's rather like a more integrated Nuzzl, or something like what you'd get if you gave asm opcodes icons and used them in a scheme variant wherein the parentheses were replaced with hyperlinks. It also works over networks (i.e., your program can be distributed across the net, but running all on one computer, without downloading the whole thing).
I don't know if these count as they are basically difference versions of C, and sometimes BASIC style programming. I use a modified C for kernel module development who has a native object structure whose access is co ordinated with a built in object manager. I also use a customized version of that where the special objects are compiled and run specifically for use in a cluster. There are numerous others i use for user space, like a special threading C (dubbed strings for the time).
- AndrewAPrice
- Member
- Posts: 2299
- Joined: Mon Jun 05, 2006 11:00 pm
- Location: USA (and Australia)
There have been Java/C# OS's..
Hey.. has anyone heard about Microsoft now releasing the entire Windows CE 6.0 kernel until their shared source license? Now to find where I can get it from..
Hey.. has anyone heard about Microsoft now releasing the entire Windows CE 6.0 kernel until their shared source license? Now to find where I can get it from..
My OS is Perception.
XANA had to go through a lot of annoyances to get D code to run standalone; if anyone wants to make a D kernel, I'd point them to the current XANA code for a start (the basic stuff is pretty useful, especially considering you gotta drop in the gc, memory manager, typeinfos, and a ton of random stuff pretty immediately before anything will work). It's easy enough to rewrite my code, which is more than I can say for Walter Bright (the guy who wrote the original D compiler and most of the standard lib).
One, don't call a thread "alternative implementation language" when you're actually advertising D.
Two, before you make claims like "C++ done right", imagine that there might be people out there who have a different idea of what is "broken" in C++. I, for one, feel quite OK in a language that doesn't do GC.
Let's say that D is an interesting language in its own right, and leave it at that.
Two, before you make claims like "C++ done right", imagine that there might be people out there who have a different idea of what is "broken" in C++. I, for one, feel quite OK in a language that doesn't do GC.
Let's say that D is an interesting language in its own right, and leave it at that.
Every good solution is obvious once you've found it.