From: Anton Moscal <msk@post.tepkom.ru>
To: Damien Doligez <Damien.Doligez@inria.fr>
Cc: caml-list@pauillac.inria.fr
Subject: Re: About array
Date: Fri, 15 Oct 1999 16:30:03 +0400 (MSD) [thread overview]
Message-ID: <Pine.LNX.4.03.9910151620460.2424-100000@post.tepkom.ru> (raw)
In-Reply-To: <199910121504.RAA19904@tobago.inria.fr>
On Tue, 12 Oct 1999, Damien Doligez wrote:
> >From: Anton Moscal <msk@post.tepkom.ru>
>
> >Evaluation `f i' can cause GC call -> we must use modify function. Really
> >we can check address of our fresh array after each `f i'. While this
> >address remains unchanged we have no need to call `modify'. I think this
> >will be good.
>
> Wrong. There is no guarantee that the GC will move your fresh array.
> In most cases it will not because the array will already be in the
> major heap.
Oops, this is an error. But correct test can be easily written in C
(simply test address range)
> >I made the following experiment:
>
> [replacing Array.init with a home-brewed version]
>
>
> >time became 0.97 sec (but this version will not work
> >with float arrays)
>
> Indeed, it only works with int arrays. And the only reason it's
I think it will be works in the current implementation with array of any
types except float (if we replace algorithm for testing for array location
in young heap on correct version). Why not? (of course this is not correct
code from point of view of the language definition)
Regards,
Anton
next prev parent reply other threads:[~1999-10-15 13:59 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
1999-10-12 15:04 Damien Doligez
1999-10-15 12:30 ` Anton Moscal [this message]
[not found] <380324A8.DEB61647@univ-savoie.fr>
1999-10-12 13:08 ` Anton Moscal
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=Pine.LNX.4.03.9910151620460.2424-100000@post.tepkom.ru \
--to=msk@post.tepkom.ru \
--cc=Damien.Doligez@inria.fr \
--cc=caml-list@pauillac.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