Version française
Home     About     Download     Resources     Contact us    

This site is updated infrequently. For up-to-date information, please visit the new OCaml website at

Browse thread
Threads performance issue.
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2009-02-16 (15:15)
From: Rémi_Dewitte <remi@g...>
Subject: Threads performance issue.

I would like to read two files in two different threads.

I have made a first version reading the first then the second and it takes
2.8s (native).

I decided to make a threaded version and before any use of thread I realized
that just linking no even using it to the threads library makes my first
version of the program to run in 12s !

I use pcre, extlib, csv libraries as well.

I guess it might come from GC slowing down thinks here, doesn't it ? Where
can it come from otherwise ? Is there a workaround or something I should
know ?

Can ocaml use multiple cores ?

Do you have few pointers on libraries to make parallel I/Os ?