Robert Brewer | 7 Jul 2005 23:25
Picon

how does it boot?

I downloaded the uuu iso image from the website and tried it out 
under qemu on my Linux box.  Was able to do a couple of
shell commands.

I'm quite interested in reading through the code more, but 
I'd really like to understand what parts are "live" and "dead"
in the source tree right now, and just how it boots up.

Is anyone willing to point me in the right direction?
Example answers are:
  The entry point to the OS which is called by the boot
   loader is here...
  None of the OSkit stuff is used anymore...
  etc.

Thanks!

-Rob
--

-- 
Robert W. Brewer
Phil Frost | 8 Jul 2005 02:14

Re: how does it boot?

On Thu, Jul 07, 2005 at 05:25:21PM -0400, Robert Brewer wrote:
> I downloaded the uuu iso image from the website and tried it out 
> under qemu on my Linux box.  Was able to do a couple of
> shell commands.
> 
> I'm quite interested in reading through the code more, but 
> I'd really like to understand what parts are "live" and "dead"
> in the source tree right now, and just how it boots up.
> 
> Is anyone willing to point me in the right direction?
> Example answers are:
>   The entry point to the OS which is called by the boot
>    loader is here...
>   None of the OSkit stuff is used anymore...
>   etc.

The entry point is 'main' in arch/whatever/main.c.

The OSKit stuff is used on the CD image. However, the CD images are
rather old. Not too long ago, it was decided to get some of the higher
level features to work on a Linux host before trying to get everything
to run on the metal. If you are playing with the code in darcs, you
probably want to build for Linux. You can try building for the ia32
host, but it might take a bit of tweaking to get working again.

Right now, when running on Linux, most of the code is dead, since much
of the code are drivers which are not needed, and what isn't a driver is
orthogonal persistence stuff that is not complete.

Also as a side note, when building for Linux you will notice some things
(Continue reading)

Jacques Mony | 8 Jul 2005 03:03
Picon

Re: how does it boot?

To add a bit to what Phil said, both ckpt and the user-space threads can be disabled using #define, this will allow easy testing without the hassle to build those libraries (as they don't provide much functionalities anyways).

On 7/7/05, Phil Frost <indigo <at> bitglue.com> wrote:
On Thu, Jul 07, 2005 at 05:25:21PM -0400, Robert Brewer wrote:
> I downloaded the uuu iso image from the website and tried it out
> under qemu on my Linux box.  Was able to do a couple of
> shell commands.
>
> I'm quite interested in reading through the code more, but
> I'd really like to understand what parts are "live" and "dead"
> in the source tree right now, and just how it boots up.
>
> Is anyone willing to point me in the right direction?
> Example answers are:
>   The entry point to the OS which is called by the boot
>    loader is here...
>   None of the OSkit stuff is used anymore...
>   etc.

The entry point is 'main' in arch/whatever/main.c.

The OSKit stuff is used on the CD image. However, the CD images are
rather old. Not too long ago, it was decided to get some of the higher
level features to work on a Linux host before trying to get everything
to run on the metal. If you are playing with the code in darcs, you
probably want to build for Linux. You can try building for the ia32
host, but it might take a bit of tweaking to get working again.

Right now, when running on Linux, most of the code is dead, since much
of the code are drivers which are not needed, and what isn't a driver is
orthogonal persistence stuff that is not complete.

Also as a side note, when building for Linux you will notice some things
related to ckpt. It was hoped that ckpt would provide most of the things
needed for persistence. It has problems though, and isn't terribly
interesting as it's used now, so it is probably easiest to disable it
with the #define at the top of arch/linux/main.c.

_______________________________________________
Uuu-devel mailing list
Uuu-devel <at> unununium.org
http://unununium.org/cgi-bin/mailman/listinfo/uuu-devel



--
Jacques Mony
Programmeur-Analyste
Les services conseils Systématix inc.
_______________________________________________
Uuu-devel mailing list
Uuu-devel <at> unununium.org
http://unununium.org/cgi-bin/mailman/listinfo/uuu-devel
Robert Brewer | 12 Jul 2005 18:00
Picon

got linux version running... now what?

Thanks for the tips, I built the user-space linux version of uuu from
darcs and ran it.
I poked around in the python interpreter and got the shell going,
and also ran gatest.  

So now I'm again wondering just what it is I have.  I've been wrapping
my brain around capability-based systems and single-level stores
for the past couple of weeks and liking the ideas.  Also, I've gone
through the past few months of mailing list archives and getting
into Phil's insights on design.  It seems that Phil's ideas are
all about minimizing the impedance mismatch between what
an application wants to do and what the underlying system
abstraction supports, as well as carefully unifying similar
abstractions as much as possible.  

The idea of no address spaces, no separation of kernel and
user space sounded pretty strange, but upon more reflection
I'm seeing that capabilities could allow that to work.  The "kernel"
can follow POLA and only give capabilities that each object
actually needs, and with no other way to access those 
functionalities, there is no need for memory protection.  Is that
the idea?

When I look at it that way, I find myself wondering why
we need MMU hardware.  I start questioning a lot of
things about today's systems.  But then I figure a lot
of that hardware must be there for a reason.  I guess
the MMU is still needed to efficiently manage the single
level store.  So rather than using its protection abilities 
to prevent "processes" from stepping on each other,
its main purpose is to efficiently fault in pages and
handle copy-on-write.  The processes can't step 
on each other because they 
can't construct their own addresses, and so have
no way of performing unsafe actions on other
processes.

On the other hand, it seems to me that for performance
and convenience sake, there must be some different
"layers" to what is happening.  For example, I'd really
like to pass around capabilities for space usage, processor
usage, network bandwidth, etc.  But every python
function will need to use some space and some processor.
Taken to its logical conclusion, I would need to pass
a space-bank reference and a processor-meter reference
into every function.  I don't want to program like that.
I would want a way of specifying defaults for those
in a section of code.  Would aspect-oriented programming help?
Would I set some sort of global variable?  Maybe I need a separate
"capability stack" that is logically passed into each function
I call.  Its purpose is to pass heavily-used capabilities
like space and processor time.  
Often I would pass the current frame on the capability
stack to my next function, so I would do nothing.  Most
other capabilities would be passed as explicit arguments.
Well, that's just some capability meandering...

So what are some items on the todo list?  I see a lot of 
pythonized device-driver type of code in pymodules.  Are
they relevant with the Linux userspace version?

-Rob
--

-- 
Robert W. Brewer
Phil Frost | 12 Jul 2005 19:16

Re: got linux version running... now what?

On Tue, Jul 12, 2005 at 12:00:06PM -0400, Robert Brewer wrote:
> Thanks for the tips, I built the user-space linux version of uuu from
> darcs and ran it.
> I poked around in the python interpreter and got the shell going,
> and also ran gatest.  

I don't think gatest really applies to the linux version. Did it do
anything interesting?

> So now I'm again wondering just what it is I have.  I've been wrapping
> my brain around capability-based systems and single-level stores
> for the past couple of weeks and liking the ideas.  Also, I've gone
> through the past few months of mailing list archives and getting
> into Phil's insights on design.  It seems that Phil's ideas are
> all about minimizing the impedance mismatch between what
> an application wants to do and what the underlying system
> abstraction supports, as well as carefully unifying similar
> abstractions as much as possible.  
> 
> The idea of no address spaces, no separation of kernel and
> user space sounded pretty strange, but upon more reflection
> I'm seeing that capabilities could allow that to work.  The "kernel"
> can follow POLA and only give capabilities that each object
> actually needs, and with no other way to access those 
> functionalities, there is no need for memory protection.  Is that
> the idea?

That sounds like the right idea. Try not to even use "kernel" in the
context of unununium, because it doesn't really mean anything. The agent
that will be giving capabilities will ultimately be the user, although
quite often indirectly.

> When I look at it that way, I find myself wondering why
> we need MMU hardware.  I start questioning a lot of
> things about today's systems.  But then I figure a lot
> of that hardware must be there for a reason.  I guess
> the MMU is still needed to efficiently manage the single
> level store.  So rather than using its protection abilities 
> to prevent "processes" from stepping on each other,
> its main purpose is to efficiently fault in pages and
> handle copy-on-write.  The processes can't step 
> on each other because they 
> can't construct their own addresses, and so have
> no way of performing unsafe actions on other
> processes.
>
> On the other hand, it seems to me that for performance
> and convenience sake, there must be some different
> "layers" to what is happening.  For example, I'd really
> like to pass around capabilities for space usage, processor
> usage, network bandwidth, etc.  But every python
> function will need to use some space and some processor.
> Taken to its logical conclusion, I would need to pass
> a space-bank reference and a processor-meter reference
> into every function.  I don't want to program like that.
> I would want a way of specifying defaults for those
> in a section of code.  Would aspect-oriented programming help?
> Would I set some sort of global variable?  Maybe I need a separate
> "capability stack" that is logically passed into each function
> I call.  Its purpose is to pass heavily-used capabilities
> like space and processor time.  
> Often I would pass the current frame on the capability
> stack to my next function, so I would do nothing.  Most
> other capabilities would be passed as explicit arguments.
> Well, that's just some capability meandering...

The MMU is still needed to service page faults, just as it is used to
implement swap in any one address space now. If we had cpus with huge
address spaces, big enough to hold all data we would ever want, the MMU
would be sufficient.

However, anyone with even a small mp3 collection has more than 4 GB of
data, so there must be some way to reference it all. A VM of some sort
is already required for secure operation, so that VM layer can be used
to solve the small address space problem. In the VM, a reference will
not be a 32 bit pointer to some address space, but instead something
bigger. Maybe there will be some virtual 64 bit (or bigger...64 bits is
only 16 exabytes) address space, or maybe instead of pointers to some
location they will be sequential object IDs or, something like that. Of
course it would be terribly slow to implement this simply, so the VM
would need to perform some compilation to perform reasonably.

As far as holding references to commonly needed resources, each language
already has some way to deal with this problem. In Python for example,
references are received by __init__ and stored in a class instance;
methods of that class can then access them later. Functional languages
have closures, etc.

> So what are some items on the todo list?  I see a lot of 
> pythonized device-driver type of code in pymodules.  Are
> they relevant with the Linux userspace version?

Probably not. Right now, Unununium in linux is nearly identical to the
python interactive mode. Most of the code is driver stuff that no longer
applies.

The next goal is to get orthogonal persistence working in some form.
There is some work in this area; take a look at
pymodules/uuu/linux/paging.py and pymodules/uuu/tstorage.py for a start.
Neither of these are beyond the experimental stage, so don't let them
box your creativity. One goal I did have in mind when writing them was
to keep the platform specific code to a minimum.
Phil Frost | 13 Jul 2005 13:55

Re: got linux version running... now what?

On Tue, Jul 12, 2005 at 08:59:57PM -0400, Robert Brewer wrote:
> On 7/12/05, Phil Frost <indigo <at> bitglue.com> wrote:
> Ok, that is sounding a lot like EROS (96-bit capabilities) or even
> more like IBM's AS/400 architecture (128-bit capabilities with 
> runtime translation by several layers of VMs to get to actual
> machine code).  I was thinking of something like that too since
> python's references are probably only 32-bit on an IA32 architecture.
> Pypy might be very interesting to get something like that going.

Pypy is nifty, but we are already slow enough with cpython. Also I don't
want to put too much work into python because I'd rather put work into a
better language. Writing a new language is a big deal though, which I am
trying hard to avoid.

> > The next goal is to get orthogonal persistence working in some form.
> > There is some work in this area; take a look at
> > pymodules/uuu/linux/paging.py and pymodules/uuu/tstorage.py for a start.
> > Neither of these are beyond the experimental stage, so don't let them
> > box your creativity. One goal I did have in mind when writing them was
> > to keep the platform specific code to a minimum.
> 
> Ok, I read through those.  Looks pretty nifty.  Am I correct that the next step
> on that code may be to wire it into python's allocator in some fashion?

Probably not. One of the goals of Uuu's persistence is to support any
language. The persistor in my mind knows only about pages of ram, and
nothing about any object structure the language in use might impose. It
doesn't even distinguish between data and code.

My stratgey for implementing this on linux was to install a SIGSEGV
handler and use mprotect to mark pages as readonly. Together with the
memory map available from /proc/self/maps, this is a fairly good
approximation of a typical MMU. Of course, I never got this fully
working so it's unknown if it is a good idea or not.
John Kintzele | 11 Jul 2005 18:11
Picon
Favicon

Is this project still ongoing?

I am interested in what you are attempting, but the
website hasn't been updated for some time.  Is the
project still active?  Yours,

John Kintzele

John Kintzele
919-271-6737 cell
919-380-9682 home
919-217-6705 work
john <at> kintzele.com

		
____________________________________________________
Sell on Yahoo! Auctions – no fees. Bid on great items.  
http://auctions.yahoo.com/
Phil Frost | 13 Jul 2005 16:12

Re: Is this project still ongoing?

On Mon, Jul 11, 2005 at 09:11:17AM -0700, John Kintzele wrote:
> I am interested in what you are attempting, but the
> website hasn't been updated for some time.  Is the
> project still active?  Yours,
> 
> John Kintzele

Probably. It's been slow due to lack of time, not lack of interest.
Jacques Mony | 13 Jul 2005 16:21
Picon

Re: Is this project still ongoing?

Even if there is not real development at the moment, ideas are still welcome! There is nothing new, but the project is not dead.

On 7/13/05, Phil Frost <indigo <at> bitglue.com> wrote:
On Mon, Jul 11, 2005 at 09:11:17AM -0700, John Kintzele wrote:
> I am interested in what you are attempting, but the
> website hasn't been updated for some time.  Is the
> project still active?  Yours,
>
> John Kintzele

Probably. It's been slow due to lack of time, not lack of interest.

_______________________________________________
Uuu-devel mailing list
Uuu-devel <at> unununium.org
http://unununium.org/cgi-bin/mailman/listinfo/uuu-devel



--
Jacques Mony
Programmeur-Analyste
Les services conseils Systématix inc.
_______________________________________________
Uuu-devel mailing list
Uuu-devel <at> unununium.org
http://unununium.org/cgi-bin/mailman/listinfo/uuu-devel
Robert Brewer | 13 Jul 2005 17:06
Picon

Re: got linux version running... now what?

I thought the SIGSEGV handler and mmaping was pretty neat.
I wanted to verify that Linux would restart the process
at the faulting memory access after the signal handler returns,
but then realized that was more than 3 lines of test code.  :)

POSIX specs say it is undefined what state the process
is in under those conditions, so Linux is free to do
whatever I guess.

-Rob
--

-- 
Robert W. Brewer

Gmane