Skip to content

Commit c507e37

Browse files
authored
Add needs primal for forward mode (#192)
1 parent ad508b9 commit c507e37

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/Interpreter.jl

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -274,6 +274,8 @@ end
274274
outtys = MLIR.IR.Type[]
275275
@inline needs_primal(::Type{<:Enzyme.ReverseMode{ReturnPrimal}}) where {ReturnPrimal} =
276276
ReturnPrimal
277+
@inline needs_primal(::Type{<:Enzyme.ForwardMode{ReturnPrimal}}) where {ReturnPrimal} =
278+
ReturnPrimal
277279
for a in linear_results
278280
if has_residx(a)
279281
if needs_primal(CMode)

0 commit comments

Comments
 (0)