Skip to content

Conversation

@SS-JIA
Copy link
Contributor

@SS-JIA SS-JIA commented Apr 9, 2025

Stack from ghstack (oldest at bottom):

Context

Some Vulkan devices do not have support for 8-bit buffers, which is currently required to execute the int4 linear compute shader due to the prepacking shader requiring it.

This diff bypasses that restriction by introducing a variant of the prepacking shader that does not need 8-bit buffers.

Changes

Introduce a variant of the int4 weight prepacking shader that interprets the tensor data as an array of uint instead of uint8_t. Each uint represents 4 uint8_t values.

Differential Revision: D72750897

## Context

Some Vulkan devices do not have support for 8-bit buffers, which is currently required to execute the int4 linear compute shader due to the prepacking shader requiring it.

This diff bypasses that restriction by introducing a variant of the prepacking shader that does not need 8-bit buffers.

## Changes

Introduce a variant of the int4 weight prepacking shader that interprets the tensor data as an array of `uint` instead of `uint8_t`. Each `uint` represents 4 `uint8_t` values.

Differential Revision: [D72750897](https://our.internmc.facebook.com/intern/diff/D72750897/)

[ghstack-poisoned]
@pytorch-bot
Copy link

pytorch-bot bot commented Apr 9, 2025

🔗 Helpful Links

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

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

✅ No Failures

As of commit 92f11a3 with merge base 6d1caca (image):
💚 Looks good so far! There are no failures yet. 💚

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

SS-JIA added a commit that referenced this pull request Apr 9, 2025
## Context

Some Vulkan devices do not have support for 8-bit buffers, which is currently required to execute the int4 linear compute shader due to the prepacking shader requiring it.

This diff bypasses that restriction by introducing a variant of the prepacking shader that does not need 8-bit buffers.

## Changes

Introduce a variant of the int4 weight prepacking shader that interprets the tensor data as an array of `uint` instead of `uint8_t`. Each `uint` represents 4 `uint8_t` values.

Differential Revision: [D72750897](https://our.internmc.facebook.com/intern/diff/D72750897/)

ghstack-source-id: 277173967
Pull Request resolved: #10030
@facebook-github-bot facebook-github-bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Apr 9, 2025
@facebook-github-bot
Copy link
Contributor

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

…upport"

## Context

Some Vulkan devices do not have support for 8-bit buffers, which is currently required to execute the int4 linear compute shader due to the prepacking shader requiring it.

This diff bypasses that restriction by introducing a variant of the prepacking shader that does not need 8-bit buffers.

## Changes

Introduce a variant of the int4 weight prepacking shader that interprets the tensor data as an array of `uint` instead of `uint8_t`. Each `uint` represents 4 `uint8_t` values.

Differential Revision: [D72750897](https://our.internmc.facebook.com/intern/diff/D72750897/)

[ghstack-poisoned]
SS-JIA added a commit that referenced this pull request Apr 9, 2025
Pull Request resolved: #10030

## Context

Some Vulkan devices do not have support for 8-bit buffers, which is currently required to execute the int4 linear compute shader due to the prepacking shader requiring it.

This diff bypasses that restriction by introducing a variant of the prepacking shader that does not need 8-bit buffers.

## Changes

Introduce a variant of the int4 weight prepacking shader that interprets the tensor data as an array of `uint` instead of `uint8_t`. Each `uint` represents 4 `uint8_t` values.

Differential Revision: [D72750897](https://our.internmc.facebook.com/intern/diff/D72750897/)
ghstack-source-id: 277175676
@facebook-github-bot
Copy link
Contributor

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

…upport"

## Context

Some Vulkan devices do not have support for 8-bit buffers, which is currently required to execute the int4 linear compute shader due to the prepacking shader requiring it.

This diff bypasses that restriction by introducing a variant of the prepacking shader that does not need 8-bit buffers.

## Changes

Introduce a variant of the int4 weight prepacking shader that interprets the tensor data as an array of `uint` instead of `uint8_t`. Each `uint` represents 4 `uint8_t` values.

Differential Revision: [D72750897](https://our.internmc.facebook.com/intern/diff/D72750897/)

[ghstack-poisoned]
@facebook-github-bot
Copy link
Contributor

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

@facebook-github-bot facebook-github-bot merged commit 3aa73e9 into gh/SS-JIA/210/base Apr 16, 2025
84 of 85 checks passed
@facebook-github-bot facebook-github-bot deleted the gh/SS-JIA/210/head branch April 16, 2025 17:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. fb-exported topic: not user facing

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants