Skip to content

[cudnn] Support v8 API in fbcode#96512

Closed
xw285cornell wants to merge 1 commit intopytorch:masterfrom
xw285cornell:export-D43784279
Closed

[cudnn] Support v8 API in fbcode#96512
xw285cornell wants to merge 1 commit intopytorch:masterfrom
xw285cornell:export-D43784279

Conversation

@xw285cornell
Copy link
Copy Markdown
Contributor

Summary: It turns out we never turn on cudnn v8 API which blocks bf16 conv. Enable the new v8 API

Test Plan: buck run mode/dev-nosan scripts/xdwang/example:fc_pytorch

Reviewed By: ngimel

Differential Revision: D43784279

@pytorch-bot
Copy link
Copy Markdown

pytorch-bot bot commented Mar 10, 2023

🔗 Helpful Links

🧪 See artifacts and rendered test results at hud.pytorch.org/pr/96512

Note: Links to docs will display an error until the docs builds have been completed.

❌ 1 Failures

As of commit 3862dc1:

NEW FAILURES - The following jobs have failed:

This comment was automatically generated by Dr. CI and updates every 15 minutes.

@facebook-github-bot
Copy link
Copy Markdown
Contributor

This pull request was exported from Phabricator. Differential Revision: D43784279

@xw285cornell xw285cornell requested review from malfet and ngimel March 10, 2023 09:18
@facebook-github-bot
Copy link
Copy Markdown
Contributor

This pull request was exported from Phabricator. Differential Revision: D43784279

@xw285cornell
Copy link
Copy Markdown
Contributor Author

@ngimel @malfet if you can help take a look :)

Copy link
Copy Markdown
Contributor

@malfet malfet left a comment

Choose a reason for hiding this comment

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

LGTM, though I'm surprised why size_t cast is needed

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Why this change is needed? If it is, then please use static_cast<size_t>(plan.getWorkspaceSize())

Suggested change
if ((size_t) plan.getWorkspaceSize() <= max_workspace_size) {
if (plan.getWorkspaceSize() <= max_workspace_size) {

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

That's our favorite signed-unsigned comparison probably, can we enable compilation flags to error on it in OSS builds? It's been a nuisance.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Given that getWorkspaceSize() returns int64_t in cudnn frontend, a better fix would be to change our vars like max_worksplace_size and curr_workspace_size to int64_t instead of size_t

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

sounds good! I'll make the change and see if I can make this from warning to error in oss :)

@facebook-github-bot
Copy link
Copy Markdown
Contributor

This pull request was exported from Phabricator. Differential Revision: D43784279

xw285cornell added a commit to xw285cornell/pytorch that referenced this pull request Mar 15, 2023
Summary: As discussed in pytorch#96512, turn on sign-compare for OSS build

Test Plan: pytorch CI

Differential Revision: D44085536

fbshipit-source-id: d2093131d84230aed316f783198f9229f2a773dc
@facebook-github-bot
Copy link
Copy Markdown
Contributor

This pull request was exported from Phabricator. Differential Revision: D43784279

@xw285cornell
Copy link
Copy Markdown
Contributor Author

Looks this PR has a conflict with #96723, will probably wait a bit to get in sync

@facebook-github-bot
Copy link
Copy Markdown
Contributor

This pull request was exported from Phabricator. Differential Revision: D43784279

Summary:
Pull Request resolved: pytorch#96512

It turns out we never turn on cudnn v8 API which blocks bf16 conv. Enable the new v8 API

Test Plan: buck run mode/dev-nosan scripts/xdwang/example:fc_pytorch

Reviewed By: ngimel

Differential Revision: D43784279

fbshipit-source-id: 902a4e162807faae874cc9c4baaa90479cd72006
@facebook-github-bot
Copy link
Copy Markdown
Contributor

This pull request was exported from Phabricator. Differential Revision: D43784279

@facebook-github-bot
Copy link
Copy Markdown
Contributor

@pytorchbot merge

(Initiating merge automatically since Phabricator Diff has merged)

@pytorch-bot pytorch-bot bot added the ciflow/trunk Trigger trunk jobs on your pull request label Mar 23, 2023
@pytorchmergebot
Copy link
Copy Markdown
Collaborator

Merge started

Your change will be merged once all checks pass (ETA 0-4 Hours).

Learn more about merging in the wiki.

Questions? Feedback? Please reach out to the PyTorch DevX Team

Advanced Debugging
Check the merge workflow status
here

cyyever pushed a commit to cyyever/pytorch_private that referenced this pull request Mar 23, 2023
Summary: It turns out we never turn on cudnn v8 API which blocks bf16 conv. Enable the new v8 API

Test Plan: buck run mode/dev-nosan scripts/xdwang/example:fc_pytorch

Reviewed By: ngimel

Differential Revision: D43784279

Pull Request resolved: pytorch/pytorch#96512
Approved by: https://github.com/malfet
cyyever pushed a commit to cyyever/pytorch_private that referenced this pull request Mar 27, 2023
Summary: It turns out we never turn on cudnn v8 API which blocks bf16 conv. Enable the new v8 API

Test Plan: buck run mode/dev-nosan scripts/xdwang/example:fc_pytorch

Reviewed By: ngimel

Differential Revision: D43784279

Pull Request resolved: pytorch/pytorch#96512
Approved by: https://github.com/malfet
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ciflow/trunk Trigger trunk jobs on your pull request fb-exported Merged

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants