Re: [GHC] #716: Unloading a dll generated by GHC doesn't free all resources

2007-11-05 Thread GHC
#716: Unloading a dll generated by GHC doesn't free all resources
+---
 Reporter:  [EMAIL PROTECTED]  |  Owner:  igloo  
 Type:  bug | Status:  closed 
 Priority:  normal  |  Milestone:  6.6.2  
Component:  Runtime System  |Version:  6.4.1  
 Severity:  normal  | Resolution:  fixed  
 Keywords:  | Difficulty:  Unknown
 Testcase:  |   Architecture:  Unknown
   Os:  Unknown |  
+---
Changes (by simonmar):

  * status:  new => closed
  * resolution:  => fixed

Comment:

 The only remaining issue related to this is #1663, as far as I know.

-- 
Ticket URL: 
GHC 
The Glasgow Haskell Compiler___
Glasgow-haskell-bugs mailing list
Glasgow-haskell-bugs@haskell.org
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs


Re: [GHC] #716: Unloading a dll generated by GHC doesn't free all resources

2007-02-23 Thread GHC
#716: Unloading a dll generated by GHC doesn't free all resources
+---
 Reporter:  [EMAIL PROTECTED]  |  Owner:  igloo  
 Type:  bug | Status:  new
 Priority:  normal  |  Milestone:  6.6.2  
Component:  Runtime System  |Version:  6.4.1  
 Severity:  normal  | Resolution: 
 Keywords:  | Difficulty:  Unknown
 Testcase:  |   Architecture:  Unknown
   Os:  Unknown |  
+---
Changes (by igloo):

  * milestone:  6.6.1 => 6.6.2
  * priority:  high => normal

Comment:

 I've added a tarball (dlls.tar.gz) which contains code for a C program
 that loads a Haskell DLL, calls something from it and unloads it, in a
 loop. It now seems to run happily no matter how many times it iterates,
 but there seems to be a performance issue: the system time is quadratic in
 the number of iterations. I haven't looked into what's causing this (not
 even tested to see if the same thing happens with a C DLL).

-- 
Ticket URL: 
GHC 
The Glasgow Haskell Compiler___
Glasgow-haskell-bugs mailing list
Glasgow-haskell-bugs@haskell.org
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs


Re: [GHC] #716: Unloading a dll generated by GHC doesn't free all resources

2006-11-17 Thread GHC
#716: Unloading a dll generated by GHC doesn't free all resources
+---
 Reporter:  [EMAIL PROTECTED]  |  Owner:  igloo  
 Type:  bug | Status:  new
 Priority:  high|  Milestone:  6.6.1  
Component:  Runtime System  |Version:  6.4.1  
 Severity:  normal  | Resolution: 
 Keywords:  | Difficulty:  Unknown
 Testcase:  |   Architecture:  Unknown
   Os:  Unknown |  
+---
Changes (by simonmar):

  * priority:  normal => high
  * testcase:  =>
  * status:  reopened => new
  * owner:  simonmar => igloo

-- 
Ticket URL: 
GHC 
The Glasgow Haskell Compiler___
Glasgow-haskell-bugs mailing list
Glasgow-haskell-bugs@haskell.org
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs


Re: [GHC] #716: Unloading a dll generated by GHC doesn't free all resources

2006-09-29 Thread GHC
#716: Unloading a dll generated by GHC doesn't free all resources
-+--
  Reporter:  [EMAIL PROTECTED]  |  Owner:  simonmar
  Type:  bug | Status:  reopened
  Priority:  normal  |  Milestone:  6.6.1   
 Component:  Runtime System  |Version:  6.4.1   
  Severity:  normal  | Resolution:  
  Keywords:  | Os:  Unknown 
Difficulty:  Unknown |   Architecture:  Unknown 
-+--
Changes (by simonmar):

  * milestone:  6.6 => 6.6.1

Comment:

 Punt to 6.6.1 - it may be fixed, but we need to investigate fully.
 Related to #804.

