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

Compile forward function in baseline backward benchmarks #3300

Merged
merged 3 commits into from
Nov 2, 2024

Conversation

Priya2698
Copy link
Collaborator

@Priya2698 Priya2698 commented Oct 29, 2024

Currently, the backward benchmark for torch.compile are compiling the output.backward(grads) function.
This PR changes the benchmarks to compile the corresponding forward function.

The benchmarking results are at: http://nv/emR
Earlier, I was observing similar performance for eager and torchcompile for these backward benchmarks.
The files *_bwd.py are changed in this PR. We observe improved performance with torchcompile as compared to eager now. Note, that, the results from weekly will have more data points than the CI pipeline.

Question: test_gelu_bwd_reduction.py reduces the gradient of the input. I am not sure what would be the right function to compile here :/

Thanks to @xwang233 for help with running the CI pipeline!

@xwang233
Copy link
Collaborator

!build

@Priya2698
Copy link
Collaborator Author

!build

Copy link
Collaborator

@liqiangxl liqiangxl left a comment

Choose a reason for hiding this comment

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

LGTM.

@Priya2698 Priya2698 merged commit 84431f7 into main Nov 2, 2024
47 checks passed
@Priya2698 Priya2698 deleted the pm/simplify_bwd_baselines branch November 2, 2024 00:01
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