diff options
| author | Yong He <yonghe@outlook.com> | 2022-10-27 12:30:15 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-10-27 12:30:15 -0700 |
| commit | 8dc9efd256bd211d8c446971f09a7c79e644b110 (patch) | |
| tree | 32612cfbd39531c1f21eab0777cf10a197b269d4 /tests/autodiff/vector-arithmetic-jvp.slang | |
| parent | 0cbef6fd6d7924d37ef3ea5ec7c848c80947d13f (diff) | |
Rename `JVPDerivativeModifier` -> `ForwardDifferentiableAttribute`. (#2472)
Co-authored-by: Yong He <yhe@nvidia.com>
Diffstat (limited to 'tests/autodiff/vector-arithmetic-jvp.slang')
| -rw-r--r-- | tests/autodiff/vector-arithmetic-jvp.slang | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/tests/autodiff/vector-arithmetic-jvp.slang b/tests/autodiff/vector-arithmetic-jvp.slang index b79b3e764..cf0eb6170 100644 --- a/tests/autodiff/vector-arithmetic-jvp.slang +++ b/tests/autodiff/vector-arithmetic-jvp.slang @@ -8,26 +8,30 @@ typedef __DifferentialPair<float2> dpfloat2; typedef __DifferentialPair<float3> dpfloat3; typedef __DifferentialPair<float4> dpfloat4; -__differentiate_jvp float3 f(float3 x) +[ForwardDifferentiable] +float3 f(float3 x) { return x; } -__differentiate_jvp float3 g(float3 x, float3 y) +[ForwardDifferentiable] +float3 g(float3 x, float3 y) { float3 a = x + y; float3 b = x - y; return a * b + 2 * x * y; } -__differentiate_jvp float2 h(float2 x, float2 y) +[ForwardDifferentiable] +float2 h(float2 x, float2 y) { float2 a = x + y; float2 b = x - y; return a * b + 2 * x * y; } -__differentiate_jvp float4 j(float4 x, float4 y) +[ForwardDifferentiable] +float4 j(float4 x, float4 y) { float4 a = x + y; float4 b = x - y; |
