Skip to content

[ET Device Support] Add NonConstBufferDevice schema for per-buffer device mapping#18330

Open
Gasoonjia wants to merge 2 commits intogh/gasoonjia/144/basefrom
gh/gasoonjia/144/head
Open

[ET Device Support] Add NonConstBufferDevice schema for per-buffer device mapping#18330
Gasoonjia wants to merge 2 commits intogh/gasoonjia/144/basefrom
gh/gasoonjia/144/head

Conversation

@Gasoonjia
Copy link
Contributor

@Gasoonjia Gasoonjia commented Mar 19, 2026

…vice mapping

Adds the NonConstBufferDevice table to the FlatBuffer schema (program.fbs) and the
corresponding Python dataclass to schema.py. This enables mapping each non-constant
planned memory buffer to a specific device type (CPU, CUDA, etc.).

The field is optional and absent for CPU-only programs, ensuring zero binary size regression.

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

[ghstack-poisoned]
@pytorch-bot
Copy link

pytorch-bot bot commented Mar 19, 2026

🔗 Helpful Links

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

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

❌ 1 New Failure, 3 Pending, 1 Unrelated Failure

As of commit c2cb7ac with merge base bf2243a (image):

NEW FAILURE - The following job has failed:

FLAKY - The following job failed but was likely due to flakiness present on trunk:

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

@meta-cla meta-cla 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 Mar 19, 2026
Gasoonjia added a commit that referenced this pull request Mar 19, 2026
…vice mapping

Adds the NonConstBufferDevice table to the FlatBuffer schema (program.fbs) and the
corresponding Python dataclass to schema.py. This enables mapping each non-constant
planned memory buffer to a specific device type (CPU, CUDA, etc.).

The field is optional and absent for CPU-only programs, ensuring zero binary size regression.

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

ghstack-source-id: 354722549
Pull Request resolved: #18330
@github-actions
Copy link

This PR needs a release notes: label

If your change should be included in the release notes (i.e. would users of this library care about this change?), please use a label starting with release notes:. This helps us keep track and include your important work in the next release notes.

To add a label, you can comment to pytorchbot, for example
@pytorchbot label "release notes: none"

For more information, see
https://github.com/pytorch/pytorch/wiki/PyTorch-AutoLabel-Bot#why-categorize-for-release-notes-and-how-does-it-work.

…r-buffer device mapping"

Adds the NonConstBufferDevice table to the FlatBuffer schema (program.fbs) and the
corresponding Python dataclass to schema.py. This enables mapping each non-constant
planned memory buffer to a specific device type (CPU, CUDA, etc.).

The field is optional and absent for CPU-only programs, ensuring zero binary size regression.

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

[ghstack-poisoned]
Gasoonjia added a commit that referenced this pull request Mar 19, 2026
…vice mapping

Pull Request resolved: #18330

Adds the NonConstBufferDevice table to the FlatBuffer schema (program.fbs) and the
corresponding Python dataclass to schema.py. This enables mapping each non-constant
planned memory buffer to a specific device type (CPU, CUDA, etc.).

The field is optional and absent for CPU-only programs, ensuring zero binary size regression.

Differential Revision: [D97335597](https://our.internmc.facebook.com/intern/diff/D97335597/)
ghstack-source-id: 354740824
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 meta-exported

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant