• Post Reply Bookmark Topic Watch Topic
  • New Topic

A question for experts ...  RSS feed

 
Vassili Vladimir
Ranch Hand
Posts: 1585
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

Is it possible to use JNI to write an Operating System using Java ?

Thanks in advance ...
 
Amit Ghorpade
Bartender
Posts: 2856
10
Fedora Firefox Browser Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
first of all i am not an expert, nor the question needs to be i think.
Next, i dont get meaning of the sentence
JNI using Java
because JNI is basically use of NON JAVA code mostly C,C++ in Java to perform hardware dependent/ system dependent operations which are not possible through Java, e.g device drivers.
An OS is the interface between hardware and user applications, so in order to "create" an OS through Java, first you will need to start the JVM, which is indeed an software/ user application. So where is that suppose to execute ? then load native code to initialize devices and so on..

So i think this is impossible

Hope this helps
 
Ernest Friedman-Hill
author and iconoclast
Sheriff
Posts: 24217
38
Chrome Eclipse IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Nothing is impossible -- some things are more pointless than others

J2ME JVMs don't require very much in the way of OS support. I could imagine a boot loader that could load up a J2ME VM, and then implementing an OS in J2ME, using JNI to talk to the hardware. Perhaps this Java kernel could then run a more elaborate JVM that supported J2SE, and user programs could run under this J2SE VM.
 
Vassili Vladimir
Ranch Hand
Posts: 1585
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Dear Ernest,

Can you give more explanation, as a matter of fact, I really need some good information about this issue.

Thanks ...
 
Amit Ghorpade
Bartender
Posts: 2856
10
Fedora Firefox Browser Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
Dear Ernest,
as a shreiff and author, you defininately have more knowledge than me.
And as you said that J2ME JVMs do not require much os support so an OS in Java is feasible.
But your explanation reminds me more of a shell program than an OS itself.
So will you please elaborate, now even i am keenly interested in this topic.

Thanks ..
 
Ulf Dittmer
Rancher
Posts: 42972
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by amit ghorpade:
as a shreiff and author, you defininately have more knowledge than me.
And as you said that J2ME JVMs do not require much os support so an OS in Java is feasible.


Well, the Sheriff exam Ernest took doesn't cover J2ME in great detail, but I don't think that's quite what he was saying.

It's not just the boot loader that would be required to run a bare-bones JVM. The API also contains a fair number of native methods, all of which would need to be implemented as well. And even if then you get to a point where a full-fledged J2SE JRE is running, there are still many things an OS can do that the JRE can't. So, the practical difficulties are formidable.
[ June 09, 2007: Message edited by: Ulf Dittmer ]
 
Amit Ghorpade
Bartender
Posts: 2856
10
Fedora Firefox Browser Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
Dear Ulf Dittmer,
I really appreciate your aspect that you added to the topic.
But i will be thankful if you please add your firm view on the same, so that we can get some definite lead on the topic.

Thanks in advance
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!