Re: realloc() - frequency, conditions, or experiences about relocation?

Liste des GroupesRevenir à ss math 
Sujet : Re: realloc() - frequency, conditions, or experiences about relocation?
De : malcolm.arthur.mclean (at) *nospam* gmail.com (Malcolm McLean)
Groupes : comp.lang.c sci.stat.math
Date : 19. Jun 2024, 11:12:22
Autres entêtes
Organisation : A noiseless patient Spider
Message-ID : <v4u7dm$1t2pu$1@dont-email.me>
References : 1 2 3 4 5 6 7
User-Agent : Mozilla Thunderbird
On 19/06/2024 07:48, David Duffy wrote:
In sci.stat.math Anton Shepelev <anton.txt@g{oogle}mail.com> wrote:
[cross-posted to: ci.stat.math]
>
Malcolm McLean:
>
We have a continuously growing buffer, and we want the
best strategy for reallocations as the stream of
characters comes at us. So, given we now how many
characters have arrived, can we predict how many will
arrive,
>
Do you mean in the next bunch, or in total (till the end of
the buffer's lifetime)?
>
Isn't this a halting problem?  Aren't the more important data:
how much memory the user is allowed to allocate, the properties of
the current system's memory allocation algorithm, when your stream
will have to go to disc or other slow large volume storage, how
the stream can be compressed on the fly (the latter might well give
strong predictions for future storage requirements based on what
has been read to date).
 
No. We have to have some knowledge. And what we probaby know is that the input is a file stored on someone's personal computer. And someone has published on the statistical distribution of such files And they have a log-normal distribution with a mean and a median which he gives. So with that informaton, we can work out, given that a file is at least N characters, what is the prbablity that an allocation of any size will contain the whole file, and how many bytes, on average will be wasted.
Statistical analysis can't tell us what a allocation wil cost versus the cost of hoggng memory we don't need, however. It can;t tell us what to do. Just put us in the picture.
--
Check out my hobby project.
http://malcolmmclean.github.io/babyxrc

Date Sujet#  Auteur
17 Jun 24 * Re: realloc() - frequency, conditions, or experiences about relocation?22Anton Shepelev
18 Jun 24 +- Re: realloc() - frequency, conditions, or experiences about relocation?1David Jones
19 Jun 24 +* Re: realloc() - frequency, conditions, or experiences about relocation?8David Duffy
19 Jun 24 i+* Re: realloc() - frequency, conditions, or experiences about relocation?6Malcolm McLean
19 Jun 24 ii+* Re: realloc() - frequency, conditions, or experiences about relocation?3Ben Bacarisse
19 Jun 24 iii`* Re: realloc() - frequency, conditions, or experiences about relocation?2David Brown
19 Jun 24 iii `- Re: realloc() - frequency, conditions, or experiences about relocation?1Ben Bacarisse
20 Jun 24 ii`* Re: realloc() - frequency, conditions, or experiences about relocation?2Anton Shepelev
8 Jul 24 ii `- Re: realloc() - frequency, conditions, or experiences about relocation?1Anton Shepelev
19 Jun 24 i`- Re: realloc() - frequency, conditions, or experiences about relocation?1Anton Shepelev
2 Jul 24 `* Re: realloc() - frequency, conditions, or experiences about relocation?12Rich Ulrich
2 Jul 24  +* Re: realloc() - frequency, conditions, or experiences about relocation?5Keith Thompson
2 Jul 24  i`* Re: realloc() - frequency, conditions, or experiences about relocation?4Rich Ulrich
8 Jul 24  i `* Re: realloc() - frequency, conditions, or experiences about relocation?3Anton Shepelev
22 Jul 24  i  `* Re: realloc() - frequency, conditions, or experiences about relocation?2Rich Ulrich
23 Jul 24  i   `- Re: realloc() - frequency, conditions, or experiences about relocation?1Anton Shepelev
2 Jul 24  `* Re: realloc() - frequency, conditions, or experiences about relocation?6Paul
2 Jul 24   `* Re: realloc() - frequency, conditions, or experiences about relocation?5Rich Ulrich
2 Jul 24    `* Re: realloc() - frequency, conditions, or experiences about relocation?4Rich Ulrich
2 Jul 24     `* Re: realloc() - frequency, conditions, or experiences about relocation?3Paul
2 Jul 24      +- Re: realloc() - frequency, conditions, or experiences about relocation?1James Kuyper
2 Jul 24      `- Re: realloc() - frequency, conditions, or experiences about relocation?1James Kuyper

Haut de la page

Les messages affichés proviennent d'usenet.

NewsPortal