Skip to content

Commit

Permalink
opDependencies: fix case for vjp.
Browse files Browse the repository at this point in the history
  • Loading branch information
athas committed Nov 19, 2023
1 parent aaf9939 commit adf324f
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions src/Futhark/IR/SOACS/SOAC.hs
Original file line number Diff line number Diff line change
Expand Up @@ -635,10 +635,11 @@ instance (ASTRep rep) => IsOp (SOAC rep) where
lambdaDependencies mempty lam $
zipWith (<>) (map depsOf' args) (map depsOf' vec)
opDependencies (VJP lam args vec) =
mconcat $
replicate 2 $
lambdaDependencies mempty lam $
zipWith (<>) (map depsOf' args) (map depsOf' vec)
lambdaDependencies
mempty
lam
(zipWith (<>) (map depsOf' args) (map depsOf' vec))
<> map (const $ freeIn args <> freeIn lam) (lambdaParams lam)
opDependencies (Screma w arrs (ScremaForm scans reds map_lam)) =
let (scans_in, reds_in, map_deps) =
splitAt3 (scanResults scans) (redResults reds) $
Expand Down

0 comments on commit adf324f

Please sign in to comment.