Philosophical Question about Cosmos

Feb 5, 2012 at 2:28 AM

Hey guys, I had a question for the developers/coordinators of the project:

How do you guys think the projects's managed code will compare to an un-managed OS? Do you think the managed will be faster? Personally I don't think so, reason being: we know that C/C++ can be far more optimized than managed code. I guess my question is, why managed code? (Great project all the same)

Cheers, Blackfireize

Developer
Feb 5, 2012 at 2:31 AM

Why not managed? .Net is a great platform with endless opertunities. The languages are easier to learn than c/c++ and basically anyone can create an os.

On Feb 4, 2012 8:29 PM, "blackfireize" <notifications@codeplex.com> wrote:

From: blackfireize

Hey guys, I had a question for the developers/coordinators of the project:

How do you guys think the projects's managed code will compare to an un-managed OS? Do you think the managed will be faster? Personally I don't think so, reason being: we know that C/C++ can be far more optimized than managed code. I guess my question is, why managed code? (Great project all the same)

Cheers, Blackfireize

Read the full discussion online.

To add a post to this discussion, reply to this email (Cosmos@discussions.codeplex.com)

To start a new discussion for this project, email Cosmos@discussions.codeplex.com

You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe or change your settings on codePlex.com.

Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at codeplex.com

Coordinator
Feb 5, 2012 at 8:21 AM
Using a managed language/environment for developing an OS, we can optimize much more.

Many things for which traditional operating systems need hardware support (context switches based on interrupts for example), we can do the checks compile-time, and just emit standard calls. This can save hundreds of microseconds per call. Other situations exist as well.

On Sun, Feb 5, 2012 at 4:31 AM, joshbeitler <notifications@codeplex.com> wrote:

From: joshbeitler

Why not managed? .Net is a great platform with endless opertunities. The languages are easier to learn than c/c++ and basically anyone can create an os.

On Feb 4, 2012 8:29 PM, "blackfireize" <notifications@codeplex.com> wrote:

From: blackfireize

Hey guys, I had a question for the developers/coordinators of the project:

How do you guys think the projects's managed code will compare to an un-managed OS? Do you think the managed will be faster? Personally I don't think so, reason being: we know that C/C++ can be far more optimized than managed code. I guess my question is, why managed code? (Great project all the same)

Cheers, Blackfireize

Read the full discussion online.

To add a post to this discussion, reply to this email (Cosmos@discussions.codeplex.com)

To start a new discussion for this project, email Cosmos@discussions.codeplex.com

You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe or change your settings on codePlex.com.

Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at codeplex.com

Read the full discussion online.

To add a post to this discussion, reply to this email (Cosmos@discussions.codeplex.com)

To start a new discussion for this project, email Cosmos@discussions.codeplex.com

You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe or change your settings on codePlex.com.

Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at codeplex.com


Feb 5, 2012 at 12:49 PM
mterwoord wrote:
Using a managed language/environment for developing an OS, we can optimize much more.

Many things for which traditional operating systems need hardware support (context switches based on interrupts for example), we can do the checks compile-time, and just emit standard calls. This can save hundreds of microseconds per call. Other situations exist as well.

On Sun, Feb 5, 2012 at 4:31 AM, joshbeitler <notifications@codeplex.com> wrote:

From: joshbeitler

Why not managed? .Net is a great platform with endless opertunities. The languages are easier to learn than c/c++ and basically anyone can create an os.

On Feb 4, 2012 8:29 PM, "blackfireize" <notifications@codeplex.com> wrote:

From: blackfireize

Hey guys, I had a question for the developers/coordinators of the project:

How do you guys think the projects's managed code will compare to an un-managed OS? Do you think the managed will be faster? Personally I don't think so, reason being: we know that C/C++ can be far more optimized than managed code. I guess my question is, why managed code? (Great project all the same)

Cheers, Blackfireize

Read the full discussion online.

To add a post to this discussion, reply to this email (Cosmos@discussions.codeplex.com)

To start a new discussion for this project, email Cosmos@discussions.codeplex.com

You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe or change your settings on codePlex.com.

Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at codeplex.com

Read the full discussion online.

To add a post to this discussion, reply to this email (Cosmos@discussions.codeplex.com)

To start a new discussion for this project, email Cosmos@discussions.codeplex.com

You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe or change your settings on codePlex.com.

Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at codeplex.com


 I honestly never thought about it that way. I had always assumed that a managed language would be slower as it required run-time support, unlike a language like C. But I had another question, how do you guys access memory locations for say a heap when you cant use pointers in a managed language? (I think C# has support for pointers but I never had any success with them when I tried)

Cheers, Blackfireize

Coordinator
Feb 5, 2012 at 1:55 PM
> a language like C. But I had another question, how do you guys access
> memory locations for say a heap when you cant use pointers in a managed
> language? (I think C# has support for pointers but I never had any
> success with them when I tried)

You can use pointers in C#, just use unsafe variables. This in the
future will be restricted to the low level kernel though, and we also
have special classes which actually are implemented in asm that allow
CPU access etc from C#.
Feb 5, 2012 at 2:43 PM
kudzu wrote:
> a language like C. But I had another question, how do you guys access
> memory locations for say a heap when you cant use pointers in a managed
> language? (I think C# has support for pointers but I never had any
> success with them when I tried)

You can use pointers in C#, just use unsafe variables. This in the
future will be restricted to the low level kernel though, and we also
have special classes which actually are implemented in asm that allow
CPU access etc from C#.

I just looked through the source, I'm guessing the file you were talking about was "CPUImpl.cs". To be honest, I have never truly looked through the code, but the more I do, the more enthralling it becomes to me.....heh I don't suppose you guys have a 'wishlist' I would be willing to help out any way I could.

Cheers, Blackfireize

Developer
Feb 5, 2012 at 3:35 PM

In truth, the only thing that managed code can be slower at is tight loops (such as encryption & compression algorithms), and that's due purely to the way managed code works. If your really that concerned about speed, why aren't you writing everything in pure asm, which, if designed right, doesn't even need to deal with stack frames (which are the biggest slowdown for any other language)? The likely reason: It's much easier to write it in C than in asm, the same can be said for C# vs. C

Coordinator
Feb 5, 2012 at 4:07 PM
Blackfireize: First step to get going with joining the project is join our mailinglist.
Send an email asking for small tasks (after short explaining technical background, like language experiences). These small tasks will get you going, and will introduce you to many aspects of the project..

Feb 5, 2012 at 4:47 PM
mterwoord wrote:
Blackfireize: First step to get going with joining the project is join our mailinglist.
Send an email asking for small tasks (after short explaining technical background, like language experiences). These small tasks will get you going, and will introduce you to many aspects of the project..

Well I got on the IRC just fine, and maybe its just me, but I cant find a way to join the mailinglist :P any suggestions?

Cheers, Blackfireize

Coordinator
Feb 5, 2012 at 4:50 PM
send email to cosmos-dev-subscribe@yahoogroups.com



On Sun, Feb 5, 2012 at 6:47 PM, blackfireize <notifications@codeplex.com> wrote:

From: blackfireize

mterwoord wrote:
Blackfireize: First step to get going with joining the project is join our mailinglist.
Send an email asking for small tasks (after short explaining technical background, like language experiences). These small tasks will get you going, and will introduce you to many aspects of the project..

Well I got on the IRC just fine, and maybe its just me, but I cant find a way to join the mailinglist :P any suggestions?

Cheers, Blackfireize

Read the full discussion online.

To add a post to this discussion, reply to this email (Cosmos@discussions.codeplex.com)

To start a new discussion for this project, email Cosmos@discussions.codeplex.com

You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe or change your settings on codePlex.com.

Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at codeplex.com


Feb 5, 2012 at 5:00 PM

Message sent.