Sorry to ask a C question here, but I could not find an answer on the net.
How do I create a library that can be used in ghci?
This is the situation:
I have a c file coracle.c. I do
/tmp$ cc -c -o coracle.o coracle.c
/tmp$ ar rc libcoracle.a coracle.o
/tmp$ ranlib libcoracle.a
and then I the
Any chance of documenting your experience on the GHC user documentation page?
http://haskell.org/haskellwiki/GHC (under collaborative documentation)
A kind of how-to that worked for you, with pointers to relevant manual parts
etc.
Simon
| -Original Message-
| From: [EMAIL
Simon Marlow wrote:
Perhaps there are some trivial examples of
unshared thunks that we could spot, though.
The sharing analysis in the interpreter is also very simple and
inexpensive. But the gain is frequent. Maybe giving it a try would be
worthwhile.
Thanks again for all your answers!
Bernd
Simon Marlow wrote:
Normally it's done like this:
$ gcc -fPIC -c foo.c
$ gcc -shared -o libfoo.so foo.o
Hope this helps.
Right away! Big Thanks!
Bernd
___
Glasgow-haskell-users mailing list
Glasgow-haskell-users@haskell.org
Bernd Brassel wrote:
Sorry to ask a C question here, but I could not find an answer on the net.
How do I create a library that can be used in ghci?
This is the situation:
I have a c file coracle.c. I do
/tmp$ cc -c -o coracle.o coracle.c
/tmp$ ar rc libcoracle.a coracle.o
/tmp$ ranlib
Bernd Brassel wrote:
There is another point that makes me wonder now. If the update frame for
the recursive call is the problem then my solution with foreign C
functions would produce a bad stack also. But this is not the case.
The code looks now like this:
sim [] = True
sim (_:xs) = yags
Hi all,
I have a problem with regards to the speed of ST arrays.
In short: a Data.Map.Map outperforms Data.Array.ST in my application,
whereas as far as I understand it, the ST array should be quicker.
My application is a compiler. It compiles some source code into a (huge)
number of boolean
So my theory now is:
I do a large number of lookups.
Try using Data.Array.Base.unsafeRead (and maybe ata.Array.Base.unsafeWrite).
These avoid the bounds checking on the index each time you lookup something in
the array.
___
Glasgow-haskell-users
Chris Kuklewicz wrote:
So my theory now is:
I do a large number of lookups.
Try using Data.Array.Base.unsafeRead (and maybe
ata.Array.Base.unsafeWrite). These avoid the bounds checking on the
index each time you lookup something in the array.
Right. Also keep an eye on the GC time
Simon Peyton-Jones wrote:
Any chance of documenting your experience on the GHC user documentation page?
http://haskell.org/haskellwiki/GHC (under collaborative
documentation)
A kind of how-to that worked for you, with pointers to relevant manual parts
etc.
Simon
Is this
10 matches
Mail list logo