[Vm-dev] [PATCH] added FilePlugin error code lookup function

Eliot Miranda eliot.miranda at gmail.com
Sat Mar 24 13:47:28 UTC 2018


Hi Monty,

On Fri, Mar 23, 2018 at 10:12 PM, monty <monty2 at programmer.net> wrote:

>
> Echoing Alistair, no SharedPool in my generated VMMaker image seems to do
> what you describe.


That's right.  I did a prototype for VisualWorks when I worked at Cincom.
I don't think they would object to me giving you the code but if you can do
with out it would be better, and since the code isn't that difficult it
might be better to start afresh.  But if you read the thread you'll see
that Mariano Martines Peck did something in Pharo based on our
conversations and that might be a better starting point.


> If you want, I can do the implementation. (In the FFI-Pools package.)
>

That would be great.  Remember the major requirements:

Deployment:
The output of the C program should be a concise parseable, human-editable
document (in STON?) whose name identifies the platform.  Let's call it
PlatformConstants-XXX.ext (where ext reflects the syntax chosen).
Various PlatformConstants-XXX.ext files can live either in a folder in the
virtual machine or a folder parallel to the image
Various PlatformConstants-XXX.ext files and the pool definition that
generated them should live somewhere on squeak.org so people can download
them without needing a C development environment to get access to new
constants, etc.
The PlatformConstants-XXX.ext file is only parsed on start-up if the image
comes up on a different platform.  Parsing happens before any FFI/socket
call
An alternative would be "conditional bindings", where the various
platform-specific values for a particular constant could be in additional
inst vars of a suitable binding type, which could allow for a default value
for concision, for example
Global variableSubclass: #PlatformConstant
instanceVariableNames: 'default'
classVariableNames: ''
poolDictionaries: ''
category: 'FFI-Core'
and then the alternatives different from the default would be held in
indexed inst vars as pairs of platform moniker, value

Development:
Generating a new PlatformConstants-XXX.ext file should be entirely
automatic, but would assume the platform's standard compiler would be
available


_,,,^..^,,,_
best, Eliot
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.squeakfoundation.org/pipermail/vm-dev/attachments/20180324/a59738eb/attachment.html>


More information about the Vm-dev mailing list