[email protected]
[Top] [All Lists]

Re[2]: [Haskell-cafe] Problem making a program in ghc

Subject: Re[2]: [Haskell-cafe] Problem making a program in ghc
From: Bulat Ziganshin
Date: Fri, 14 Mar 2008 14:23:25 +0300
Hello Sterling,

Friday, March 14, 2008, 7:06:24 AM, you wrote:

yes, it's another question. my own program also writes to logfile and
it got lock-free only when i've switched to using my own IO routines

> This answer may be way off base, but if differences appear between  
> ghci and compiled versions, I've often found its as simple as  
> remembering to compile with the -threaded flag. The ghci runtime is  
> threaded by default, as I understand it, while compiled binaries are  
> not, and IO operations will block in very different fashions (i.e. in
> their own thread, or stalling the entire app) depending on the runtime.

> Regards,
> sterl.

> On Mar 13, 2008, at 3:47 PM, Adam Langley wrote:

>>> web application),
>>> I have a log that confirms that the response arrives correctly.
>> I hate to see any requests for help go unanswered here, but this one
>> might be tough. I think you need to give some more information,
>> otherwise the suggestions are going to be very general. Can you put
>> the Haskell source code on a website somewhere and link to it. Since
>> it's a network service, an example request and reply might be good to
>> include.
>> In general, you should check that you are correctly flushing your
>> connection. If you are using Handles to interface to the network, they
>> can buffer the response. hFlush[1] may need to be called when you have
>> finished generating it.
>> [1] http://haskell.org/ghc/docs/latest/html/libraries/base/System- 
>> IO.html#v%3AhFlush
>> AGL
>> -- 
>> Adam Langley [email protected] http://www.imperialviolet.org
>> _______________________________________________
>> Haskell-Cafe mailing list

> _______________________________________________
> Haskell-Cafe mailing list
> [email protected]
> http://www.haskell.org/mailman/listinfo/haskell-cafe

Best regards,
 Bulat                            mailto:[email protected]

Haskell-Cafe mailing list
[email protected]

<Prev in Thread] Current Thread [Next in Thread>