JuliaPerf / BenchmarksGame.jl

Other
43 stars 13 forks source link

protype to compile julia scripts to exe #35

Open SimonDanisch opened 5 years ago

SimonDanisch commented 5 years ago

Shaves off a few ms from the benchmarks:

# current way to benchmark
/BenchmarksGame.jl$ time julia nbody/nbody-fast.jl 50000000
-0.169075164
-0.169059907
real    0m2.639s
user    0m2.763s
sys 0m0.365s

#when compiled 
/BenchmarksGame.jl$ time ./build/nbody-fast 50000000
-0.169075164
-0.169059907
real    0m2.484s
user    0m2.563s
sys 0m0.398s

# Reference when calling 2 times  (first gets called on include)
julia> push!(ARGS, "100")
julia> include("nbody/nbody-fast.jl")
julia> @time NBody.perf_nbody(50000000)
-0.169075164
-0.169059907
  2.334110 seconds (28 allocations: 976 bytes)

Need to discuss how to properly integrate this!