From: Xavier Leroy <Xavier.Leroy@inria.fr>
To: Gerd Stolpmann <info@gerd-stolpmann.de>
Cc: caml-list@yquem.inria.fr
Subject: Re: [Caml-list] Comments welcomed to progr. style / speed of my first ocaml program "Error correcting LDPC decoder"
Date: Thu, 15 Dec 2005 16:09:38 +0100 [thread overview]
Message-ID: <43A18732.2060201@inria.fr> (raw)
In-Reply-To: <3518.192.168.1.2.1134650422.squirrel@gps.dynxs.de>
> I forgot one thing: This comment is only correct for 32 bit code. 64 bit
> code has a uniform array layout for all element types.
Yes, but a generic access to a float array still involves an extra
boxing operation. So, your advice is sound for 64-bit plaforms as well.
I had a very quick look at the original poster's code: it seems
reasonable performance-wise. There are a few extra hacks that could
be done to increase performance at some expense in code clarity, for
instance turning
a.(i).(j) <- f i j a.(i).(j);
in
(let b = a.(i) in b.(j) <- f i j b.(j));
but I wouldn't recommend doing this unless profiling exhibits a big
"hot spot" in this function.
- Xavier Leroy
next prev parent reply other threads:[~2005-12-15 15:09 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-12-15 10:33 Andries Hekstra
[not found] ` <OFB50A01B3.ECDA5A94-ONC12570D8.00394FEA-C12570D8.003A2427@philips.com >
2005-12-15 12:03 ` [Caml-list] " Gerd Stolpmann
2005-12-15 12:40 ` Gerd Stolpmann
2005-12-15 15:09 ` Xavier Leroy [this message]
2005-12-16 19:35 ` Jon Harrop
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=43A18732.2060201@inria.fr \
--to=xavier.leroy@inria.fr \
--cc=caml-list@yquem.inria.fr \
--cc=info@gerd-stolpmann.de \
/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