caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: Eric Stokes <eric.stokes@csun.edu>
To: effbiae@ivorykite.com
Cc: caml-list@inria.fr
Subject: Re: [Caml-list] custom mmap modeled on bigarray
Date: Wed, 11 Aug 2004 07:52:20 -0700	[thread overview]
Message-ID: <0BFACEB2-EBA6-11D8-9B5E-000A95A1E69A@csun.edu> (raw)
In-Reply-To: <49993.60.246.255.166.1092114361.squirrel@www.ivorykite.com>

Even if it isn't it can be distributed as a GODI patch fairly easily. I 
think a patch such as this, if architected well
would allow me to improve performance of some of my C bindings even 
more, and that is a good thing.

On Aug 9, 2004, at 10:06 PM, Jack Andrews wrote:

> i know the argument for developing first, optimizing later.  i also 
> know
> the arguments for not caring about fine-grain performance and to look
> at the big picture.  i've argued both and seen where these arguments 
> fail.
>
> consider compressed data as a bit stream from disk.
> say it has simple encoding:
>  phrase :=
>   byte:<number-of-bits>, byte:<number-of-values>, int[]:<bit-stream>
> eg:
>   0x03 0x0a 0b1110 0011 1001 0100   1110 0101 1101 1100
>   |    |    +<bit-stream>
>   |    +number-of-values
>   +number-of-bits
>
> represents the sequence of 10 3-bit numbers:
>
>  111,000,111,001,010,011,100,101,110,111
>
> now consider a sentence as
>   sentence := <empty> | phrase, sentence
>
> without an enhanced FFI, ocaml will be considerably slower than C for
> uncompressing (and compressing).
>
> in my previous post, i suggest that some language primitives similar to
> %bigarray_ref_1 could be introduced to make ocaml comparable to C.  i
> have investigated this possibility, and my suggestion is that
> %bigarray_ref is replaced by a primitive %ffi_ref and made public.
> then bigarray can be built on the more general %ffi_ref and developers
> have a fast means of accessing C arrays like mmap regions.
>
> if i spend time implementing %ffi_ref/set, is there any chance of it 
> being
> incorporated into ocaml?
>
> thanks,
>
>
>
> jack
>
>
> -------------------
> 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
>

-------------------
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-08-11 14:52 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-08-04  2:39 [Caml-list] c is 4 times faster than ocaml? effbiae
2004-08-04  4:59 ` John Prevost
2004-08-04  5:05   ` John Prevost
2004-08-04  5:24   ` effbiae
2004-08-04  7:28     ` John Prevost
2004-08-04  8:18       ` [Caml-list] " Jack Andrews
2004-08-04 10:06         ` Mikhail Fedotov
2004-08-04 10:25           ` [Caml-list] " Jack Andrews
2004-08-04 15:38             ` [Caml-list] custom mmap modeled on bigarray Jack Andrews
2004-08-10  5:06               ` Jack Andrews
2004-08-11 14:52                 ` Eric Stokes [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=0BFACEB2-EBA6-11D8-9B5E-000A95A1E69A@csun.edu \
    --to=eric.stokes@csun.edu \
    --cc=caml-list@inria.fr \
    --cc=effbiae@ivorykite.com \
    /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).