Related articles |
---|
[5 earlier articles] |
Re: Historical Implementations to Garbage Collectors robin51@dodo.com.au (Robin Vowels) (2014-05-06) |
Re: Historical Implementations to Garbage Collectors gneuner2@comcast.net (George Neuner) (2014-05-06) |
Re: Historical Implementations to Garbage Collectors acolvin@efunct.com (mac) (2014-05-06) |
Re: Historical Implementations to Garbage Collectors genew@telus.net (Gene Wirchenko) (2014-05-06) |
Re: Historical Implementations to Garbage Collectors gneuner2@comcast.net (George Neuner) (2014-05-07) |
Re: Historical Implementations to Garbage Collectors kaz@kylheku.com (Kaz Kylheku) (2014-05-07) |
Re: Historical Implementations to Garbage Collectors robin51@dodo.com.au (Robin Vowels) (2014-05-21) |
Re: Historical Implementations to Garbage Collectors DrDiettrich1@aol.com (Hans-Peter Diettrich) (2014-05-22) |
From: | "Robin Vowels" <robin51@dodo.com.au> |
Newsgroups: | comp.compilers |
Date: | Wed, 21 May 2014 18:37:33 +1000 |
Organization: | Compilers Central |
References: | 14-05-001 14-05-009 14-05-012 14-05-017 14-05-021 |
Keywords: | storage, history |
Posted-Date: | 21 May 2014 20:13:09 EDT |
From: "George Neuner" <gneuner2@comcast.net>
> Our esteemed moderator wrote:
>>[You don't need anything that fancy for strings to overlap. With null
>>terminated readonly C-style strings, you can combine "storage" and
>>"rage" and "age". Wih strings represented by a pointer and length,
>>they can overlap anywhere.
>
> Yes. Tricks like that were used frequently in memory constrained
> implementations.
I wouldn't call it a "trick". It's a carefully-planned algorithm.
> Pointer:length pairs permit multiple use of substrings, but don't
> permit constructing a new string from arbitrary pieces of existing
> ones. The tree representation can permit completely arbitrary
> substring sharing.
The overheads of that would be intolerable. The address-length
pair is simple to use, can be passed easily as an argument
(and returned easily from a function), and there is -- essentially --
no overhead until the dynamic string space gets used up,
after which garbage collection is necessary.
> Of course, given the small amount of memory available to early
> implementations, tree representation of strings would have been
> unworkable.
Even with lots of memory, not really a proposition on account of
overheads. With lots of memory, the garbage collection routine
might not even be called.
--
This email is free from viruses and malware that avast! Antivirus
protection knows about, but is likely riddled with ones that it
doesn't.
Return to the
comp.compilers page.
Search the
comp.compilers archives again.