Run time very very slow bug #2

dterei opened this Issue Jun 7, 2011 · 1 comment


None yet
2 participants

dterei commented Jun 7, 2011

The latest fibon and fibon-benchmarks from github seem to have a bad bug in them in regards to the run time of the benchmarks. Running the BinaryTrees benchmark for example using the default config takes 1 day. I've tested this on two different machines and with 7.0.3 and 6.12.3. Interestingly if you modify the BinaryTrees source file and add a print statement to the oldmain function that prints anything, the run time for the benchmark falls to the sane 4 minutes 30 seconds range.

If I run BinaryTrees outside of the fibon framework the runtime is also normal.


dmpots commented Jun 7, 2011

Thanks for the report!

I recently updated the benchmarks so that the Ref run time is more in line with the running time of the spec benchmarks. The old Ref settings are still available as the Train benchmark size. It is certainly possible that I introduced a bug somewhere. It's been working for me with ghc head.

One thing I can think of is that the default config runs the Ref size with -O0 (Base) and -O2 (Peak) each 10 times. I've seen -O0 code run very slowly. You can try just running the Peak setting for one iteration from the command line using

$ fibon-run -i 1 -t Peak

I should probably update the default config so that it runs quickly and doesn't include the -O0 setting. You can set a timeout in a config file using

setTimeout $ Limit 0 10 0

(the Limit constructor takes Hours Minutes Seconds). There are some example config files that might be useful at:

I can't explain why adding a print statement would make it run fast though... I'll have to look into it more because that sounds like a bug.

dterei closed this Mar 13, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment