Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ DiffResults = "1.1"
DiffRules = "1.4"
DiffTests = "0.1"
IrrationalConstants = "0.1, 0.2"
JET = "0.9, 0.10, 0.11"
JET = "0.9, 0.12"
LogExpFunctions = "0.3, 1"
NaNMath = "1"
Preferences = "1"
Expand Down
16 changes: 9 additions & 7 deletions test/QATest.jl
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,16 @@ module QATest
using ForwardDiff
using Test

using JET: @test_opt
import JET

@testset "JET" begin
# issue #778
@test_opt ForwardDiff.derivative(identity, 1.0)
@test_opt ForwardDiff.gradient(only, [1.0], ForwardDiff.GradientConfig(only, [1.0], ForwardDiff.Chunk{1}()))
@test_opt ForwardDiff.jacobian(identity, [1.0], ForwardDiff.JacobianConfig(identity, [1.0], ForwardDiff.Chunk{1}()))
@test_opt ForwardDiff.hessian(only, [1.0], ForwardDiff.HessianConfig(only, [1.0], ForwardDiff.Chunk{1}()))
if VERSION < v"1.12" || JET.JET_AVAILABLE
@testset "JET" begin
# issue #778
JET.@test_opt ForwardDiff.derivative(identity, 1.0)
JET.@test_opt ForwardDiff.gradient(only, [1.0], ForwardDiff.GradientConfig(only, [1.0], ForwardDiff.Chunk{1}()))
JET.@test_opt ForwardDiff.jacobian(identity, [1.0], ForwardDiff.JacobianConfig(identity, [1.0], ForwardDiff.Chunk{1}()))
JET.@test_opt ForwardDiff.hessian(only, [1.0], ForwardDiff.HessianConfig(only, [1.0], ForwardDiff.Chunk{1}()))
end
end

end # module