[GHC] #13830: '+RTS -s' gives incorrect value for work balance in some cases

#13830: '+RTS -s' gives incorrect value for work balance in some cases -------------------------------------+------------------------------------- Reporter: duog | Owner: (none) Type: bug | Status: new Priority: normal | Milestone: Component: Runtime | Version: 8.0.1 System | Keywords: | Operating System: Unknown/Multiple Architecture: | Type of failure: Debugging Unknown/Multiple | information is incorrect Test Case: | Blocked By: Blocking: | Related Tickets: Differential Rev(s): | Wiki Page: -------------------------------------+------------------------------------- The formula for work balance as printed by the rts -s flag does not account for the possibility of the number of capabilities changing. Nor does it account for the number of garbage collection threads being other than n_capabilities. The attached program demonstrates the first problem, with instructions for replication in comments. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/13830 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#13830: '+RTS -s' gives incorrect value for work balance in some cases -------------------------------------+------------------------------------- Reporter: duog | Owner: (none) Type: bug | Status: new Priority: normal | Milestone: Component: Runtime System | Version: 8.0.1 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: Type of failure: Debugging | Unknown/Multiple information is incorrect | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Changes (by duog): * Attachment "Main.hs" added. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/13830 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#13830: '+RTS -s' gives incorrect value for work balance in some cases -------------------------------------+------------------------------------- Reporter: duog | Owner: (none) Type: bug | Status: new Priority: normal | Milestone: Component: Runtime System | Version: 8.0.1 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: Type of failure: Debugging | Unknown/Multiple information is incorrect | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Comment (by bgamari): Mmm, I suspect there are a lot of these sorts of issues since dynamically changing the number of capabilities was something of an afterthought AFAIK. See #13836 for another which I spotted a few days ago. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/13830#comment:1 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#13830: '+RTS -s' gives incorrect value for work balance in some cases -------------------------------------+------------------------------------- Reporter: duog | Owner: duog Type: bug | Status: new Priority: normal | Milestone: Component: Runtime System | Version: 8.0.1 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: Type of failure: Debugging | Unknown/Multiple information is incorrect | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Changes (by duog): * owner: (none) => duog Comment: The number of garbage collection threads is limited to the number of cores right? I believe that this bug will result in the work balance being significantly under reported if the number of capabilities is much more than the number of gc threads. I don't expect dynamically changing capabilities is very common in the wild, but a number of capabilities several times the number of cores may be, I think I remember a blog post of Simon Marlow's saying that they do that at facebook. I'm assigning this to myself as I have a fix in mind: track a value like (or instead of) cumulative_par_max_copied_bytes. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/13830#comment:2 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#13830: '+RTS -s' gives incorrect value for work balance in some cases -------------------------------------+------------------------------------- Reporter: duog | Owner: duog Type: bug | Status: patch Priority: normal | Milestone: Component: Runtime System | Version: 8.0.1 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: Type of failure: Debugging | Unknown/Multiple information is incorrect | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Phab:3658 Wiki Page: | -------------------------------------+------------------------------------- Changes (by duog): * status: new => patch * differential: => Phab:3658 -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/13830#comment:3 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#13830: '+RTS -s' gives incorrect value for work balance in some cases -------------------------------------+------------------------------------- Reporter: duog | Owner: duog Type: bug | Status: patch Priority: normal | Milestone: Component: Runtime System | Version: 8.0.1 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: Type of failure: Debugging | Unknown/Multiple information is incorrect | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Phab:D3658 Wiki Page: | -------------------------------------+------------------------------------- Changes (by RyanGlScott): * differential: Phab:3658 => Phab:D3658 -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/13830#comment:4 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#13830: '+RTS -s' gives incorrect value for work balance in some cases
-------------------------------------+-------------------------------------
Reporter: duog | Owner: duog
Type: bug | Status: patch
Priority: normal | Milestone:
Component: Runtime System | Version: 8.0.1
Resolution: | Keywords:
Operating System: Unknown/Multiple | Architecture:
Type of failure: Debugging | Unknown/Multiple
information is incorrect | Test Case:
Blocked By: | Blocking:
Related Tickets: | Differential Rev(s): Phab:D3658
Wiki Page: |
-------------------------------------+-------------------------------------
Comment (by Ben Gamari

#13830: '+RTS -s' gives incorrect value for work balance in some cases -------------------------------------+------------------------------------- Reporter: duog | Owner: duog Type: bug | Status: closed Priority: normal | Milestone: 8.4.1 Component: Runtime System | Version: 8.0.1 Resolution: fixed | Keywords: Operating System: Unknown/Multiple | Architecture: Type of failure: Debugging | Unknown/Multiple information is incorrect | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Phab:D3658 Wiki Page: | -------------------------------------+------------------------------------- Changes (by bgamari): * status: patch => closed * resolution: => fixed * milestone: => 8.4.1 -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/13830#comment:6 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler
participants (1)
-
GHC