Skip to content

Commit

Permalink
add Const for Enzyme.autodiff_deferred function arg
Browse files Browse the repository at this point in the history
  • Loading branch information
omlins committed Dec 4, 2024
1 parent e6221c6 commit 85db9c3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion test/ParallelKernel/test_parallel.jl
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ macro compute_with_aliases(A) esc(:(ix + (iz -1)*size($A,1)
return
end
@parallel configcall=f!(A, B, a) AD.autodiff_deferred!(Enzyme.Reverse, f!, Const, DuplicatedNoNeed(A, Ā), DuplicatedNoNeed(B, B̄), Const(a)) # NOTE: f! is automatically promoted to Const.
Enzyme.autodiff_deferred(Enzyme.Reverse, g!, Const, DuplicatedNoNeed(A_ref, Ā_ref), DuplicatedNoNeed(B_ref, B̄_ref), Const(a))
Enzyme.autodiff_deferred(Enzyme.Reverse, Const(g!), Const, DuplicatedNoNeed(A_ref, Ā_ref), DuplicatedNoNeed(B_ref, B̄_ref), Const(a))
@test Array(Ā) Ā_ref
@test Array(B̄) B̄_ref
end
Expand Down

0 comments on commit 85db9c3

Please sign in to comment.