[GHC] #8289: unused variable in rts/posix/OSMem.c getPageSize
#8289: unused variable in rts/posix/OSMem.c getPageSize ------------------------------------+------------------------------------- Reporter: rwbarton | Owner: Type: bug | Status: new Priority: low | Milestone: Component: Compiler | Version: 7.7 Keywords: | Operating System: Unknown/Multiple Architecture: Unknown/Multiple | Type of failure: None/Unknown Difficulty: Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | ------------------------------------+------------------------------------- bgamari pointed this out on IRC. The static variable `pageSize` is never set, so every `getPageSize` call does a system call. There should be a line `pageSize = ret;` before `return ret;`. -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/8289> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#8289: unused variable in rts/posix/OSMem.c getPageSize -------------------------------------+------------------------------------ Reporter: rwbarton | Owner: Type: bug | Status: new Priority: low | Milestone: Component: Compiler | Version: 7.7 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: Unknown/Multiple Type of failure: None/Unknown | Difficulty: Unknown Test Case: | Blocked By: Blocking: | Related Tickets: -------------------------------------+------------------------------------ Comment (by thoughtpolice): Yep, I saw this too when we were on IRC. I'll go ahead and push a fix for this. -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/8289#comment:1> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#8289: unused variable in rts/posix/OSMem.c getPageSize -------------------------------------+------------------------------------ Reporter: rwbarton | Owner: Type: bug | Status: new Priority: low | Milestone: Component: Compiler | Version: 7.7 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: Unknown/Multiple Type of failure: None/Unknown | Difficulty: Unknown Test Case: | Blocked By: Blocking: | Related Tickets: -------------------------------------+------------------------------------ Comment (by Austin Seipp <austin@…>): In [changeset:57700b9a54f81755e3760e56f3bf34426711b81c/ghc]: {{{ #!CommitTicketReference repository="ghc" revision="57700b9a54f81755e3760e56f3bf34426711b81c" Fix getPageSize to actually cache the page size. This fixes #8289. Signed-off-by: Austin Seipp <austin@well-typed.com> }}} -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/8289#comment:2> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#8289: unused variable in rts/posix/OSMem.c getPageSize -------------------------------------+------------------------------------ Reporter: rwbarton | Owner: Type: bug | Status: closed Priority: low | Milestone: Component: Compiler | Version: 7.7 Resolution: fixed | Keywords: Operating System: Unknown/Multiple | Architecture: Unknown/Multiple Type of failure: None/Unknown | Difficulty: Unknown Test Case: | Blocked By: Blocking: | Related Tickets: -------------------------------------+------------------------------------ Changes (by thoughtpolice): * status: new => closed * resolution: => fixed -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/8289#comment:3> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
participants (1)
-
GHC