Re: Can Java be used to write an operating system

On Tue, 3 Jun 2008, Dave Miller wrote:

devj.nullj@xxxxxxxxx wrote:

I would like to enquire from the experts here whether Java can be used to program lower level applications like device drivers or a new operating system for that matter?

Probably the wrong language for a free standing driver and pretty much impossible for a free standing OS. Java utilizes an abstract computing machine (called a "Java Virtual Machine" or JVM) which sits on top of the native OS. In other words, you'd need an OS to run your OS.

Yebbut you can write the JVM in java, and have it compile itself, isn't it:

Once you have that kind of capability - and Jikes includes ways of expressing unsafe but essential operations like direct memory access - there's no reason you couldn't write an OS all the way down to the bare metal. You might need a smattering of assembly to initialise the processor, set up interrupt handlers, things like that, but you could completely replace C.

I have no idea how far along this JNode project is, but long, long ago, in an industry far, far away, a company called Symbolics actually shipped an operating system written entirely in LISP:


For me, thats just logic. OTOH, Spock went bananas several times using
logic. -- Pete, mfw