pending mac VM 3.2.2
John M McIntosh
johnmci at smalltalkconsulting.com
Wed Jan 30 23:32:19 UTC 2002
Ok, here are the release notes for 3.2.2. The two major changes are
memory mapping, and FFI support.
But I need another person or two to fiddle with the FFI interface to
confirm it works as expected,
if anyone is interested they should email me. I expect, pending a few
64 bit file io cleanup items to
post the VM later this week.
Mac VM 3.2.2 mach-o build for Carbon.
Jan 30th 2002
Still yet to do, in future versions.
Test drag and drop at startup time
Verify that file delete rename etc works on aliases, not the targets.
You will need mach-o os-x bundle plugins to work with this VM.
example -> mpeg3Plugin.bundle.
Old carbon non-bundled plugins will not work.
a) AsyncFilePlugin.c Use global to remember security function entry
point for performance reasons
b) FilePlugin.c Use global to remember security function entry point
for performance reasons
c) interp.c Use squeakFileOffsetType versus off_t and add a bunch of
checks to handle lack of long long and conversion errors between
64/32 bit integers and LargeInteger objects
d) readme, it's http://www.mucow.com/Gnuifier.1.cs
e) SocketPlugin.c Use global to remember security function
entry point for performance reasons
f) sq.h added default sqFilenameFromStringOpen and sqTruncate
g) sqFilePluginBasicPrims.c revert to ansi specs, but ensure #def to
fseeko and ftello for 64 bit aware file systems.
h) sqMacDirectory.c A bit more error checking on bad file names
i) sqMacFileLogic.c Folders size is now zero in classic, and a bit
more checking on bad file names
j) sqMacSound.c Fixed a problem with sound recording in classic due
to a change made in Sept. But sound recording still does not work
k) sqMacWindow.c two very important changes:
1) You can now do FFI calls with the FFI bundle plugin to
However you need to rework your api calls. For example:
apiGetMousePoint: aMacPoint was
<apicall: void 'GetMouse' (MacPoint*) module:'InterfaceLib'>
It now is:
<apicall: void 'GetMouse' (MacPoint*) module:'Carbon.framework'>
If you review /System/Library/Frameworks I'm sure you can
come up with interesting ways to
make mac only squeak images.
I now use mmap( NULL, gMaxHeapSize, PROT_READ | PROT_WRITE,
MAP_ANON | MAP_SHARED,-1,0);
anonymous memory mapping to 512MB as the squeak memory block.
The VM can then grow or shrink
within the 512MB block, I just move a pointer.
Note in 3.2.1 a slight error on my part restricted Squeak to
50MB. I am of course
interested to hear about issues with my choice of 512MB. Note
a Squeak VM is limited to 2GB under perfect
conditions, however if any part of the image crosses the 2GB
boundary the VM will fail, right now 512MB
seemed a safe choice.
PhysMem: 60.2M wired, 78.6M active, 412M inactive, 551M
used, 217M free
VM: 3.03G + 55.3M 7847(0) pageins, 1(0) pageouts
PID COMMAND %CPU TIME #TH #PRTS #MREGS RPRVT RSHRD
422 Squeak VM 0.8% 0:35.59 2 71 100 23.3M 8.53M
but I only have one 80,000,000 byte swap file in /var/vm
Note if you turn crash reporter on, then if the VM crashes a nice
report should be generated in your log directory. See the Apple
documentation for a description of this feature, currently it is set
in OS-X 10.1.x via the preferences window for the Console
Application. If you have a crash with this VM, please recreate and
post the crash log (found in Users/foobar/Library/Logs/ to the Squeak
mailing list so we can continue to make the VM fault tolerant.
John M. McIntosh <johnmci at smalltalkconsulting.com> 1-800-477-2659
Corporate Smalltalk Consulting Ltd. http://www.smalltalkconsulting.com
More information about the Squeak-dev