As part of my work on the iPhone VM I've started updating the isqueak.org site with documentation on the APIs that a VM maintainer needs to supply when building a new VM,
A starting set of pages is found at:
On Tue, Oct 14, 2008 at 08:19:23PM -0700, John M McIntosh wrote:
As part of my work on the iPhone VM I've started updating the isqueak.org site with documentation on the APIs that a VM maintainer needs to supply when building a new VM,
A starting set of pages is found at:
Great, this is good to see. Thanks for making it available.
Dave
Thank you, thank you, thank you, and Thank You! This sort of stuff may not be of interest to everyone, but when you need it you really need it and it can be truly invaluable. And I know compiling it and putting it into a readable form is not the most enjoyable task. I really appreciate your making the effort.
Thank you,
Ken
On Tue, 2008-10-14 at 20:19 -0700, John M McIntosh wrote:
As part of my work on the iPhone VM I've started updating the isqueak.org site with documentation on the APIs that a VM maintainer needs to supply when building a new VM,
A starting set of pages is found at:
What is sqInt? signed quad Int? Could you put an explanation of what each function is supposed to do? Are interrupts supported?
On 10/15/08, Ken Causey ken@kencausey.com wrote:
Thank you, thank you, thank you, and Thank You! This sort of stuff may not be of interest to everyone, but when you need it you really need it and it can be truly invaluable. And I know compiling it and putting it into a readable form is not the most enjoyable task. I really appreciate your making the effort.
Thank you,
Ken
On Tue, 2008-10-14 at 20:19 -0700, John M McIntosh wrote:
As part of my work on the iPhone VM I've started updating the isqueak.org site with documentation on the APIs that a VM maintainer needs to supply when building a new VM,
A starting set of pages is found at:
Thank you for the feedback, there is some assumptions that people looking at the docs would understand what sqInt is. However in reflection I do need to go back and add more details about the parms being passed, especially when they are data coming directly from oops objects in object space.
As for the explanation of each function, I'll see about adding more words. I currently have another twenty api calls documented, but yet not placed on the wiki, and there are a couple of more dozen yet to document.
The other task is to document the VM callback routines, not sure when that will occur.
Lastly I"m not sure what you mean by "Are interrupts supported?"
On Oct 15, 2008, at 9:17 PM, Kjell Godo wrote:
What is sqInt? signed quad Int? Could you put an explanation of what each function is supposed to do? Are interrupts supported?
On 10/15/08, Ken Causey ken@kencausey.com wrote:
Thank you, thank you, thank you, and Thank You! This sort of stuff may not be of interest to everyone, but when you need it you really need it and it can be truly invaluable. And I know compiling it and putting it into a readable form is not the most enjoyable task. I really appreciate your making the effort.
Thank you,
Ken
On Tue, 2008-10-14 at 20:19 -0700, John M McIntosh wrote:
As part of my work on the iPhone VM I've started updating the isqueak.org site with documentation on the APIs that a VM maintainer needs to supply when building a new VM,
A starting set of pages is found at:
I have noticed that Squeak seems to do Sockets by using Delays for x milliseconds and then waking back up to do something again.
So I tried to make a minimal Croquet like Router doing it that way using something that was already there as the pattern and it was kind of convoluted because it was going round and round checking on things. So what I was doing was going round and round checking on things also.
Wouldn't it be better to have network interrupts happen when new data has arrived? Or when all the data has been sent? Like some kind of callback?
Could I help with this documenting? I don't know how i might do that. But the VM is of interest to me. I would like to find out about how it all works. I tried to join the vm-dev mailing list but didn't get any response yet. I don't dislike documenting things like most people seem to. I would like to do it if i could somehow come to understand what is going on in the VM.
On 10/15/08, John M McIntosh johnmci@smalltalkconsulting.com wrote:
Thank you for the feedback, there is some assumptions that people looking at the docs would understand what sqInt is. However in reflection I do need to go back and add more details about the parms being passed, especially when they are data coming directly from oops objects in object space.
As for the explanation of each function, I'll see about adding more words. I currently have another twenty api calls documented, but yet not placed on the wiki, and there are a couple of more dozen yet to document.
The other task is to document the VM callback routines, not sure when that will occur.
Lastly I"m not sure what you mean by "Are interrupts supported?"
On Oct 15, 2008, at 9:17 PM, Kjell Godo wrote:
What is sqInt? signed quad Int? Could you put an explanation of what each function is supposed to do? Are interrupts supported?
On 10/15/08, Ken Causey ken@kencausey.com wrote:
Thank you, thank you, thank you, and Thank You! This sort of stuff may not be of interest to everyone, but when you need it you really need it and it can be truly invaluable. And I know compiling it and putting it into a readable form is not the most enjoyable task. I really appreciate your making the effort.
Thank you,
Ken
On Tue, 2008-10-14 at 20:19 -0700, John M McIntosh wrote:
As part of my work on the iPhone VM I've started updating the isqueak.org site with documentation on the APIs that a VM maintainer needs to supply when building a new VM,
A starting set of pages is found at:
Hello Kjell,
Documenting and improving Sockets are for sure something needed and it can help a lot us the web guys to improve Swazoo, Commanche etc to be more performant. So you are welcome and you can expect my help to your work.
Janko
Kjell Godo wrote:
I have noticed that Squeak seems to do Sockets by using Delays for x milliseconds and then waking back up to do something again.
So I tried to make a minimal Croquet like Router doing it that way using something that was already there as the pattern and it was kind of convoluted because it was going round and round checking on things. So what I was doing was going round and round checking on things also.
Wouldn't it be better to have network interrupts happen when new data has arrived? Or when all the data has been sent? Like some kind of callback?
Could I help with this documenting? I don't know how i might do that. But the VM is of interest to me. I would like to find out about how it all works. I tried to join the vm-dev mailing list but didn't get any response yet. I don't dislike documenting things like most people seem to. I would like to do it if i could somehow come to understand what is going on in the VM.
On 10/15/08, John M McIntosh johnmci@smalltalkconsulting.com wrote:
Thank you for the feedback, there is some assumptions that people looking at the docs would understand what sqInt is. However in reflection I do need to go back and add more details about the parms being passed, especially when they are data coming directly from oops objects in object space.
As for the explanation of each function, I'll see about adding more words. I currently have another twenty api calls documented, but yet not placed on the wiki, and there are a couple of more dozen yet to document.
The other task is to document the VM callback routines, not sure when that will occur.
Lastly I"m not sure what you mean by "Are interrupts supported?"
On Oct 15, 2008, at 9:17 PM, Kjell Godo wrote:
What is sqInt? signed quad Int? Could you put an explanation of what each function is supposed to do? Are interrupts supported?
On 10/15/08, Ken Causey ken@kencausey.com wrote:
Thank you, thank you, thank you, and Thank You! This sort of stuff may not be of interest to everyone, but when you need it you really need it and it can be truly invaluable. And I know compiling it and putting it into a readable form is not the most enjoyable task. I really appreciate your making the effort.
Thank you,
Ken
On Tue, 2008-10-14 at 20:19 -0700, John M McIntosh wrote:
As part of my work on the iPhone VM I've started updating the isqueak.org site with documentation on the APIs that a VM maintainer needs to supply when building a new VM,
A starting set of pages is found at:
So where do I start to study the VM? i have heard about a VM simulator inside of Squeak. But I don't know offhand where it is at in there.
What do you think about Exupery? Could this eventually be used to output the VM?
It would be cool if everything you need to make a VM for a platform were zipped into the VM maker for that platform including the right gcc and everything. The VM maker would unzip it all and install it. Or download it for you and install it. If you already had a C setup you could cancel the new gcc install.
I am not a C programmer but I can read it somewhat.
On 10/16/08, Janko Mivšek janko.mivsek@eranova.si wrote:
Hello Kjell,
Documenting and improving Sockets are for sure something needed and it can help a lot us the web guys to improve Swazoo, Commanche etc to be more performant. So you are welcome and you can expect my help to your work.
Janko
Kjell Godo wrote:
I have noticed that Squeak seems to do Sockets by using Delays for x milliseconds and then waking back up to do something again.
So I tried to make a minimal Croquet like Router doing it that way using something that was already there as the pattern and it was kind of convoluted because it was going round and round checking on things. So what I was doing was going round and round checking on things also.
Wouldn't it be better to have network interrupts happen when new data has arrived? Or when all the data has been sent? Like some kind of callback?
Could I help with this documenting? I don't know how i might do that. But the VM is of interest to me. I would like to find out about how it all works. I tried to join the vm-dev mailing list but didn't get any response yet. I don't dislike documenting things like most people seem to. I would like to do it if i could somehow come to understand what is going on in the VM.
On 10/15/08, John M McIntosh johnmci@smalltalkconsulting.com wrote:
Thank you for the feedback, there is some assumptions that people looking at the docs would understand what sqInt is. However in reflection I do need to go back and add more details about the parms being passed, especially when they are data coming directly from oops objects in object space.
As for the explanation of each function, I'll see about adding more words. I currently have another twenty api calls documented, but yet not placed on the wiki, and there are a couple of more dozen yet to document.
The other task is to document the VM callback routines, not sure when that will occur.
Lastly I"m not sure what you mean by "Are interrupts supported?"
On Oct 15, 2008, at 9:17 PM, Kjell Godo wrote:
What is sqInt? signed quad Int? Could you put an explanation of what each function is supposed to do? Are interrupts supported?
On 10/15/08, Ken Causey ken@kencausey.com wrote:
Thank you, thank you, thank you, and Thank You! This sort of stuff may not be of interest to everyone, but when you need it you really need it and it can be truly invaluable. And I know compiling it and putting it into a readable form is not the most enjoyable task. I really appreciate your making the effort.
Thank you,
Ken
On Tue, 2008-10-14 at 20:19 -0700, John M McIntosh wrote:
As part of my work on the iPhone VM I've started updating the isqueak.org site with documentation on the APIs that a VM maintainer needs to supply when building a new VM,
A starting set of pages is found at:
-- Janko Mivšek AIDA/Web Smalltalk Web Application Server http://www.aidaweb.si
On Thu, Oct 16, 2008 at 12:47 AM, Kjell Godo squeaklist@gmail.com wrote:
So where do I start to study the VM? i have heard about a VM simulator inside of Squeak. But I don't know offhand where it is at in there.
Check the mailing list archives for information about it.
What do you think about Exupery? Could this eventually be used to output the VM?
Earlier versions of the mac vm had Exupery support built in, there was no interest from anyone to make it work. So we currently wait on the Cog work Eliot is doing.
It would be cool if everything you need to make a VM for a platform were zipped into the VM maker for that platform including the right gcc and everything. The VM maker would unzip it all and install it. Or download it for you and install it. If you already had a C setup you could cancel the new gcc install.
Feel free to do this
John McIntosh writes:
On Thu, Oct 16, 2008 at 12:47 AM, Kjell Godo squeaklist@gmail.com wrote:
So where do I start to study the VM? i have heard about a VM simulator inside of Squeak. But I don't know offhand where it is at in there.
Check the mailing list archives for information about it.
What do you think about Exupery? Could this eventually be used to output the VM?
Earlier versions of the mac vm had Exupery support built in, there was no interest from anyone to make it work. So we currently wait on the Cog work Eliot is doing.
Exupery is continuing development. Progress is slowly moving towards a 1.0. It's still not quite reliable enough, but hopefully one more bug fix and it will be...
We've even had working Mac VMs built. The trick is to avoid gcc 4.0, which is unfortunately what Apple ships with XCode or to disable gcc optimisation.
Bryce
Kjell Godo schrieb:
So where do I start to study the VM? i have heard about a VM simulator inside of Squeak. But I don't know offhand where it is at in there.
VMMaker in squeaksource. Squeak is (should be ;-)) implemented in itself, which means, there's a platform skeleton (platform source files for windows, linux, bsd, osx, etc. pp.) but the heart of squeak is implemented it smalltalk itself. Smalltalk meaning, there is a smalltalk subset implent(izable)ed to be executed within smalltalk. That is, for my understanding, the Interpreter. A smalltalk implementation which is able to read and execute an image within itself.
So loading the VMMaker image gives you the oppurtunity to bootstrap squeak in itself.
What do you think about Exupery?
The way to go.
Could this eventually be used to output the VM?
The VM always will be the VM. The virtual machine. Question is how to map the "virtual machine" to the "actual machine"...
It would be cool if everything you need to make a VM for a platform were zipped into the VM maker for that platform including the right gcc and everything. The VM maker would unzip it all and install it. Or download it for you and install it. If you already had a C setup you could cancel the new gcc install.
For my knowledge, the windows gcc setup is fairly old, otoh, the windows gcc setup (msys, mingw) as nearly-to-aboned right now.
I am not a C programmer but I can read it somewhat.
I whish I could read macro assembler code too ;-)
I have some fixes (for sqUnixSocket.c) to deal with with the EINTR error code on various socket related calls. However there has been zero interest in promoting it to current code base. If you would like a copy and re-integrate it into the IPV6 work and do some testing to confirm the changes do in fact address a problem please let me know.
On Thu, Oct 16, 2008 at 12:26 AM, Janko Mivšek janko.mivsek@eranova.si wrote:
Hello Kjell,
Documenting and improving Sockets are for sure something needed and it can help a lot us the web guys to improve Swazoo, Commanche etc to be more performant. So you are welcome and you can expect my help to your work.
Janko
Kjell Godo wrote:
I have noticed that Squeak seems to do Sockets by using Delays for x milliseconds and then waking back up to do something again.
So I tried to make a minimal Croquet like Router doing it that way using something that was already there as the pattern and it was kind of convoluted because it was going round and round checking on things. So what I was doing was going round and round checking on things also.
Wouldn't it be better to have network interrupts happen when new data has arrived? Or when all the data has been sent? Like some kind of callback?
Could I help with this documenting? I don't know how i might do that. But the VM is of interest to me. I would like to find out about how it all works. I tried to join the vm-dev mailing list but didn't get any response yet. I don't dislike documenting things like most people seem to. I would like to do it if i could somehow come to understand what is going on in the VM.
On 10/15/08, John M McIntosh johnmci@smalltalkconsulting.com wrote:
Thank you for the feedback, there is some assumptions that people looking at the docs would understand what sqInt is. However in reflection I do need to go back and add more details about the parms being passed, especially when they are data coming directly from oops objects in object space.
As for the explanation of each function, I'll see about adding more words. I currently have another twenty api calls documented, but yet not placed on the wiki, and there are a couple of more dozen yet to document.
The other task is to document the VM callback routines, not sure when that will occur.
Lastly I"m not sure what you mean by "Are interrupts supported?"
On Oct 15, 2008, at 9:17 PM, Kjell Godo wrote:
What is sqInt? signed quad Int? Could you put an explanation of what each function is supposed to do? Are interrupts supported?
On 10/15/08, Ken Causey ken@kencausey.com wrote:
Thank you, thank you, thank you, and Thank You! This sort of stuff may not be of interest to everyone, but when you need it you really need it and it can be truly invaluable. And I know compiling it and putting it into a readable form is not the most enjoyable task. I really appreciate your making the effort.
Thank you,
Ken
On Tue, 2008-10-14 at 20:19 -0700, John M McIntosh wrote:
As part of my work on the iPhone VM I've started updating the isqueak.org site with documentation on the APIs that a VM maintainer needs to supply when building a new VM,
A starting set of pages is found at:
-- Janko Mivšek AIDA/Web Smalltalk Web Application Server http://www.aidaweb.si
-- =========================================================================== John M. McIntosh johnmci@smalltalkconsulting.com Corporate Smalltalk Consulting Ltd. http://www.smalltalkconsulting.com ===========================================================================
"Kjell" == Kjell Godo squeaklist@gmail.com writes:
Kjell> I have noticed that Squeak seems to do Sockets by using Delays for x Kjell> milliseconds and then waking back up to do something again.
I'm pretty sure that's not the case, because otherwise a Squeak webserver image would be constantly consuming a noticable amout of CPU.
I believe that what actually happens is that you have a Semaphore that is triggered either when a timeout happens or when data has arrived. At the VM level, this eventually maps to the actual select() or poll() call which contains a file descriptor mask and the shortest timeout currently requested. At this point, no CPU is consumed until the OS responds, at which point the event is mapped back to the appropriate Semaphore wakeup.
At a higher level, the pattern is to request a read with a timeout of say, 5 seconds. If the data is available immediately or soon, the 5 seconds is never reached. It's unlikely that you'd ask for no timeout, as there's probably some other course of action you'd want to take if the data won't be arriving.
This is as I understand it, having looked at similar event loop dispatchers in Perl, and the bits I remember looking at Socket and OldSocket from the image level (not VM level) in Squeak.
On Wed, Oct 15, 2008 at 10:34 PM, Kjell Godo squeaklist@gmail.com wrote:
I have noticed that Squeak seems to do Sockets by using Delays for x milliseconds and then waking back up to do something again.
Well that is wrong, it just appears that way. As the guy who wrote the vm socket semphore logic, let me explain, there are three smaltalk semphores on a socket, (read, write, control) which means on a socket state change you would get the control sempahore signaled, on a connection accepted, a socket close, a connection error, and a connection reset.
The read semaphore is signalled when data arrives for the socket. The write sempahore is signalled when the data is written, which does not mean the data is received by the other party.
This is rather complicated, and an failed attempt was made by Craig Latta to re-implement all this with a product he called "Flow" which he introduced aug 17th of 2002.
Now for example if you wanted to read from a socket you would call the read data available primitive primSocketReceiveDataAvailable:, discover no data, and then what? Wlll you wait *forever*? for the read semaphore to be signalled? Well yes, maybe no. For the no case you have Smalltalk code that waits on the read semaphore for so many seconds then fails, then the error recovery does whatever action the programmer decided to do, well like try again? Plus of course then handle issues like the socket being closed.
This is rather complicated, and an failed attempt was made by Craig Latta to re-implement all this with a product he called "Flow" which he introduced aug 17th of 2002.
Actually, I introduced it in 1998. Why do say I failed? It works.
thanks,
-C
-- Craig Latta improvisational musical informaticist www.netjam.org Smalltalkers do: [:it | All with: Class, (And love: it)]
squeak-dev@lists.squeakfoundation.org