Re[2]: Concurrency issue with dynamic linker in GHC

2006-10-23 Thread Bulat Ziganshin
Hello Vyacheslav, Monday, October 23, 2006, 7:20:47 AM, you wrote: Bulat: I didn't get the chance to use the streams library yet, but could you explain how it would solve my locking problem? The core problem that the runtime under Win32 doesn't have an IO manager still remains, correct? i

Re: Concurrency issue with dynamic linker in GHC

2006-10-23 Thread Simon Marlow
Bulat Ziganshin wrote: Hello Vyacheslav, Monday, October 23, 2006, 7:20:47 AM, you wrote: Bulat: I didn't get the chance to use the streams library yet, but could you explain how it would solve my locking problem? The core problem that the runtime under Win32 doesn't have an IO manager still

Re: Concurrency issue with dynamic linker in GHC

2006-10-23 Thread Simon Marlow
Donald Bruce Stewart wrote: bulat.ziganshin: Hello Donald, Sunday, October 22, 2006, 9:04:02 AM, you wrote: can't you define this call as 'safe'? But is it safe. Hmm I get kind of queasy when mucking about in the rts. i don't understand you (because of my weak English). 'safe'

Re: Concurrency issue with dynamic linker in GHC

2006-10-23 Thread Simon Marlow
Simon Marlow wrote: Bulat Ziganshin wrote: Hello Vyacheslav, Monday, October 23, 2006, 7:20:47 AM, you wrote: Bulat: I didn't get the chance to use the streams library yet, but could you explain how it would solve my locking problem? The core problem that the runtime under Win32 doesn't

Re[2]: Concurrency issue with dynamic linker in GHC

2006-10-23 Thread Bulat Ziganshin
Hello Simon, Monday, October 23, 2006, 5:05:56 PM, you wrote: Perhaps your bug is that you're using hGetBufNonBlocking, which isn't on Windows? _whose_ bug? you write to Simon Marlow :) and what is you explanation why Vyacheslav's programs using getLine does block? -- Best regards,

Re: Concurrency issue with dynamic linker in GHC

2006-10-23 Thread Simon Marlow
Bulat Ziganshin wrote: Hello Simon, Monday, October 23, 2006, 5:05:56 PM, you wrote: Perhaps your bug is that you're using hGetBufNonBlocking, which isn't on Windows? _whose_ bug? you write to Simon Marlow :) Sorry - let me rephrase that: perhaps the problem is that hs-plugins uses

Re: Concurrency issue with dynamic linker in GHC

2006-10-22 Thread Vyacheslav Akhmechet
Thanks guys! I'll try the streams library and see what happens. Bulat: спасибо! ___ Glasgow-haskell-users mailing list Glasgow-haskell-users@haskell.org http://www.haskell.org/mailman/listinfo/glasgow-haskell-users

Re[2]: Concurrency issue with dynamic linker in GHC

2006-10-22 Thread Bulat Ziganshin
Hello Donald, Sunday, October 22, 2006, 9:04:02 AM, you wrote: can't you define this call as 'safe'? But is it safe. Hmm I get kind of queasy when mucking about in the rts. i don't understand you (because of my weak English). 'safe' specifier is just says that function should be called

Re: Concurrency issue with dynamic linker in GHC

2006-10-22 Thread Donald Bruce Stewart
bulat.ziganshin: Hello Donald, Sunday, October 22, 2006, 9:04:02 AM, you wrote: can't you define this call as 'safe'? But is it safe. Hmm I get kind of queasy when mucking about in the rts. i don't understand you (because of my weak English). 'safe' specifier is just says

Re: Concurrency issue with dynamic linker in GHC

2006-10-22 Thread Vyacheslav Akhmechet
Bulat: I didn't get the chance to use the streams library yet, but could you explain how it would solve my locking problem? The core problem that the runtime under Win32 doesn't have an IO manager still remains, correct? Is anyone looking to fix this issue? If not, how hard would it be for me to

Re: Concurrency issue with dynamic linker in GHC

2006-10-22 Thread Vyacheslav Akhmechet
Also, what would it take for me to fix the GHCi crash on Win32 when a plugin is being loaded? I figured I'll ask before blindly jumping into the code :) ___ Glasgow-haskell-users mailing list Glasgow-haskell-users@haskell.org

Re: Concurrency issue with dynamic linker in GHC

2006-10-22 Thread Donald Bruce Stewart
coffeemug: Also, what would it take for me to fix the GHCi crash on Win32 when a plugin is being loaded? I figured I'll ask before blindly jumping into the code :) You need to find the win32 equivalent of the ELF-specific code that ignores requests to load a module multipe times, rather than

Re: Concurrency issue with dynamic linker in GHC

2006-10-21 Thread Bulat Ziganshin
Hello Vyacheslav, Saturday, October 21, 2006, 7:37:19 AM, you wrote: I am running ghc 6.4.2 on a Win32 machine. I'm using hs-plugins in one thread and a simple getLine loop in another. It appears that getLine blocks the hs-plugins thread on Win32 (this has been verified to work fine on

Re[2]: Concurrency issue with dynamic linker in GHC

2006-10-21 Thread Bulat Ziganshin
Hello Bulat, Saturday, October 21, 2006, 12:56:48 PM, you wrote: use 'vGetLine fdStdIn' in order to read lines. you should strip sorry, use do h - bufferBlockStream fdStdIn vGetLine h vGetLine h ... -- Best regards, Bulatmailto:[EMAIL PROTECTED]

Re: Concurrency issue with dynamic linker in GHC

2006-10-21 Thread Donald Bruce Stewart
bulat.ziganshin: Hello Vyacheslav, Saturday, October 21, 2006, 7:37:19 AM, you wrote: I am running ghc 6.4.2 on a Win32 machine. I'm using hs-plugins in one thread and a simple getLine loop in another. It appears that getLine blocks the hs-plugins thread on Win32 (this has been

Re[2]: Concurrency issue with dynamic linker in GHC

2006-10-21 Thread Bulat Ziganshin
Hello Donald, Saturday, October 21, 2006, 1:03:34 PM, you wrote: I am running ghc 6.4.2 on a Win32 machine. I'm using hs-plugins in one Oh, that's almost certainly it. Bulat++ It's blocking on the foreign call (into the linker), since there's no IO manager thread, I think. can't you

Re: Concurrency issue with dynamic linker in GHC

2006-10-21 Thread Donald Bruce Stewart
bulat.ziganshin: Hello Donald, Saturday, October 21, 2006, 1:03:34 PM, you wrote: I am running ghc 6.4.2 on a Win32 machine. I'm using hs-plugins in one Oh, that's almost certainly it. Bulat++ It's blocking on the foreign call (into the linker), since there's no IO manager thread,

Concurrency issue with dynamic linker in GHC

2006-10-20 Thread Vyacheslav Akhmechet
I am running ghc 6.4.2 on a Win32 machine. I'm using hs-plugins in one thread and a simple getLine loop in another. It appears that getLine blocks the hs-plugins thread on Win32 (this has been verified to work fine on freeBSD). I've tried various combinations of -threaded flag and forkIO/forkOS