[sugar] Remarks on the Work of Sugar

Martin Langhoff martin.langhoff at gmail.com
Tue Jul 22 20:34:29 EDT 2008


On Wed, Jul 23, 2008 at 12:19 PM, Michael Stone <michael at laptop.org> wrote:
> I regard "fully pythonic" python data as a subgraph of a
> reference-counted object graph. So far as I know, Python has lots of
> interesting ways to parse bytestreams into object graphs, but no great
> way to read an object graph directly into memory without the overhead of
> parsing or to save an subgraph of its object graph directly to a
> bytestream. This makes it hard to use pythonic data via shared-memory or
> to pull it quickly off of a filesystem.

None of the dynamic languages I am used to can do this - Perl, Python,
PHP, Ruby - even with locks or read-only shmem arrangements. Whenever
I've used a shmem arrangement in any of them, it involved
marshalling/unmarshalling, which of course is a huge perf drag.

Which makes me suspect that there's something else that is tricky
there -- things in that shmem space do have references to the private
mem of the originating process (pointers to the class code perhaps). I
understand the PHP and Perl (circa P5.0005) internal memory handling.
YMMV.

In other words, it's in the way-too-hard-and-brittle basket, barring
an execution-engine redesign, that might incorporate some changes.
OTOH, ISTR reading that Erlang's odd all-variables-are-constants
scheme makes this easier.

cheers,


m
-- 
 martin.langhoff at gmail.com
 martin at laptop.org -- School Server Architect
 - ask interesting questions
 - don't get distracted with shiny stuff - working code first
 - http://wiki.laptop.org/go/User:Martinlanghoff


More information about the Sugar mailing list