You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Activity analysis change:
- Mark array literal element addresses (`pointer_to_address` and `index_addr`
instructions) as useful. These addresses legitimately need a derivative.
- Propagate usefulness through array literal element addresses that are `apply`
indirect results to the `apply` arguments.
Pullback generation changes:
- Add special case for array literal element addresses to
`PullbackEmitter::getAdjointProjection`. The adjoint projection is a local
allocation initialized from the array literal's adjoint value by applying
`Array.TangentVector.subscript`.
- This generalizes the old logic in `PullbackEmitter::visit{Store,CopyAddr}Inst`
for handling array literal element addresses.
- When an array literal's adjoint value is updated via
`PullbackEmitter::addAdjointValue`, accumulate the array literal's adjoint
value into the adjoint buffers of its element addresses.
Resolves cleanup task: TF-976.
Fixes correctness issues:
- TF-975: nested array literals.
- TF-978: array literal element address initialized as `apply` indirect result.
Update activity analysis and derivative correctness tests.
0 commit comments