Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fortran compiler "cheating" at Fibonacci benchmark #58

Open
MilesCranmer opened this issue Mar 14, 2022 · 2 comments
Open

Fortran compiler "cheating" at Fibonacci benchmark #58

MilesCranmer opened this issue Mar 14, 2022 · 2 comments

Comments

@MilesCranmer
Copy link
Sponsor Member

FYI the fortran compiler is "cheating" at two benchmarks: fibonacci and mandelbrot. See the latest benchmark results: https://github.com/JuliaLang/Microbenchmarks/runs/5503666442?check_suite_focus=true#step:17:25.

For Fibonacci, C gives a time of 0.021 whereas fortran gives a time of 0.000037.

For Mandelbrot, C gives a time of 0.068 whereas fortran gives a time of 0.000066.

I assume the latest fortran compiler has translated these benchmarks to analytic versions.

@acxz
Copy link
Contributor

acxz commented Mar 23, 2022

For fib this repo may have some solutions for us: https://github.com/drujensen/fib

@KristofferC
Copy link
Sponsor Member

It's usually good to feed inputs from a file or stdin to prevent specialising on benchmark constants.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants