Page 1 of 1
Osdev standards...
Posted: Mon Dec 08, 2008 2:42 pm
by mitzampt
Hi,
I'm thinking about starting my own project or adhering to one soon, but first i'm planning and I have some thoughts/questins i want to share:
1. Can there be other executable formats for kernels, i mean custom ones? I'm thinking about one that allows you to use separate compiled parts of the kernel into one big picture of the image? I find quite dificult to follow a monolithic structure (example linux kernel) without some sort of mapping of it's guts.
2. Can someone point me a language that it's equally fast and comprehensive, both compiled and interpreted? This is for basic system interfacing/system calls/shell.... Fast may not be the most important quality....
3. How many of you have succeded making a operating system with a object oriented language compiler and standard library (that means C++) and kept an object oriented structure? Can anyone point me a project which is still in development of this kind?
The bottom line is, according with the topic title: Can osdev use developer experience to formulate some standards about operating systems, new standards that complete the goals POSIX and other standards had? Executable format, language, system layout recommendations, mappings, some points of reference for a good operating system.... only POSIX standard alone, if kept in an operating system allows easy porting of software and that is a big advantage. But POSIX is not complete, not as nearly as comercial software developers' ones...
Hope i don't make a big fool out of myself...
Mike
Re: Osdev standards...
Posted: Mon Dec 08, 2008 6:54 pm
by Troy Martin
Welcome to the forums!
1. Sure, you can code your own and parse the header. I was thinking of doing one for my OS.
2. If you're looking for really fast, you should go for assembly language. I think C is a good high level language, personally.
3. Never tried it. But remember, in OS development, you have to code EVERYTHING yourself, especially in protected mode with high-level language. So there's no libraries to do stuff for you.
Hope i don't make a big fool out of myself...
Nope, you didn't! Perfectly logical and smart questions.
Good luck with your OS,
Troy
Re: Osdev standards...
Posted: Mon Dec 08, 2008 8:03 pm
by Love4Boobies
mitzampt wrote: 3. How many of you have succeded making a operating system with a object oriented language compiler and standard library (that means C++) and kept an object oriented structure? Can anyone point me a project which is still in development of this kind?
Troy Martin wrote:3. Never tried it. But remember, in OS development, you have to code EVERYTHING yourself, especially in protected mode with high-level language. So there's no libraries to do stuff for you.
Well, if you want OOP, C++ isn't necessarily what you need. C, as opposed to wha t Troy Martin said, is not a high level language, but rather a middle level language. C++ is a higher level language and has all sorts of stuff that you'll need to write yourself (standard library); however, OOP support is not one of these things. Try Objective C if it meets your requirements.
Re: Osdev standards...
Posted: Mon Dec 08, 2008 8:20 pm
by Troy Martin
Heh, middle-level, I like that. I'd apply that to my NASM macros though xD
Re: Osdev standards...
Posted: Sun Dec 14, 2008 9:51 pm
by thre3dee
Love4Boobies wrote:however, OOP support is not one of these things
I fail to see how people constantly disregard C++ as being object-oriented. Its not quite high level and not quite low level but its classes provide a lot of flexibility and satisfy the "OOP" definition. The whole point of C++ was to add object-oriented programming to C.
Re: Osdev standards...
Posted: Sun Dec 14, 2008 10:25 pm
by neon
3. How many of you have succeded making a operating system with a object oriented language compiler and standard library (that means C++) and kept an object oriented structure?
...Are you looking for a number here? Im sure plenty of people here use C++. My new systems design is an example and is very object oriented.
I fail to see how people constantly disregard C++ as being object-oriented. Its not quite high level and not quite low level but its classes provide a lot of flexibility and satisfy the "OOP" definition. The whole point of C++ was to add object-oriented programming to C.
<opinion>
Agreed. classes, namespaces, multiple inheritance are enough for me to want to choose C++ over C any day; and none of those require a runtime. They provide a much cleaner way of writing object oriented code then C ever could. In this respect C is more lower level then C++; but I prefer cleaner code and design.
</opinion>
Re: Osdev standards...
Posted: Sun Dec 14, 2008 10:40 pm
by thre3dee
neon wrote:3. How many of you have succeded making a operating system with a object oriented language compiler and standard library (that means C++) and kept an object oriented structure?
...Are you looking for a number here? Im sure plenty of people here use C++. My new systems design is an example and is very object oriented.
I fail to see how people constantly disregard C++ as being object-oriented. Its not quite high level and not quite low level but its classes provide a lot of flexibility and satisfy the "OOP" definition. The whole point of C++ was to add object-oriented programming to C.
<opinion>
Agreed. classes, namespaces, multiple inheritance are enough for me to want to choose C++ over C any day; and none of those require a runtime. They provide a much cleaner way of writing object oriented code then C ever could. In this respect C is more lower level then C++; but I prefer cleaner code and design.
</opinion>
Exactly. C++ falls under a
category of object-oriented programming called
class-based programming. But its still an object-oriented programming language whether you want it to be or not.
Re: Osdev standards...
Posted: Mon Dec 15, 2008 12:57 pm
by madeofstaples
thre3dee wrote:Love4Boobies wrote:C++ is a higher level language and has all sorts of stuff that you'll need to write yourself (standard library); however, OOP support is not one of these things.
I fail to see how people constantly disregard C++ as being object-oriented. Its not quite high level and not quite low level but its classes provide a lot of flexibility and satisfy the "OOP" definition. The whole point of C++ was to add object-oriented programming to C.
I added the entire sentence back into Love4Boobies's quote because as it reads, it appears he is saying that the OOP aspect of C++ is not something for which the OS developer has to write specific support (as opposed to the C++ standard library).
In other words, rather than "disregard[ing] C++ as being object-oriented," it would seem Love4Boobies actually asserted that C++ is inherently object-oriented.
Re: Osdev standards...
Posted: Mon Dec 15, 2008 9:27 pm
by cg123
As much as I love Python, I'm going to have to set you straight on that. Python could perhaps be called fast in comparison to a turing machine implemented in Brainfuck. With a stretch of imagination, it could be called fast in comparison to Perl. But in any other situation? Python is dead slow. Psyco and the likes help, but you're still going to have serious performance problems with anything time-critical. That's even ignoring the fact that it takes a bit of a stretch of imagination to say it can be compiled at all.
However, I'd say it's extremely plausible to use RPython.