Fetching latest commit…
Cannot retrieve the latest commit at this time.
# This repo contains a snapshot of a version of ThreadScope from # http://code.haskell.org/ThreadScope/ # a version of ghc-events from # http://code.haskell.org/~duncan/ghc-events/ # and a copy of the sample parallel Haskell program # http://code.haskell.org/~duncan/parlist.hs # All three are modified. # There are also plot scripts generated using gnuplot, see # http://www.gnuplot.info/ # The ghc version required to compile the included ghc-events # is the one from # http://darcs.haskell.org/~duncan/ghc/ # Threadscope sources can be compiled with any GHC version # that copes with gtk2hs. # Instructions: # To see the plots, compile and run tests (using the right ghc version). # Or you can skip the next 4 lines and use pregenerated test data. ghc -O -eventlog -rtsopts parlist.hs --make -threaded ./parlist +RTS -N2 -ls ghc -O -eventlog -rtsopts parlist2.hs --make -threaded ./parlist2 +RTS -N2 -ls # At this point, the data can be loaded into and visualized using ThreadScope. # To see gnuplot graphs of the data, compile the tools and do the following # (shown only for parlist.eventlog; you can do the same using parlist2.eventlog # and see different plots, for a test with faulty parallelisation). cd ghc-events/; cabal install; cd .. show-ghc-events parlist.eventlog > output.dat # Now run gnuplot. gnuplot # And enter the following gnuplot directives. load "pool_size.plt" load "pool_size_max_min_original.plt" load "pool_size_max_min_mean.plt" load "pool_size_out.plt" load "pool_size_max_out.plt" load "pool_size_min_out.plt" load "pool_size_mean_out.plt" load "pool_size_max_min_out.plt" load "pool_size_max_min_mean_out.plt" load "creation_velocity.plt" load "disposal_velocity.plt" load "creation_velocity_out.plt" load "disposal_velocity_out.plt" # to generate the plots as picture files, do, e.g., set term pngcairo size 600, 400 # and repeat the loads, naming the pictures before each, as in set output "png/pool_size.png" # deprecated plots: # too much vertical space taken; too similar for different data (close to y=x) load "creation_cumulative.plt" load "disposal_cumulative.plt" # Data is not continuous, so derivative does not exist, # so the difference quotient does not make sense and looks bad: # we have a saw pattern and the more samples, the more it is just # a sequence of separate peaks of equal height (binary signal: 0 and 1). # The area under the graph still corresponds to the number of spark # transitions, as required, but it's effectively via counting the peaks. # With uneven distribution of samples it's even worse, because the same # data in different parts of the graph looks very differently # (binary, horizontal signal vs. aggregated, vertical signal on the same graph). load "cr_local_speed.plt" load "di_local_speed.plt" # speed averaged over arbitrary, too big interval (from start to sample point); # the higher the time, the more smooth the curve load "creation_speed.plt" load "disposal_speed.plt"