Mailing list for all users of the OCaml language and system.
 help / color / mirror / Atom feed
From: doligez@pa.dec.com
To: caml-list@inria.fr
Subject: Re: controler la taille du tas
Date: Wed, 10 Mar 1999 16:52:13 -0800	[thread overview]
Message-ID: <199903110052.AA21421@six.pa.dec.com> (raw)
In-Reply-To: Message of Wed, 10 Mar 1999 09:15:27 +0100 from "Pierre CREGUT - FT.BD/CNET/DTL/MSV" <pierre.cregut@cnet.francetelecom.fr> <19990310091527.17113@lsun605>

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1024 bytes --]


>From: "Pierre CREGUT - FT.BD/CNET/DTL/MSV" <pierre.cregut@cnet.francetelecom.fr>

>Y a t'il un moyen (même détourné) pour imposer que la taille du tas=
> d'un
>programme CAML ne passe jamais en dessous d'un certain seuil.
>Je veux que même si la mémoire est inutilisée, le GC ne la relache =
>pas
>(sinon, une solution au problème est d'allouer un tableau global de la =
>taille
>du seuil voulu, mais ca n'a pas grand intérêt).

C'est simple:
1. allouer un objet de la taille voulue (par exemple une chaine)
2. ne pas garder de pointeur sur cet objet
3. declencher un GC
4. ne pas utiliser le compactage


>===[translation]===
>
>Is there a way (even a weird one) to enforce that the size of the heap of=
>
>a Caml program will never shrink under a given threshold ? I want
>that the garbage collector takes all the memory allocated and
>does not release it even if it is unused.

1. allocate a big object (for example a string)
2. don't keep any pointer to the object
3. call the GC
4. don't use compaction

-- Damien




      reply	other threads:[~1999-03-11 12:34 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <pierre.cregut@cnet.francetelecom.fr>
1999-03-10  8:15 ` Pierre CREGUT - FT.BD/CNET/DTL/MSV
1999-03-11  0:52   ` doligez [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=199903110052.AA21421@six.pa.dec.com \
    --to=doligez@pa.dec.com \
    --cc=caml-list@inria.fr \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox