John,

Adding -C0.005 makes it much better. Using -C0.001 makes it behave more like 
-N4.

Thanks. This saves my project, as I need to deploy on a single core Atom and 
was stuck.

Mike

On Oct 29, 2014, at 5:12 PM, John Lato <jwl...@gmail.com> wrote:

> By any chance do the delays get shorter if you run your program with `+RTS 
> -C0.005` ?  If so, I suspect you're having a problem very similar to one that 
> we had with ghc-7.8 (7.6 too, but it's worse on ghc-7.8 for some reason), 
> involving possible misbehavior of the thread scheduler.
> 
> On Wed, Oct 29, 2014 at 2:18 PM, Michael Jones <m...@proclivis.com> wrote:
> I have a general question about thread behavior in 7.8.3 vs 7.6.X
> 
> I moved from 7.6 to 7.8 and my application behaves very differently. I have 
> three threads, an application thread that plots data with wxhaskell or sends 
> it over a network (depends on settings), a thread doing usb bulk writes, and 
> a thread doing usb bulk reads. Data is moved around with TChan, and TVar is 
> used for coordination.
> 
> When the application was compiled with 7.6, my stream of usb traffic was 
> smooth. With 7.8, there are lots of delays where nothing seems to be running. 
> These delays are up to 40ms, whereas with 7.6 delays were a 1ms or so.
> 
> When I add -N2 or -N4, the 7.8 program runs fine. But on 7.6 it runs fine 
> without with -N2/4.
> 
> The program is compiled -O2 with profiling. The -N2/4 version uses more 
> memory,  but in both cases with 7.8 and with 7.6 there is no space leak.
> 
> I tired to compile and use -ls so I could take a look with threadscope, but 
> the application hangs and writes no data to the file. The CPU fans run wild 
> like it is in an infinite loop. It at least pops an unpainted wxhaskell 
> window, so it got partially running.
> 
> One of my libraries uses option -fsimpl-tick-factor=200 to get around the 
> compiler.
> 
> What do I need to know about changes to threading and event logging between 
> 7.6 and 7.8? Is there some general documentation somewhere that might help?
> 
> I am on Ubuntu 14.04 LTS. I downloaded the 7.8 tool chain tar ball and 
> installed myself, after removing 7.6 with apt-get.
> 
> Any hints appreciated.
> 
> Mike
> 
> 
> _______________________________________________
> Glasgow-haskell-users mailing list
> Glasgow-haskell-users@haskell.org
> http://www.haskell.org/mailman/listinfo/glasgow-haskell-users
> 

_______________________________________________
Glasgow-haskell-users mailing list
Glasgow-haskell-users@haskell.org
http://www.haskell.org/mailman/listinfo/glasgow-haskell-users

Reply via email to