Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[AutoDiff] Fix activity analysis for side-effecting instructions. #21826

Merged
merged 1 commit into from Jan 13, 2019

Conversation

dan-zheng
Copy link
Collaborator

  • Now, all address-operands of side-effecting instructions are marked as
    useful only if any result is useful.

    • This enables differentiation of non-useful mutation (so functions can
      mutate outside state).
    • Previously, all address-operands and results of side-effecting
      instructions were unconditionally marked as useful.
  • If the source of an "modifying" side-effecting instruction
    (e.g. store or copy_addr) is varied, recursively mark results
    and their operands as varied.

- Now, all address-operands of side-effecting instructions are marked as
  useful only if any result is useful.
  - This enables differentiation of non-useful mutation (so functions can
    mutate outside state).
  - Previously, all address-operands and results of side-effecting
    instructions were unconditionally marked as useful.

- If the source of an "modifying" side-effecting instruction
  (e.g. `store` or `copy_addr`) is varied, recursively mark results
  and their operands as varied.
@dan-zheng dan-zheng added the tensorflow This is for "tensorflow" branch PRs. label Jan 13, 2019
@dan-zheng
Copy link
Collaborator Author

@swift-ci Please test tensorflow

@dan-zheng dan-zheng requested a review from rxwei January 13, 2019 07:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
tensorflow This is for "tensorflow" branch PRs.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants