Mailing list for all users of the OCaml language and system.
 help / color / mirror / Atom feed
From: Falk Hueffner <falk.hueffner@student.uni-tuebingen.de>
To: caml-list@inria.fr
Subject: [Caml-list] Alpha optimizations
Date: 26 Nov 2001 02:27:45 +0100	[thread overview]
Message-ID: <87lmgub9ta.fsf@student.uni-tuebingen.de> (raw)

Hi,

I noticed that there are some small optimizations possible for Alpha,
e. g. s4addq with immediate values, or multiplication with 2.0 as
add. Is there any interest in patches for that?

Also, would it be reasonably easy to unbox floats in tail recursive
leaf functions? This would speed up code tremendously like

let rec do_iter i zr zi =
  let zr2 = sqr zr and zi2 = sqr zi in
    if i >= maxiter || zr2 +. zi2 >= 4.0
    then i
    else do_iter
        (i + 1)
        (zr2 -. zi2 +. cr)
        (2.0 *. zr *. zi +. ci)

which is currently 7.5 times slower than C.

Also, OCaml frequently emits redundant instructions like

        ldt     $f13, 0($18)
        ldt     $f14, 0($18)
or
        sra     $16, 1, $3
        sra     $16, 1, $4

I'm not sure how to avoid this, though; perhaps some postprocessing
would be appropriate?

        Falk

-------------------
Bug reports: http://caml.inria.fr/bin/caml-bugs  FAQ: http://caml.inria.fr/FAQ/
To unsubscribe, mail caml-list-request@inria.fr  Archives: http://caml.inria.fr


                 reply	other threads:[~2001-11-26  1:28 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=87lmgub9ta.fsf@student.uni-tuebingen.de \
    --to=falk.hueffner@student.uni-tuebingen.de \
    --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