Skip to content

reland fp8 kv cache dequantization fix#3956

Closed
mxz297 wants to merge 1 commit into
pytorch:mainfrom
mxz297:export-D72799994
Closed

reland fp8 kv cache dequantization fix#3956
mxz297 wants to merge 1 commit into
pytorch:mainfrom
mxz297:export-D72799994

Conversation

@mxz297

@mxz297 mxz297 commented Apr 10, 2025

Copy link
Copy Markdown
Contributor

Summary:
This is a reland of D72062745, which was reverted as it broke NV.

In this diff, we have separate kernels for AMD and NV, so it won't have any unintended side effects to NV kernels.

For the AMD kernel, we continue to use one warp for a row. And because AMD has 64 threads per warp, we let the first 32 threads handle K and second 32 threads handle V.

Differential Revision: D72799994

@facebook-github-bot

Copy link
Copy Markdown
Contributor

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

@netlify

netlify Bot commented Apr 10, 2025

Copy link
Copy Markdown

Deploy Preview for pytorch-fbgemm-docs ready!

Name Link
🔨 Latest commit a25f605
🔍 Latest deploy log https://app.netlify.com/sites/pytorch-fbgemm-docs/deploys/67f981d1eac58b00081147d8
😎 Deploy Preview https://deploy-preview-3956--pytorch-fbgemm-docs.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@mxz297 mxz297 force-pushed the export-D72799994 branch from ba885de to f5e8768 Compare April 11, 2025 20:00
mxz297 added a commit to mxz297/FBGEMM that referenced this pull request Apr 11, 2025
Summary:

X-link: facebookresearch/FBGEMM#1041

This is a reland of D72062745, which was reverted as it broke NV.

In this diff, we have separate kernels for AMD and NV, so it won't have any unintended side effects to NV kernels.

For the AMD kernel, we continue to use one warp for a row. And because AMD has 64 threads per warp, we let the first 32 threads handle K and second 32 threads handle V.

Differential Revision: D72799994
@facebook-github-bot

Copy link
Copy Markdown
Contributor

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

mxz297 added a commit to mxz297/FBGEMM that referenced this pull request Apr 11, 2025
Summary:

X-link: facebookresearch/FBGEMM#1041

This is a reland of D72062745, which was reverted as it broke NV.

In this diff, we have separate kernels for AMD and NV, so it won't have any unintended side effects to NV kernels.

For the AMD kernel, we continue to use one warp for a row. And because AMD has 64 threads per warp, we let the first 32 threads handle K and second 32 threads handle V.

Differential Revision: D72799994
@mxz297 mxz297 force-pushed the export-D72799994 branch from f5e8768 to a26c198 Compare April 11, 2025 20:43
mxz297 added a commit to mxz297/FBGEMM that referenced this pull request Apr 11, 2025
Summary:

X-link: facebookresearch/FBGEMM#1041

This is a reland of D72062745, which was reverted as it broke NV.

In this diff, we have separate kernels for AMD and NV, so it won't have any unintended side effects to NV kernels.

For the AMD kernel, we continue to use one warp for a row. And because AMD has 64 threads per warp, we let the first 32 threads handle K and second 32 threads handle V.

Differential Revision: D72799994
@mxz297 mxz297 force-pushed the export-D72799994 branch from a26c198 to 079c45a Compare April 11, 2025 20:44
@facebook-github-bot

Copy link
Copy Markdown
Contributor

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

mxz297 added a commit to mxz297/FBGEMM that referenced this pull request Apr 11, 2025
Summary:
Pull Request resolved: pytorch#3956

X-link: facebookresearch/FBGEMM#1041

This is a reland of D72062745, which was reverted as it broke NV.

In this diff, we have separate kernels for AMD and NV, so it won't have any unintended side effects to NV kernels.

For the AMD kernel, we continue to use one warp for a row. And because AMD has 64 threads per warp, we let the first 32 threads handle K and second 32 threads handle V.

Differential Revision: D72799994
@mxz297 mxz297 force-pushed the export-D72799994 branch from 079c45a to 7c59e67 Compare April 11, 2025 20:46
Summary:
Pull Request resolved: pytorch#3956

X-link: facebookresearch/FBGEMM#1041

This is a reland of D72062745, which was reverted as it broke NV.

In this diff, we have separate kernels for AMD and NV, so it won't have any unintended side effects to NV kernels.

For the AMD kernel, we continue to use one warp for a row. And because AMD has 64 threads per warp, we let the first 32 threads handle K and second 32 threads handle V.

Differential Revision: D72799994
@facebook-github-bot

Copy link
Copy Markdown
Contributor

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

@facebook-github-bot

Copy link
Copy Markdown
Contributor

This pull request has been merged in b5c24b4.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants