new OO OS

M

Michael Groys

Hello all,
I'm looking for collaborators to develop new object oriented operating
system.
As most of the software development had moved to the OO languages so
the OS must move towards OO OS.
I think that it will be very interesting project with big potential.
So everybody is invited.
More information you can find at,
http://www.yaooos.org
Michael
 
V

Victor Bazarov

Michael Groys said:
I'm looking for collaborators to develop new object oriented operating
system.
As most of the software development had moved to the OO languages so
the OS must move towards OO OS.

You must be thinking of BeOS...
I think that it will be very interesting project with big potential.

So apparently did the developers of BeOS...
 
M

Michael Groys

Victor said:
You must be thinking of BeOS...




So apparently did the developers of BeOS...
Two comments.
1. As I understand the initial BeOs is not alive any more.
(be site is defunct)
2. As far as I know BeOs was good operating system with OO api and may
be OO kernel (may be I'm wrong). I'm talking about the whole object
oriented distributed environment. Where the applications and USER
access objects and not files by terms of OO interface. Additional
information appears in the site ( http://www.yaooos.org ).

If you think that what I'm talking about is actually BeOs,
then let me know and I will really appreciate this.
Best regards, Michael.
 
N

Noah Roberts

Michael said:
Two comments.
1. As I understand the initial BeOs is not alive any more.
(be site is defunct)
2. As far as I know BeOs was good operating system with OO api and may
be OO kernel (may be I'm wrong). I'm talking about the whole object
oriented distributed environment. Where the applications and USER
access objects and not files by terms of OO interface. Additional
information appears in the site ( http://www.yaooos.org ).

If you think that what I'm talking about is actually BeOs,
then let me know and I will really appreciate this.
Best regards, Michael.

What architecture are you going with? I realize OO is part of it, but
there is more needed. Monolithic, micro, exokernel, ..., something new?

This is probably an inappropriate forum for this type of discussion.
Something about operating systems would be better. There is one like
"alt.os.research" or something. I am finding it interesting, but
someone is bound to complain.
 
M

Michael Groys

Noah said:
What architecture are you going with? I realize OO is part of it, but
there is more needed. Monolithic, micro, exokernel, ..., something new?
Good OO design will allow to build very modular kernel that corresponds
to microkernel architecture. The "core" of the kernel will implement
only basic objects and will be responsible for redirecting calls from
caller to object owner. In this way the system can be easily extended.
This is probably an inappropriate forum for this type of discussion.
Something about operating systems would be better. There is one like
"alt.os.research" or something. I am finding it interesting, but
someone is bound to complain.
I chose this forum because it deals with C++ which I plan to use as a
basic language for the system.
Michael.
 
J

Jack Klein

Hello all,
Hello.

I'm looking for collaborators to develop new object oriented operating
system.

The above is a statement that I am willing to accept at face value.
As most of the software development had moved to the OO languages so
the OS must move towards OO OS.

The above is a statement that I am NOT be willing to accept at face
value. What proof or arguments can you offer that operating systems
"must" become object oriented?
 
M

Michael Groys

Jack said:
The above is a statement that I am NOT be willing to accept at face
value. What proof or arguments can you offer that operating systems
"must" become object oriented?

My be word "must" is not so good. This is actually my vision which is
based on some assumptions and some experience both as devloper and
user under/of different operating systems.
In any case I tried to provide some arguments (I have few) in my site.
If you want to discuss them then you are very wellcome.
But I don't think that usenet is good place to present them.
 
V

Victor Bazarov

Michael Groys said:
My be word "must" is not so good. This is actually my vision which is
based on some assumptions and some experience both as devloper and
user under/of different operating systems.
In any case I tried to provide some arguments (I have few) in my site.
If you want to discuss them then you are very wellcome.
But I don't think that usenet is good place to present them.

Typical...
 
T

Thomas Matthews

Michael said:
Hello all,
I'm looking for collaborators to develop new object oriented operating
system.
As most of the software development had moved to the OO languages so
the OS must move towards OO OS.
I think that it will be very interesting project with big potential.
So everybody is invited.
More information you can find at,
http://www.yaooos.org
Michael

Search the web for "Nucleus Plus". I'm sure how far into OO
the operating system goes, but it's a lot closer than a procedural
operating system.

To increase the potential, allow users to pick and choose at the
"advanced" features. Many embedded systems, which are the primary
customers of OTS operating systems, don't have much room for
large operating systems and only want the stuff they need, no more.
For example, a vending machine is too simple to implement the
Windows CE operating system. A high end laser printer, is another
story.

--
Thomas Matthews

C++ newsgroup welcome message:
http://www.slack.net/~shiva/welcome.txt
C++ Faq: http://www.parashift.com/c++-faq-lite
C Faq: http://www.eskimo.com/~scs/c-faq/top.html
alt.comp.lang.learn.c-c++ faq:
http://www.raos.demon.uk/acllc-c++/faq.html
Other sites:
http://www.josuttis.com -- C++ STL Library book
 
M

Michael Groys

Thomas said:
Search the web for "Nucleus Plus". I'm sure how far into OO
the operating system goes, but it's a lot closer than a procedural
operating system.

To increase the potential, allow users to pick and choose at the
"advanced" features. Many embedded systems, which are the primary
customers of OTS operating systems, don't have much room for
large operating systems and only want the stuff they need, no more.
For example, a vending machine is too simple to implement the
Windows CE operating system. A high end laser printer, is another
story.

You are right and indeed OO model allows to perform this easily
by allowing to have efficient microkernel architecture.
 
D

DeMarcus

There is one really bad thing with object oriented languages:

My view of objects and your view of objects may differ a lot.
That's the beauty of plain C API:s. When I get the API from a
supplier I wrap it within my objects seen from my point of view.

Take threads for instance. I don't like the Java
overload-thread::run()-style of threads. What does a typical
thread class look like from your point of view? (or anyone else
reading this)

Best regards
Daniel Marcus


PS. I like your idea, but I may or may not like your view of
objects.
 
S

Stewart Gordon

While it was 1/2/04 2:26 pm throughout the UK, Michael Groys sprinkled
little black dots on a white screen, and they fell thus:
Hello all,
I'm looking for collaborators to develop new object oriented operating
system.
As most of the software development had moved to the OO languages so
the OS must move towards OO OS.
<snip>

I suppose that would be a nice concept. All the better if it can be
made compatible with C++, D, Object Pascal, ADD 1 TO COBOL GIVING COBOL
:) and whatever other OO languages you care to think of....

Further idea: develop an OS with built-in garbage collection facilities.

Stewart.
 
C

Claudio Puviani

Stewart Gordon said:
While it was 1/2/04 2:26 pm throughout the UK, Michael Groys sprinkled
little black dots on a white screen, and they fell thus:
<snip>

I suppose that would be a nice concept. All the better if it can be
made compatible with C++, D, Object Pascal, ADD 1 TO COBOL GIVING COBOL
:) and whatever other OO languages you care to think of....

Further idea: develop an OS with built-in garbage collection facilities.

I've been trying to avoid this senseless thread, but this desperately needs to
be said. All of the cutesy ideas about OS design that keep cropping up: BEEN
DONE, FOLKS! Been done BETTER. Been done by more competent people. Been written
about in dozens of books and hundreds of articles. Can be found in herds through
judicious use of Google.

Time to move these naive sugar-cane-in-the-sky inspirations to a more
appropriate forum. Try comp.l337.kewl.kewl.kewl

Claudio Puviani
 
M

Michael Groys

DeMarcus said:
There is one really bad thing with object oriented languages:

My view of objects and your view of objects may differ a lot.
That's the beauty of plain C API:s. When I get the API from a
supplier I wrap it within my objects seen from my point of view.

Take threads for instance. I don't like the Java
overload-thread::run()-style of threads. What does a typical
thread class look like from your point of view? (or anyone else
reading this)

Best regards
Daniel Marcus


PS. I like your idea, but I may or may not like your view of
objects.

It is indeed very important point,
because I want the new OS to be as programmer friendly as possible.
Still I think that it solvable problem.
First of all I think we can relatively easy define set of objects that
is managed by each module of OS.
A bit harder but still easy to define the objects' functionality.
The most problematic stage is to define the API.
For this purpose we can use Internet society (for example this forum).

And I want to ask people to write here their suggestions about the
set of classes and their api, that new OS must provide.

PS.
How do you like to see Thread class?
In any case we can provide several interfaces,
but their functionality must include the possibility of
execution of some method of users object, to allow user
to provide additional data to the newly created thread.

Best regards, Michael
 
D

DeMarcus

To me a thread is a task that shall be executed, and most often
it's not an object. Therefore I'd like to see the threads as a
normal method that shall be run, or in this case, a callback
just as in pthreads. To clearify what I mean; I want to be able
to run an arbitrary method within an object just as I run it
normally, sending exaclty the parameters required for that method
and get the result whatever it is.

Let's say I have a class like this:

class Cafe : public Interface // explained later
{
public:

Coffe makeCoffe( bool sugar, bool milk );
Cake makeCake( int nStrawberries );
};

Then I certainly don't want the class to know anything about threads
(maybe reentrance though) meanwhile the user of it may want to run the
methods of it within different threads.

Now you think; "Hmm, callbacks in C++, this may be tricky with
method pointers to some base object. We'll easily run into some tacky
mesh of templates." But there's a way to solve it that I use today.
I use double dispatch for my thread callbacks. It's clean and simple,
BUT it demands that you conform to an Interface/Interaction-standard.

Now we create interactions:

class MakeCoffee : public Interaction
{
public:

// Parameters
bool sugar;
bool milk;

// Results
Coffee coffee;


virtual void executeOn( Interface* interface )
{
Cafe cafe = dynamic_cast<Cafe*>(interface);
if( cafe == 0 )
throw Exception();
coffee = cafe->makeCoffee( sugar, milk );
}
};

class Thread
{
public:

void run( Interface* interface, Interaction* interaction )
{
interaction->executeOn( interface );
}
};

int main( void )
{
Cafe cafe;
MakeCoffee makeCoffee;
Thread thread;

makeCoffee.milk = true;
makeCoffee.sugar = false;

thread.run( &cafe, &makeCoffe );
thread.wait();

if( makeCoffe.coffee.isGood() )
return 0;

return 1;
}


This is my view of threads. I don't know if anyone else like it.

Best Regards
Daniel Marcus
 
C

Claudio Puviani

DeMarcus said:
Let's say I have a class like this:

class Cafe : public Interface // explained later
[...]

class MakeCoffee : public Interaction

[...]

class Thread
{
public:

void run( Interface* interface, Interaction* interaction )
{
interaction->executeOn( interface );
}
};

Why be so intrusive? Classes shouldn't have to inherit from some arbitrary class
just to be usable in a given context. If you want to be able to call just about
anything, create a framework of functors that allow you to wrap regular
functions and method invocations and have your threads invoke the functor. Now,
the rest of the system isn't artificially coupled with your threading libraries
and you don't introduce a massively subjective view of "what threads really
mean".

Claudio Puviani

"Low coupling. It's not just for breakfast any more."
 
D

DeMarcus

Claudio said:
DeMarcus said:
Let's say I have a class like this:

class Cafe : public Interface // explained later
[...]

class MakeCoffee : public Interaction

[...]

class Thread
{
public:

void run( Interface* interface, Interaction* interaction )
{
interaction->executeOn( interface );
}
};


Why be so intrusive? Classes shouldn't have to inherit from some arbitrary class
just to be usable in a given context. If you want to be able to call just about
anything, create a framework of functors that allow you to wrap regular
functions and method invocations and have your threads invoke the functor. Now,
the rest of the system isn't artificially coupled with your threading libraries
and you don't introduce a massively subjective view of "what threads really
mean".

Claudio Puviani

"Low coupling. It's not just for breakfast any more."

Yes, you're right. I have to go through my code and see what I really
though when I designed it. But our solutions are quite close ain't
they? I mean, if we remove the inheritance of Interface from class Cafe
and change MakeCoffee to

class MakeCoffe : public Functor
{
public:
MakeCoffe( void* instance );

virtual void execute( void )
{
dynamic_cast<Cafe*>(instance)->makeCoffe( sugar, milk );
}
};

and change Thread::run() to

void run( Functor* functor )
{
functor->execute();
}

ain't we then speaking almost the same language here?

I agree with your idea, I just have make sure I got it right to be able
to improve my framework.


Daniel Marcus


PS. Also to Michael Groys; seconds after I posted my message I realized
that my situation actually can be solved quite easy with the old Java-
overload-thread::run()-style as well.
 
M

Michael Groys

DeMarcus said:
Claudio said:
DeMarcus said:
Let's say I have a class like this:

class Cafe : public Interface // explained later
[...]

class MakeCoffee : public Interaction

[...]

class Thread
{
public:

void run( Interface* interface, Interaction* interaction )
{
interaction->executeOn( interface );
}
};



Why be so intrusive? Classes shouldn't have to inherit from some
arbitrary class
just to be usable in a given context. If you want to be able to call
just about
anything, create a framework of functors that allow you to wrap regular
functions and method invocations and have your threads invoke the
functor. Now,
the rest of the system isn't artificially coupled with your threading
libraries
and you don't introduce a massively subjective view of "what threads
really
mean".

Claudio Puviani

"Low coupling. It's not just for breakfast any more."

Yes, you're right. I have to go through my code and see what I really
though when I designed it. But our solutions are quite close ain't
they? I mean, if we remove the inheritance of Interface from class Cafe
and change MakeCoffee to

class MakeCoffe : public Functor
{
public:
MakeCoffe( void* instance );

Why you provide it as void* and not just Cafe*
virtual void execute( void )
{
dynamic_cast<Cafe*>(instance)->makeCoffe( sugar, milk );
}
};

and change Thread::run() to

void run( Functor* functor )
{
functor->execute();
}

ain't we then speaking almost the same language here?

I agree with your idea, I just have make sure I got it right to be able
to improve my framework.


Daniel Marcus


PS. Also to Michael Groys; seconds after I posted my message I realized
that my situation actually can be solved quite easy with the old Java-
overload-thread::run()-style as well.

I also think that in the case of thread object as in the case of other
callbacks from OS to user app the best way will be to
handle them like the functors. Then programmer can easily provide his
class that will perform any task he wishes during the invocation
of the callback. (And he can store in that object any data he wants)

In addition we can provide template implementation of callback object
that will call some function of some object and provide it with
some argument, like following

template<class T, class A, class R=void>
class CallObj: public Thread
{
public:
typedef R (T::*F)(A&);
F m_f;
T* m_t;
A m_a;
CallObj(T* t, F f, const A& a)
: m_t(t), m_f(f), m_a(a)
{}
void run() {
(m_t->*m_f)(m_a);
}
};

class MyClass
{
public:
void print(const int& i) {
printf("i=%d\n", i);
}
};

int main() {
MyClass p;
CallObj<MyClass, const int> co(&p, &MyClass::print, 10);
co.run();
return 0;
}

Michael.
PS. this compiles under g++.
 
D

DeMarcus

Michael said:
Claudio said:
Let's say I have a class like this:

class Cafe : public Interface // explained later
[...]

class MakeCoffee : public Interaction

[...]

class Thread
{
public:

void run( Interface* interface, Interaction* interaction )
{
interaction->executeOn( interface );
}
};




Why be so intrusive? Classes shouldn't have to inherit from some
arbitrary class
just to be usable in a given context. If you want to be able to call
just about
anything, create a framework of functors that allow you to wrap regular
functions and method invocations and have your threads invoke the
functor. Now,
the rest of the system isn't artificially coupled with your threading
libraries
and you don't introduce a massively subjective view of "what threads
really
mean".

Claudio Puviani

"Low coupling. It's not just for breakfast any more."

Yes, you're right. I have to go through my code and see what I really
though when I designed it. But our solutions are quite close ain't
they? I mean, if we remove the inheritance of Interface from class Cafe
and change MakeCoffee to

class MakeCoffe : public Functor
{
public:
MakeCoffe( void* instance );


Why you provide it as void* and not just Cafe*
virtual void execute( void )
{
dynamic_cast<Cafe*>(instance)->makeCoffe( sugar, milk );
}
};

and change Thread::run() to

void run( Functor* functor )
{
functor->execute();
}

ain't we then speaking almost the same language here?

I agree with your idea, I just have make sure I got it right to be able
to improve my framework.


Daniel Marcus


PS. Also to Michael Groys; seconds after I posted my message I realized
that my situation actually can be solved quite easy with the old Java-
overload-thread::run()-style as well.

I also think that in the case of thread object as in the case of other
callbacks from OS to user app the best way will be to
handle them like the functors. Then programmer can easily provide his
class that will perform any task he wishes during the invocation
of the callback. (And he can store in that object any data he wants)

In addition we can provide template implementation of callback object
that will call some function of some object and provide it with
some argument, like following

template<class T, class A, class R=void>
class CallObj: public Thread
{
public:
typedef R (T::*F)(A&);
F m_f;
T* m_t;
A m_a;
CallObj(T* t, F f, const A& a)
: m_t(t), m_f(f), m_a(a)
{}
void run() {
(m_t->*m_f)(m_a);
}
};

class MyClass
{
public:
void print(const int& i) {
printf("i=%d\n", i);
}
};

int main() {
MyClass p;
CallObj<MyClass, const int> co(&p, &MyClass::print, 10);
co.run();
return 0;
}

Michael.
PS. this compiles under g++.


Yes, it sounds reasonable. Why I used void* (which to me feels scary in
a C++ environment) is because my brain went confused trying to put my
framework into a functor. I have one level higher of security where
some kind of functor are sent to an object, and it will only run if it
belongs to that object. A double dispatch thing. But that's my problem.
:)


~ Daniel
 
C

Claudio Puviani

DeMarcus said:
Yes, you're right. I have to go through my code and see what I really
though when I designed it. But our solutions are quite close ain't
they? I mean, if we remove the inheritance of Interface from class Cafe
and change MakeCoffee to

class MakeCoffe : public Functor
{
public:
MakeCoffe( void* instance );

virtual void execute( void )
{
dynamic_cast<Cafe*>(instance)->makeCoffe( sugar, milk );
}
};

and change Thread::run() to

void run( Functor* functor )
{
functor->execute();
}

The point was to NOT inherit from something in the framework. Let me be more
explicit. You need a base functor class, say 'ThreadFunctor' that provides a
virtual method that's invoked by your threads (or eventually your thread pools
and other dispatch mechanisms, but let's not get ahead of ourselves). I usually
make that operator()(), but that's almost arbitrary in this context. Now, if you
want to invoke method 'doSomething' from class 'Whatever', you create a new
functor class, as follows:

class WhateverFunctor : public ThreadFunctor
{
public:
WhateverFunctor(Whatever & obj, int arg)
: m_obj(obj)
, m_arg(arg)
{
}

// other ctors, dtor, etc.

virtual void operator()()
{
m_obj.doSomething(arg);
}

private:
Whatever & m_obj;
int m_arg;
};

See? The original class, 'Whatever', doesn't get modified. It doesn't depend on
the threading framework and if you ever need to port it to another environment,
you can do it without maintaining different versions for the two (or more)
environments.

A test to see if inheritance is gratuitous is to ask if a class really IS a
variant of another. Is a coffee maker an interface? No. Is a coffee maker a
functor? No. If I want to bludgeon someone with a coffee maker, does that make a
coffee maker a mace? No.

Think of it another way. If I did want to use a coffee maker as an interface, a
mace, a lucky charm, and a decoration, would the class look like this?

class CoffeeMaker : public Interface, public Mace, public LuckyCharm, public
Decoration {};

It's extreme, but that's exactly what happens when someone inherits from a
totally unrelated class just to shoehorn the class into a particular usage.

Claudio Puviani
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,160
Messages
2,570,890
Members
47,423
Latest member
henerygril

Latest Threads

Top