Skip to content

Commit

Permalink
Widen gpu allocations buffer
Browse files Browse the repository at this point in the history
  • Loading branch information
charleskawczynski committed Apr 6, 2024
1 parent 6299eb8 commit e048444
Showing 1 changed file with 10 additions and 4 deletions.
14 changes: 10 additions & 4 deletions perf/flame.jl
Original file line number Diff line number Diff line change
Expand Up @@ -88,8 +88,10 @@ using Test
# Threaded/gpu allocations are not deterministic, so let's add a buffer
# TODO: remove buffer, and threaded tests, when
# threaded/unthreaded functions are unified
buffer = if any(x -> occursin(x, job_id), ("threaded", "gpu"))
buffer = if any(x -> occursin(x, job_id), ("threaded",))
1.8
elseif any(x -> occursin(x, job_id), ("gpu",))
5
else
1.1
end
Expand All @@ -108,9 +110,13 @@ end

# https://github.com/CliMA/ClimaAtmos.jl/issues/827
@testset "Allocations limit" begin
@test 0.5 * allocs_limit[job_id] * buffer <=
allocs
allocs_limit[job_id] * buffer
if occursin("gpu", job_id) # https://github.com/CliMA/ClimaAtmos.jl/issues/2831
@test allocs allocs_limit[job_id] * buffer
else
@test 0.25 * allocs_limit[job_id] * buffer <=
allocs
allocs_limit[job_id] * buffer
end
end

import ClimaComms
Expand Down

0 comments on commit e048444

Please sign in to comment.