Hello Roman, Wednesday, September 24, 2008, 2:04:38 PM, you wrote:
> As I understand, there are two ways to do that. Either Haskell code is > called from C, or C code is called for Haskell. So my questions are: > 1. Are they both possible? yes. "foreign export" exports Haskell functions to C world, foreign import does opposite > 2. If yes, which is better performance-wise? (C function is > performance-critical). If generated function is called many times, > how big an overhead is going to be? foreign import *unsafe* -fvia-C together with -O2 may improve speed of C function calls -- Best regards, Bulat mailto:[EMAIL PROTECTED] _______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe