Skip to content

Commit

Permalink
add more compute in sum/_sum
Browse files Browse the repository at this point in the history
  • Loading branch information
yebai authored May 30, 2024
1 parent a0a67e2 commit 3b6cee4
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions bench/run_benchmarks.jl
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ function _sum(x::AbstractArray{<:Real})
n = 0
while n < length(x)
n += 1
y += x[n]
y += sin(cos(exp(x[n])))
end
return y
end
Expand Down Expand Up @@ -137,8 +137,8 @@ an array.
"""
function generate_inter_framework_tests()
return Any[
("sum", (sum, randn(100))),
("_sum", (_sum, randn(100))),
("sum_sin_cos_exp", (x -> sum(sin.(cos.(exp.(x)))), randn(10_000))),
("_sum_sin_cos_exp", (_sum, randn(10_000))),
("kron_sum", (_kron_sum, randn(20, 20), randn(40, 40))),
("kron_view_sum", (_kron_view_sum, randn(40, 30), randn(40, 40))),
("naive_map_sin_cos_exp", (_naive_map_sin_cos_exp, randn(10, 10))),
Expand Down

0 comments on commit 3b6cee4

Please sign in to comment.