-- 
Ticket URL: 
GHC 
The Glasgow Haskell Compiler___
Glasgow-haskell-bugs mailing list
Glasgow-haskell-bugs@haskell.org
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs


Re: [GHC] #716: Unloading a dll generated by GHC doesn't free all resources

2006-03-21 Thread GHC
#716: Unloading a dll generated by GHC doesn't free all resources
-+--
  Reporter:  [EMAIL PROTECTED]  |  Owner:  simonmar
  Type:  bug | Status:  reopened
  Priority:  normal  |  Milestone:  6.6 
 Component:  Runtime System  |Version:  6.4.1   
  Severity:  normal  | Resolution:  
  Keywords:  | Os:  Unknown 
Difficulty:  Unknown |   Architecture:  Unknown 
-+--
Changes (by simonmar):

  * resolution:  fixed =>
  * milestone:  6.4.2 => 6.6
  * status:  closed => reopened

Comment:

 On second thoughts I'll leave the ticket open until it's fully fixed.  I
 don't expect to fix it properly in 6.4.2, though - the best chance for a
 complete fix is in the HEAD with the threaded RTS.  As far as I'm aware,
 in the HEAD's threaded RTS, all threads should shut down properly at exit
 except those currently blocked in foreign calls.

-- 
Ticket URL: 
GHC 
The Glasgow Haskell Compiler___
Glasgow-haskell-bugs mailing list
Glasgow-haskell-bugs@haskell.org
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs


Re: [GHC] #716: Unloading a dll generated by GHC doesn't free all resources

2006-03-21 Thread GHC
#716: Unloading a dll generated by GHC doesn't free all resources
-+--
  Reporter:  [EMAIL PROTECTED]  |  Owner:  simonmar
  Type:  bug | Status:  closed  
  Priority:  normal  |  Milestone:  6.4.2   
 Component:  Runtime System  |Version:  6.4.1   
  Severity:  normal  | Resolution:  fixed   
  Keywords:  | Os:  Unknown 
Difficulty:  Unknown |   Architecture:  Unknown 
-+--
Changes (by simonmar):

  * resolution:  => fixed
  * status:  new => closed

Comment:

 Now fixed, at least partially.  Please test.  I've addressed the timer
 thread issue.

 I've run a test program that loads & unloads a DLL several hundred times
 without crashing (it used to crash before the patch).

-- 
Ticket URL: 
GHC 
The Glasgow Haskell Compiler___
Glasgow-haskell-bugs mailing list
Glasgow-haskell-bugs@haskell.org
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs


Re: [GHC] #716: Unloading a dll generated by GHC doesn't free all resources

2006-03-16 Thread GHC
#716: Unloading a dll generated by GHC doesn't free all resources
-+--
  Reporter:  [EMAIL PROTECTED]  |  Owner:  simonmar
  Type:  bug | Status:  new 
  Priority:  normal  |  Milestone:  6.4.2   
 Component:  Runtime System  |Version:  6.4.1   
  Severity:  normal  | Resolution:  
  Keywords:  | Os:  Unknown 
Difficulty:  Unknown |   Architecture:  Unknown 
-+--
Changes (by simonmar):

  * component:  Compiler => Runtime System
  * milestone:  => 6.4.2
  * owner:  => simonmar

Comment:

 I have a better patch for timeslicing floating around (make the timer
 interval configurable) but it needs more testing.

 In the meantime, we'll do '''something''' about this before 6.4.2.

-- 
Ticket URL: 
GHC 
The Glasgow Haskell Compiler___
Glasgow-haskell-bugs mailing list
Glasgow-haskell-bugs@haskell.org
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs


Re: [GHC] #716: Unloading a dll generated by GHC doesn't free all resources

2006-03-08 Thread GHC
#716: Unloading a dll generated by GHC doesn't free all resources
-+--
  Reporter:  [EMAIL PROTECTED]  |  Owner: 
  Type:  bug | Status:  new
  Priority:  normal  |  Milestone: 
 Component:  Compiler|Version:  6.4.1  
  Severity:  normal  | Resolution: 
  Keywords:  | Os:  Unknown
Difficulty:  Unknown |   Architecture:  Unknown
-+--
Comment (by [EMAIL PROTECTED]):

 Sometimes (very often?) it's not really necessary to have timer interrupts
 running in the Haskell rts.
 I've added a patch that allows you to turn them off by specifying a
 negative value to the -C flag.

 Using this feature I can get around the access violation that sometimes
 occurs when unloading a DLL.  A proper fix for the race condition is still
 needed, though.

-- 
Ticket URL: 
GHC 
The Glasgow Haskell Compiler___
Glasgow-haskell-bugs mailing list
Glasgow-haskell-bugs@haskell.org
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs


Re: [GHC] #716: Unloading a dll generated by GHC doesn't free all resources

2006-03-08 Thread GHC
#716: Unloading a dll generated by GHC doesn't free all resources
-+--
  Reporter:  [EMAIL PROTECTED]  |  Owner: 
  Type:  bug | Status:  new
  Priority:  normal  |  Milestone: 
 Component:  Compiler|Version:  6.4.1  
  Severity:  normal  | Resolution: 
  Keywords:  | Os:  Unknown
Difficulty:  Unknown |   Architecture:  Unknown
-+--
Comment (by [EMAIL PROTECTED]):

 After some more examination I've seen that the threads are supposed to
 exit.
 BUT, it doesn't really work because of a bad race condition.

 Take stopTicker().  It sends an event to the tick thread that tells it
 to exit.  But then it never waits for the thread to actually exit!
 This means that when the tick thread get scheduled to run the Haskell
 DLL migh have been unloaded from memory.  And it seems that that this
 really happens, albeit rarely.

 For each occurence of _beginthreadex() in the code there really needs to
 be a corresponding call that waits for the thread to shut down when
 exiting.  You can't rely on thread scheduling to run things in the right
 order.

-- 
Ticket URL: 
GHC 
The Glasgow Haskell Compiler___
Glasgow-haskell-bugs mailing list
Glasgow-haskell-bugs@haskell.org
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs


Re: [GHC] #716: Unloading a dll generated by GHC doesn't free all resources

2006-03-08 Thread GHC
#716: Unloading a dll generated by GHC doesn't free all resources
-+--
  Reporter:  [EMAIL PROTECTED]  |  Owner: 
  Type:  bug | Status:  new
  Priority:  normal  |  Milestone: 
 Component:  Compiler|Version:  6.4.1  
  Severity:  normal  | Resolution: 
  Keywords:  | Os:  Unknown
Difficulty:  Unknown |   Architecture:  Unknown
-+--
-- 
Ticket URL: 
GHC 
The Glasgow Haskell Compiler___
Glasgow-haskell-bugs mailing list
Glasgow-haskell-bugs@haskell.org
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs


[GHC] #716: Unloading a dll generated by GHC doesn't free all resources

2006-03-08 Thread GHC
#716: Unloading a dll generated by GHC doesn't free all resources
---+
Reporter:  [EMAIL PROTECTED]  |Owner: 
Type:  bug |   Status:  new
Priority:  normal  |Milestone: 
   Component:  Compiler|  Version:  6.4.1  
Severity:  normal  | Keywords: 
  Os:  Unknown |   Difficulty:  Unknown
Architecture:  Unknown |  
---+
There seems to be resource leaks in load&unload of a DLL.
 If you put it in a loop strange thing can happen.

 So one thing I notiticed is that several places
 (Ticker.c, IOManager.c) create threads, but I could not
 find the place where these threads die.
 How are they supposed to die shutdownHaskell() is called?

-- 
Ticket URL: 
GHC 
The Glasgow Haskell Compiler___
Glasgow-haskell-bugs mailing list
Glasgow-haskell-bugs@haskell.org
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs