Version française
Home     About     Download     Resources     Contact us    
Browse thread
-linkall segmentation faults
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Frank Dellaert <dellaert@c...>
Subject: -linkall segmentation faults
Hi
we have a very extensive robotics/vision code-base that mixes C and 
Ocaml. The library is divided in about 30 different libraries that can 
be linked in with the main program, depending on its functionality. 
However, the executables that ocamlopt produces started to get too 
large (10MB and more) so I decided to remove the -linkall flag. 
However, we quickly found that
(1) removing the -linkall on certain libraries immediately crashes our 
executables
(2) even after re-instituting -linkall for those, we still experience 
random crashes (2 out of 5 runs)
I suspect, based on examining core dumps, that it is C-externals or 
garbage collection problems. Two questions:
a) I do believe this is a genuine bug: the linker should find out which 
modules to link. Can it be added to a list of bugs in Ocaml ?
b) how can we work around it, and/or identify which libraries cause the 
problem ?
Cheers
Frank Dellaert
Asst. professor, Georgia Tech