Skip to content

Commit

Permalink
Add jlarrays test
Browse files Browse the repository at this point in the history
  • Loading branch information
wsmoses committed Dec 23, 2024
1 parent 7626c52 commit dbd2836
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 0 deletions.
1 change: 1 addition & 0 deletions test/Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ LLVM = "929cbde3-209d-540e-8aea-75f648917ca0"
LLVM_jll = "86de99a1-58d6-5da7-8064-bd56ce2e322c"
LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e"
LogExpFunctions = "2ab3a3ac-af41-5b50-aa03-7779005ae688"
JLArrays = "27aeb0d3-9eb9-45fb-866b-73c2ecf80fcb"
Pkg = "44cfe95a-1eb2-52ea-b672-e2afdf69b78f"
Random = "9a3f8284-a2c9-5f02-9a11-845980a1fd5c"
SparseArrays = "2f01184e-e22b-5df5-ae63-d93ebab69eaf"
Expand Down
10 changes: 10 additions & 0 deletions test/ext/jlarrays.jl
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
using Enzyme, Test, JLArrays

function jlres(x)
2 * x
end

@testset "JLArrays" begin
Enzyme.jacobian(Forward, jlres, JLArray([3.0, 5.0]))
Enzyme.jacobian(Reverse, jlres, JLArray([3.0, 5.0]))
end
1 change: 1 addition & 0 deletions test/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -3778,5 +3778,6 @@ include("ext/logexpfunctions.jl")
include("ext/bfloat16s.jl")
end

include("ext/jlarrays.jl")
include("ext/sparsearrays.jl")
include("ext/staticarrays.jl")

0 comments on commit dbd2836

Please sign in to comment.