I know this project.The question is that "Can we create a real OS with Managed Code or the os that will create with this project is a hello world os?"
Operating Systems need to have full control on hardware.Can we do it with this one?
If there are any another project please tell me
Cosmos Project
-
4Are you asking if there are any managed code operating systems out there? Check out the [Singularity project](http://research.microsoft.com/en-us/projects/singularity/), from Microsoft. – alex May 16 '11 at 06:09
-
I know that there are.But can we write a big os such as mac os or windows with these projects??? – Saleh May 16 '11 at 06:11
-
1@LightWing: it's a daunting task. First of all, Singularity is an OS, so you can't write an OS with it. I know Microsoft uses a language similar to C# to write it, but I don't have any more details. – alex May 16 '11 at 06:12
-
Sorry I was wrong about MOSA,But Cosmos is a project for c#.Net to develop OS – Saleh May 16 '11 at 06:15
-
1Of course you can build an operating system in a managed environment. It all depends how you define operating system. – Razor May 16 '11 at 06:20
-
No point in re-opening this: http://stackoverflow.com/questions/1669993/how-to-build-a-operating-system-with-c http://stackoverflow.com/questions/4058876/a-full-operating-system-in-c plus the answers to http://stackoverflow.com/q/861257/2509 discusses the possibility. – dmckee --- ex-moderator kitten May 16 '11 at 19:34
1 Answers
Yes it can be done - see Singularity which is (was) a Microsoft research project to create an entirely managed operating system in "Sing#" (an extended version of "Spec#" which is itself an extension of C#). Its worth stressing that this was just a research project into the concept, and was never intended as a "full" operating system of the likes of Windows or Max OSX.
The source code is available on CodePlex - you can download the code, build it and run it yourself in an emulator (I've done it myself, its well documented and relativley easy although I can't remember the exact steps myself).
Parts of the system were written in assembly / C, specifically the bootloader and the lowest level x86 interupt dispatch code however this is essentially all but unavoidable (it is by its very nature very platform dependant - something needs to write the x86 instructions to control and respond to basic hardware). The low level interrupts are also not particularly interesting in terms of how the operating system actually functions, so I personally don't consider this as cheating the "entirely managed" definition.
Looking on the Wikipedia page for Singularity there are also 5-6 similar projects, including Cosmos and a couple of similar attempts that use Java instead of C#.
The focus of Singularity OS was on security and dependency, however whats also impressive is that according to some basic benchmarks in An Overview of the Singularity Project1 (PDF) the performance of their archetecture was actually comparable to that of other "more conventional" operating systems:
... these numbers demonstrate that architecture that we proposed not only does not incur a performance penalty, but is often as fast as or faster than more conventional architecture. In other words, it is a practical basis on which to build a system.

- 84,773
- 49
- 224
- 367
-
-
-
1@LightWing I don't know if it is "Open source" (it is just a research project not a "proper" OS) however the source code is available on CodePlex. – Justin May 16 '11 at 06:36
-
I have no idea what performance was like but it wasn't the focus of their research so it probably wasn't fantastic, however I'm not aware of any real reason why it shouldn't be able to perform if enough effort was spent optimising it suitably. – Justin May 16 '11 at 06:36
-
if understand it,os programming in java seems interesting too.http://www.jnode.org/ Thanks your link to Wikipedia was so great. – Saleh May 16 '11 at 07:10