#4450: Do stack squeezing before expanding stack
---------------------------------+------------------------------------------
    Reporter:  simonpj           |        Owner:              
        Type:  bug               |       Status:  new         
    Priority:  normal            |    Milestone:              
   Component:  Compiler          |      Version:  6.12.3      
    Keywords:                    |     Testcase:              
   Blockedby:                    |   Difficulty:              
          Os:  Unknown/Multiple  |     Blocking:              
Architecture:  Unknown/Multiple  |      Failure:  None/Unknown
---------------------------------+------------------------------------------
 The presenting effect is that `nofib/spectral/hartel/genfft` exhibits non-
 deterministic allocation behaviour:
 {{{
 ./fft-noticky 7 +RTS -sstderr
 13735234/185243
      112,177,208 bytes allocated in the heap
       61,405,448 bytes copied during GC
       15,156,968 bytes maximum residency (8 sample(s))
       13,590,616 bytes maximum slop
               40 MB total memory in use (8 MB lost due to fragmentation)

   Generation 0:   151 collections,     0 parallel,  0.10s,  0.10s elapsed
   Generation 1:     8 collections,     0 parallel,  0.06s,  0.06s elapsed

   INIT  time    0.00s  (  0.00s elapsed)
   MUT   time    0.08s  (  0.08s elapsed)
   GC    time    0.16s  (  0.16s elapsed)
   EXIT  time    0.00s  (  0.00s elapsed)
   Total time    0.25s  (  0.25s elapsed)

   %GC time      66.3%  (66.8% elapsed)

   Alloc rate    1,343,359,176 bytes per MUT second

   Productivity  32.9% of total user, 33.1% of total elapsed

 -----------------------------
 ./fft-noticky 7 +RTS -sstderr
 13735234/185243
      114,257,976 bytes allocated in the heap
       61,405,448 bytes copied during GC
       15,156,968 bytes maximum residency (8 sample(s))
       14,622,696 bytes maximum slop
               40 MB total memory in use (6 MB lost due to fragmentation)

   Generation 0:   151 collections,     0 parallel,  0.11s,  0.11s elapsed
   Generation 1:     8 collections,     0 parallel,  0.06s,  0.06s elapsed

   INIT  time    0.00s  (  0.00s elapsed)
   MUT   time    0.08s  (  0.08s elapsed)
   GC    time    0.17s  (  0.17s elapsed)
   EXIT  time    0.00s  (  0.00s elapsed)
   Total time    0.25s  (  0.25s elapsed)

   %GC time      66.4%  (66.8% elapsed)

   Alloc rate    1,354,200,704 bytes per MUT second

   Productivity  32.9% of total user, 33.0% of total elapsed
 }}}
 The non-determinism goes away with the RTS opt `-V0`.

 In discussion we think the allocation differs because stack-squeezing
 happens differently in the two runs.

-- 
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/4450>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
_______________________________________________
Glasgow-haskell-bugs mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs

Reply via email to