Linked by MOS6510 on Thu 10th Jan 2013 23:25 UTC
General Development "For years I've tried my damnedest to get away from C. Too simple, too many details to manage, too old and crufty, too low level. I've had intense and torrid love affairs with Java, C++, and Erlang. I've built things I'm proud of with all of them, and yet each has broken my heart. They've made promises they couldn't keep, created cultures that focus on the wrong things, and made devastating tradeoffs that eventually make you suffer painfully. And I keep crawling back to C."
Thread beginning with comment 548546
To view parent comment, click here.
To read all comments associated with this story, please click here.
RE[9]: C -> Go
by Valhalla on Sun 13th Jan 2013 00:25 UTC in reply to "RE[8]: C -> Go"
Valhalla
Member since:
2006-01-24


These systems are also native

Heh, I should have checked up the name of the language, Native Oberon is a quite telling name ;)


I just have user experience, no benchmarks.

They are good enough to use as desktop system, with text editing software, video and sound processing, Internet usage, for example.

Which really doesn't tell me anything, it's an unmeasurable anecdote.

But let me reiterate, should there be a garbage collected memory safe operating system with the same or just about the same performance as that of native, manually memory managed operating systems then the industry would pounce on it in a heartbeat since these are all great features... until you factor in the performance cost, which is why Linux/BSD/NT/Darwin haven't been replaced.

There really isn't any conspiracy going on, there's simply no 'oh, this is good enough performance' when we are talking about operating systems / kernels. In userspace, sure, but not in such core functionality which in turn has such a profound impact on the overall performance when put under pressure like in high performing servers, computing clusters, super computers etc. Areas where something like even a 3% performance difference isn't brushed off as irrelevant.

Heck I've seen hardcore gamers curse for less of a performance drop than that ;)


System programming languages with GC, also allow you to disable the GC in critical sections and make use of manual memory management in unsafe/system code sections.

Yes, pretty much all garbage collected languages allows for some sort of unsafe operation/mode, but entering and leaving critical sections comes with a performance cost and you are then adding complexity + possible bugs you tried to avoid by using a safe garbage collected language in the first place.

You are still left with less performance than native code and you may have introduced memory bugs, can't say I personally find that solution very attractive.

I don't always use garbage collecting, but when I do, I use full garbage collecting.

Reply Parent Score: 2

RE[10]: C -> Go
by moondevil on Sun 13th Jan 2013 08:31 in reply to "RE[9]: C -> Go"
moondevil Member since:
2005-07-08

But let me reiterate, should there be a garbage collected memory safe operating system with the same or just about the same performance as that of native, manually memory managed operating systems then the industry would pounce on it in a heartbeat since these are all great features... until you factor in the performance cost, which is why Linux/BSD/NT/Darwin haven't been replaced.


The issue is much broader than that, that is why I said inertia on my initial thread post.

System programming languages success are bound to the success of a specific operating system. There is yet to exist a system programming language that becomes successful without being sold by an OS vendor.

So, this means on the current scenario there would need to exist an operating system vendor that decides to promote such languages alongside an operating system coded in such language.

The UNIX family of operating systems of course will never move out of C, it does not make sense to do so.

Microsoft is only doing baby steps. First with Singularity, then with the still secret Midori that no one outside Microsoft Research really knows what it is about.

On Windows 8, the WinRT subsystem is based on COM, which makes use of reference counting with C++/CX as native language to develop such components.

As mentioned, at BUILD there was a comment about Windows code being migrated from C to C++, but no details were given if it is pure C++ or C++/CX.

In theory, Apple could throw away all the C and C++ code from MacOS X and just use Objective-C everywhere. This way developers could use the C subset in areas where performace cannot be ignored at all, while using the Objective-C ARC in code sections where it makes sense to do so.

Most companies prefer to evolve software, rather than rewrite it.

So do you see Microsoft or Apple creating from scratch an operating system in a GC system programming language just because it is cool to do so?

Of course not, because at the end that does not sell computers regardless how fast the system might be. So the progress is very slow and will take many versions until we get there and might even take a few more decades, who knows.

But we are moving into that direction, although in baby steps. Objective-C got a pure GC, which had a few issues and now ARC, which seems to be better.

With Windows 8, C++ got reference counting extensions with C++/CX. If they should have used *_ptr<>()is another discussion.

The remaining question is why doesn't another vendor do it?

Well, developing operating systems is a lot of effort and now with free(gratis) operating systems available (Linux and BSD family) no single company is going to invest money on that to go against any of the big guys that sell operating systems with an established base.

So we keep using what works and most important sells computers, hence inertia.

Reply Parent Score: 3

RE[11]: C -> Go
by Valhalla on Sun 13th Jan 2013 18:32 in reply to "RE[10]: C -> Go"
Valhalla Member since:
2006-01-24


System programming languages success are bound to the success of a specific operating system. There is yet to exist a system programming language that becomes successful without being sold by an OS vendor.

But that doesn't preclude the existance of verifiable benchmarks showing the performance compared to these established operating systems.

If someone were to present such benchmarks for their research operating system then the industry would take great note. I have yet to come across any such benchmarks, can you point me to any?

Obviously these research OS's are being continously benchmarked by their creators against established operating systems, and if they had something impressive to report performance-wise in those comparisons I'm certain they would be shouting it from the rooftops, research grants and all that.

First with Singularity, then with the still secret Midori that no one outside Microsoft Research really knows what it is about.

Singularity saw no commercial potential and was passed off to academia, and 'then with the still secret Midori that no one outside Microsoft Research really knows what it is about' means absolutely nothing in the context of this discussion, it could be anything.


As mentioned, at BUILD there was a comment about Windows code being migrated from C to C++, but no details were given if it is pure C++ or C++/CX.

Microsoft's migration from C to C++ has been going on for quite some time as far as I know, hardly surprising as C is in a state of limbo in their toolchains. That doesn't mean they are shifting to being garbage collected.

So we keep using what works and most important sells computers, hence inertia.

There's a difference between using what works and where you actually put your continued efforts. I've seen no indication that efforts are being routed away from the traditional kernel/operating system towards some new shiny safe memory based solution.

Simply because when push comes to shove, they will be slower than the current solutions (unless they can somehow perform magic), and the current solutions are working very well.

We'll just have to agree to disagree, future will tell either way but seriously I've been hearing (the same?) people making your kind of claims for the past 10 years or so, those baby steps must be really small indeed.

Reply Parent Score: 2