[Annoying] Code Education Needed

Soldato
Joined
10 Dec 2003
Posts
6,348
I know that there exists quite a number of programming languages, and all made to complete different tasks. Some of them, I know are used to write all these great and wonderful programs we use on our systemss or online.

PHP, C#, ASP, etc

What I'm struggling to work out is, what is used to write Windows or other Operating Systems? I mean, from what platform are they built?

It seems to me that, the better OS's becomes (and technology as a whole), the better programs we get because of the power that the OS offers us.

I'm also wondering how DOS/MS-DOS fits into all of this, but struggling to find a place for it. If someone could clear up this confuzzling problem, I'd be appreciative, much.

Thanks. :)
 
I know that there exists quite a number of programming languages, and all made to complete different tasks. Some of them, I know are used to write all these great and wonderful programs we use on our systemss or online.

PHP, C#, ASP, etc

What I'm struggling to work out is, what is used to write Windows or other Operating Systems? I mean, from what platform are they built?

It seems to me that, the better OS's becomes (and technology as a whole), the better programs we get because of the power that the OS offers us.

I'm also wondering how DOS/MS-DOS fits into all of this, but struggling to find a place for it. If someone could clear up this confuzzling problem, I'd be appreciative, much.

Thanks. :)
DOS/MS-DOS is an operating system. Windows 95 and Windows 98 were built 'on top' of MS-DOS, but since Windows 2000 it has been replaced - the 'Windows' operating system top-to-bottom.

Beyond the kernel which is written in C and/or 'assembly' code, the rest of the operating system is written in C and C++.
 
Linux is written in C. The windows kernel is also I believe written in C.

Linus Torvalds said:
"In fact, in Linux we did try C++ once already, back in 1992. It sucks. Trust me - writing kernel code in C++ is a BLOODY STUPID IDEA.

"The fact is, C++ compilers are not trustworthy. They were even worse in
1992, but some fundamental facts haven't changed: 1) the whole C++ exception handling thing is fundamentally broken. It's _especially_ broken for kernels. 2) any compiler or language that likes to hide things like memory allocations behind your back just isn't a good choice for a kernel. 3) you can write object-oriented code (useful for filesystems etc) in C, _without_ the crap that is C++."

:)
 
It seems to me that, the better OS's becomes (and technology as a whole), the better programs we get because of the power that the OS offers us.
Don't really agree with that! I think the reason why C#(.Net) is so good is down to the .Net framework; the classes that other programmers have spent many moons creating. You can ignore these and use the low level windows API but its just a nightmare.
 
Don't really agree with that! I think the reason why C#(.Net) is so good is down to the .Net framework; the classes that other programmers have spent many moons creating. You can ignore these and use the low level windows API but its just a nightmare.

I would agree with you Goksly.

OS'es are generally written in C, C++, ASM.

Not sure what you are asking in reference to DOS. It's another operating system, pretty much the lauch pad of Mr Gate's empire.
 
Lots of great Education guys, thanks. :D

I wasn't aware that DOS was just an OS, as I assumed DOS was somehow a basis for what all OS's are built on - maybe because even with the latest OS's, you still see DOS-y things going on before the OS actually starts.

So my next question would be - Where does it all start?

I guess what I want to know is what happens the moment you push the power button on a PC? What's the very first 'program' or line of code to actually run?

I can feel this is getting more to do with hardware, than code. :)
 
The very first thing that happens is bootstrapping (or just booting), so called because the PC kind of has to pull itself up by it's boot straps. When you turn a PC on it doesn't know how to run a program, so it has to run a program to work out how to run a program. There's something called the bios which does this, it's almost a mini os in its own right, built right onto the motherboard on a CMOS chip.

The BIOS generally detects and manages the hardware long enough to read the hard drives and start any operating system on them, once that gets to a certain point the OS itself takes over.
 
Back
Top Bottom