base cross-platform kernel system

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
Post Reply
durand
Member
Member
Posts: 193
Joined: Wed Dec 21, 2005 12:00 am
Location: South Africa
Contact:

base cross-platform kernel system

Post by durand »

I'm busy making my kernel a lot more portable and the changes have shown me exactly how much of the kernel is actually just logic versus hardware-specific implementation.

So, assuming that you have the basic logic section - the kernel proper - and it has a list of available, generic functions which the hardware-specific sections should provide, the matter of porting merely becomes implementing those funtions on each platform you want.

But then I thought, what if you were to just provide the hardware-specific sections and have that jump into an empty logic section?

Also, what if the logic section were to have certain guarantees about the enviroment it runs in: (no interrupts, paging, safe to switch tasks, safe to acces memory, ... etc ... or reasonable emulations of those abilities )

What you'd get is a cross-platform kernel base on which you could implement different logic - (and therefore different kernels? )

So... yeah... is there such a thing out there already? A cross-platform kernel base?

Like ... cut, paste, insert logic, run ...
User avatar
Solar
Member
Member
Posts: 7615
Joined: Thu Nov 16, 2006 12:01 pm
Location: Germany
Contact:

Re:base cross-platform kernel system

Post by Solar »

OSKit / OSLib might be somewhat in that direction; I haven't looked at them in detail.

But what if I want a logic that breaks common assumptions, naming conventions, and basic techniques?

That's why I didn't look at OSKit / OSLib en detail - I didn't think I could write better logic, but I thought I could give better structure.

But it's only me. If you feel like it, go for it!
Every good solution is obvious once you've found it.
durand
Member
Member
Posts: 193
Joined: Wed Dec 21, 2005 12:00 am
Location: South Africa
Contact:

Re:base cross-platform kernel system

Post by durand »

I was thinking of providing my cross-platform base once as a bare system once I'm done with it... leaving out the logic. That's if something like it doesn't exist already.

Maybe it would be useful in a quick, development kind of environment. I mean, imagine being able to quickly develop a small cool application in a few minutes and have it cross-compile to multiple platforms without the need to install other stuff besides the kernel.

Kind of like, "Okay class, today we're going to develop a <insert something simple> and it's going to run on intel, sparc and powerpc. You have an hour. Go."
User avatar
Candy
Member
Member
Posts: 3882
Joined: Tue Oct 17, 2006 11:33 pm
Location: Eindhoven

Re:base cross-platform kernel system

Post by Candy »

durand wrote: Kind of like, "Okay class, today we're going to develop a <insert something simple> and it's going to run on intel, sparc and powerpc. You have an hour. Go."
You can do most of those things with some weird thing nowadays called "unix". It runs on most/all of these systems and is very portable if you code carefully.
User avatar
Solar
Member
Member
Posts: 7615
Joined: Thu Nov 16, 2006 12:01 pm
Location: Germany
Contact:

Re:base cross-platform kernel system

Post by Solar »

...or Java, or Perl/Tk, or Python... where the language runtime doubles as "kernel".

Rule #1 of Software Engineering: Define the purpose of your design clearly. Be specific about it.
Every good solution is obvious once you've found it.
durand
Member
Member
Posts: 193
Joined: Wed Dec 21, 2005 12:00 am
Location: South Africa
Contact:

Re:base cross-platform kernel system

Post by durand »

:)

Yeah but i was talking about a kernel base and not really a system. Sure my example sucked ;) but we're all here because we share the same interest of OS development.

So, with that in mind, I was asking if something like it already existed? Would it be of use to anyone? Would people use it?

It does kind of limit you to use the same structure as the base (paging, protected, etc) ... I hadn't thought of that. And none of us would be here if we didn't want to try something different ;) So maybe it wouldn't have a place here.
User avatar
Pype.Clicker
Member
Member
Posts: 5964
Joined: Wed Oct 18, 2006 2:31 am
Location: In a galaxy, far, far away
Contact:

Re:base cross-platform kernel system

Post by Pype.Clicker »

actually, when i see code for paging management in Linux, it always give me the feeling things have been over-complicated and do not get the full potential of the target machine ... one of the reason being the very low-level multiplatform behaviour.
Post Reply