[email@example.com: Re: red seg size philosophy question]
Jonathan S. Shapiro
Wed, 1 Apr 1998 07:58:02 -0500
[Jonathan Adams sent this to me rather than to the list. I've edited
out some personal comments at the end that were inappropriate for the
list. My previous post was a response to this.]
On Tue, 31 Mar 1998, Jonathan S. Shapiro wrote:
> The lss value for a red segment resides inside the segment itself, so
> in some sense it is "owned" by the keeper.
> The question: what value should vcsk/zsk choose?
> A very large value allows a growable segment, such as a kept process
> address space. This can be constrained by the holder by placing it
> inside a segment with a smaller LSS.
Just as a question, would it be reasonable to have a call in the vcsk
interface which basically states "Truncate (if necessary) to x bytes and do
not extend the segment past x bytes"? It seems to me it might be a useful
thing for, say a fixed length file.
With your solution, you can only restrict it to x = 32^N, which is not
> A value that is too small prevents the address space from growing
> I can imagine four reasonable choices:
> 1. Just big enough to hold whatever the previously
> frozen segment held.
> 2. That + 1, allowing controlled growth, but not arbitrary
> 3. MAXLSS.
> I'm beginning to incline towards MAXLSS, because it seems to me that a
> growable segment shouldn't have a limit until it is told to.
I would lean towards MAXLSS. Anything else has a good chance of biting back
when one least expects it. Since someone can always limit the size by
wrapping it in another segment (or issuing the above call or something that
sets the lss), there is no loss of functionality by choosing MAXLSS, and the
user is not surprised by the outcome.
Which brings up another question in my mind: Should there be a way to
make pages in a vsck "not there", in the sense that accessing them will cause
the domain keeper to be invoked.
This could be in the form of an option on the segment which makes "holes" in
the original segment fill with zeros, with the consequence of disabling the
option being a domain keeper invocation on accessing of "holes"?
Talk to you later,
- Jonathan Adams