[Vm-dev] New Cog VMs available

Ryan Macnak rmacnak at gmail.com
Thu Jun 26 06:05:24 UTC 2014


With appropriate settings [1], one can get 3GB on Windows. (I haven't
tested this on Cog but once upon time used it in another project.) I don't
know if this extra GB is worth it to anyone; given the other platforms
provide above 2GB hopefully the bugs related to signed versus unsigned
comparisons are already flushed out.

[1] http://msdn.microsoft.com/en-us/library/bb613473(v=VS.85).aspx


On Wed, Jun 25, 2014 at 4:13 PM, Eliot Miranda <eliot.miranda at gmail.com>
wrote:

>
> ... at http://www.mirandabanda.org/files/Cog/VM/VM.r3018/.
>
> The main difference here is fixes to memory segment allocation on Spur.
>  Linux and Mac OS can now grow the heap to 2.9Gb or there abouts, and Win
> XP can grow to 1.8Gb.  I'm interested in reports on other Windows versions
> that don't have XP's 2Gb user process address space limit.
>
> Here's my test script:
> | them |
> them := OrderedCollection new.
> [[them addLast: (ByteArray new: 16000000).
>  Transcript cr; print: (Smalltalk vmParameterAt: 3) / (1024*1024.0)
> maxDecimalPlaces: 1; flush] repeat]
>  on: OutOfMemory
> do: [:ex| 2 to: them size by: 2 do: [:i| them at: i put: nil. Smalltalk
> garbageCollect]].
> Transcript cr; print: (Smalltalk vmParameterAt: 3) / (1024*1024.0)
> maxDecimalPlaces: 1; flush.
> them := nil.
> Smalltalk garbageCollect.
> Transcript cr; print: (Smalltalk vmParameterAt: 3) / (1024*1024.0)
> maxDecimalPlaces: 1; flush
>
> And the README is:
> CogVM binaries as per VMMaker.oscog-eem.779/r3018.
>
> Rewrite memory allocation on linux for Spur.  Arrange that the heap can
> grow
> above 2Gb without any large initial alloc.
>
> Rewrite platforms/unix/vm/sqUnixSpurMemory.c to stand alone.  Use it in
> place
> of sqMacMemory.c with Spur on Mac OS.  Now Spur can grow the heap to 2.9Gb
> on
> both linux (CentOS 5.3) and Mac OS X (10.6.8).
>
> Rewrite Spur memory allocation on win32 similarly to unix.  Can now
> allocate
> up to 1.8Gb on Windows XP (which has a 2Gb address space limit).  Add a
> flag
> to indicate if the win32 exe is running as a console app and don't write to
> the in-window console if so.
>
> Fix some sign issues with free space tallying to allow Spur to shrink
> memory
> and answer via primitiveVMParameter heap sizes above 2Gb.
>
> Add longPrintInstancesOf:/longPrintInstancesWithClassIndex: for debugging.
>
> Suggest reading a suitable README when the linux VM fails to spawn the
> heartbeat
> thread.
>
> Add parameter 54 on Spur to answer totalFreeOldSpace.
>
> --
> best,
> Eliot
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.squeakfoundation.org/pipermail/vm-dev/attachments/20140625/5a393ade/attachment.htm


More information about the Vm-dev mailing list