<div>picoLARC will have a C like dialect of Lisp in it.&nbsp; ( <a href="http://sourceforge.net">sourceforge.net</a> )&nbsp; I would like to write a VM for picoLARC in this dialect of Lisp.&nbsp; So I would like to learn about the Windows version of the Squeak VM.&nbsp; </div>

<div>How do I do that?&nbsp; </div>
<div>Where do I start?&nbsp; </div>
<div>Are there test cases that I could step through?</div>
<div>What do I need to compile it?</div>
<div>Is there a visual debugger I can use to step through the C parts?</div>
<div>&nbsp;</div>
<div>If I could understand it then I would like to help document it.&nbsp; If possible.<br><br></div>
<div class="gmail_quote">On Tue, Oct 28, 2008 at 5:31 PM, John M McIntosh <span dir="ltr">&lt;<a href="mailto:johnmci@smalltalkconsulting.com">johnmci@smalltalkconsulting.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">This VM has a number of fundamental changes and can be found<br>via ftp or my idisk at &nbsp;<a href="http://www.smalltalkconsulting.com/squeak.html" target="_blank">http://www.smalltalkconsulting.com/squeak.html</a><br>
<br>(a) I have changed how image files are read.<br><br>Users should verify the VM still will load and work with their current images on their current systems. I have tested with macintel on 10.5.x and powerpc on 10.4.x but have NOT tested on a 10.3.x powerpc system, if some 10.3.x user could do that it would be appreciated.<br>
<br>(b) I no longer cwd (change working directory) at startup time to the VM directory, and I added a change so if the image name is for example Squeak.image we attempt to find that in the VM directory. This change *should* enable the ablility to launch a VM and image and startup file from a command line using relative file paths, versus having to give absolute paths.<br>
<br>Users are welcome to test and confirm this feature works as expected with relative and absolute paths for the image and startup file.<br><br>Memory allocation background:<br><br>In the past we have read the image file into a pre-allocated chunk of memory allocated via mmap, now I have changed to a more complicated but faster method of reading which then allows us to someday depending on your VM to avoid re-swizzling pointers for an image that is launched on a unix, windows, or iPhone since all oops should start on the 500MB boundary.<br>
<br>What happens is we mmap the image file with copy on write mmap into a segment of memory starting at a real address of 500MB (500*1024*1024), the next virtual memory page follow the size of the file then is anonymously mmap upto the maximum memory size choosen for the implmentation. In this case we allocate 512MB of memory which is a settable option in the info.plist.<br>
<br>Because of mmap differences between operating systems, and versions of operating systems I cannot say if this will work on your favourite device, but it does seem to work on os-x 10.4 &amp; 10.5 for powerpc and macintel, plus on iPhone 2.x.<br>
<br>Post loading we check to see if the memory start location is the same as the memory start location when the image was saved. If not then we adjust all oops pointers by the difference in addresses. If the saved image was at the 500MB boundary then we do not need to walk all the oops to swizzle pointers, this saves some CPU cycle and becomes important on slow devices like the iPhone, or when we want to use Squeak as a scripting engine and expect really fast startup.<br>
<font color="#888888"><br>--<br>===========================================================================<br>John M. McIntosh &lt;<a href="mailto:johnmci@smalltalkconsulting.com" target="_blank">johnmci@smalltalkconsulting.com</a>&gt;<br>
Corporate Smalltalk Consulting Ltd. &nbsp;<a href="http://www.smalltalkconsulting.com/" target="_blank">http://www.smalltalkconsulting.com</a><br>===========================================================================<br><br>
<br><br><br></font></blockquote></div><br>