Skip to content

Ad ptr merge #1

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

Draft
wants to merge 736 commits into
base: autodiff
Choose a base branch
from
Draft

Ad ptr merge #1

wants to merge 736 commits into from

Conversation

NeuralCoder3
Copy link
Owner

To review the changes and keep track of changes.

@@ -29,6 +49,7 @@ add_thorin_dialect(clos
clos/phase/lower_typed_clos.cpp
clos/phase/lower_typed_clos.h
mem/passes/fp/copy_prop.cpp
mem/passes/rw/reshape.cpp
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Check if inter-dialect phases are necessary here.


auto cmp = core::op(core::icmp::ul, iter, end);
for_lam->branch(false, cmp, new_body, if_else, w.tuple());
for_lam->branch(false, cmp, new_body, if_else, acc);
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@christopherhjung
Is the inlining/forwarding of the accumulator necessary here?
Optimizations like CopyProp will probably delete the arguments.
And Closure Conversion has as one main function closing open terms and will (if not inlined) re-add the accumulator and bound variables as arguments.

@NeuralCoder3
Copy link
Owner Author

NeuralCoder3 commented Nov 3, 2022

@christopherhjung Reshape has problems with empty arguments (or higher-order arguments).
Example: lit/clos/pow_ad_eval_simpl.thorin

NeuralCoder3 added a commit that referenced this pull request Jan 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants