caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: Alain Frisch <Alain.Frisch@ens.fr>
To: skaller <skaller@users.sourceforge.net>
Cc: caml-list <caml-list@inria.fr>
Subject: Re: [Caml-list] some profile data
Date: Sat, 26 Jun 2004 09:39:56 +0200 (MET DST)	[thread overview]
Message-ID: <Pine.SOL.4.44.0406260932350.19464-100000@clipper.ens.fr> (raw)
In-Reply-To: <1088185404.1941.126.camel@pelican.wigram>

On 26 Jun 2004, skaller wrote:

> This is curious enough to report: I use hash tables quite
> a bit, but i didn't quite expect this profile: 2/3 of ALL time
> doing comparisons??

You should be aware that the polymorphic compare function is slow (for
each block, it has to do a dispatch on the tag, etc...).  In general, it
is a good idea to write your own compare function for your types; it also
allows you to stop the recursive descent where you want (e.g. for
comparing only some fields). And this is a must if you have cyclic
data-structure.


-- Alain

-------------------
To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr
Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners


      reply	other threads:[~2004-06-26  7:40 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-06-25 17:43 skaller
2004-06-26  7:39 ` Alain Frisch [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=Pine.SOL.4.44.0406260932350.19464-100000@clipper.ens.fr \
    --to=alain.frisch@ens.fr \
    --cc=caml-list@inria.fr \
    --cc=skaller@users.sourceforge.net \
    /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;
as well as URLs for NNTP newsgroup(s).