Skip to content

Conversation

zou3519
Copy link
Contributor

@zou3519 zou3519 commented May 22, 2024

Summary:
co-dev reland of pytorch/pytorch#124520, which requires
the removal of some executorch tests.

Before this PR, we didn't check that types in a schema were valid. This
is because TorchScript treats unknown types as type variables.

This PR checks types in a schema for the TORCH_LIBRARY APIs. To do this,
we add an allow_typevars flag to parseSchema so that TorchScript can
use allow_typevars=True. We also add some error messages for common
mistakes (e.g. using int64_t or double in schema).

Differential Revision: D57666659

Copy link

pytorch-bot bot commented May 22, 2024

🔗 Helpful Links

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

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

❗ 1 Active SEVs

There are 1 currently active SEVs. If your PR is affected, please view them below:

✅ No Failures

As of commit 31d0c18 with merge base 16a892d (image):
💚 Looks good so far! There are no failures yet. 💚

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

@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 May 22, 2024
@facebook-github-bot
Copy link
Contributor

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

zou3519 added a commit to zou3519/pytorch that referenced this pull request May 22, 2024
Summary:

X-link: pytorch/executorch#3705

co-dev reland of pytorch#124520, which requires
the removal of some executorch tests.

Before this PR, we didn't check that types in a schema were valid. This
is because TorchScript treats unknown types as type variables.

This PR checks types in a schema for the TORCH_LIBRARY APIs. To do this,
we add an `allow_typevars` flag to parseSchema so that TorchScript can
use allow_typevars=True. We also add some error messages for common
mistakes (e.g. using int64_t or double in schema).

Test Plan: Wait for tests

Differential Revision: D57666659
zou3519 added a commit to zou3519/executorch that referenced this pull request May 22, 2024
Summary:
X-link: pytorch/pytorch#126861


co-dev reland of pytorch/pytorch#124520, which requires
the removal of some executorch tests.

Before this PR, we didn't check that types in a schema were valid. This
is because TorchScript treats unknown types as type variables.

This PR checks types in a schema for the TORCH_LIBRARY APIs. To do this,
we add an `allow_typevars` flag to parseSchema so that TorchScript can
use allow_typevars=True. We also add some error messages for common
mistakes (e.g. using int64_t or double in schema).

Differential Revision: D57666659
@zou3519 zou3519 force-pushed the export-D57666659 branch from 6692766 to cc26b8f Compare May 22, 2024 10:22
@facebook-github-bot
Copy link
Contributor

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

Copy link

@albanD albanD left a comment

Choose a reason for hiding this comment

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

Sounds good as a reland

Summary:
X-link: pytorch/pytorch#126861


co-dev reland of pytorch/pytorch#124520, which requires
the removal of some executorch tests.

Before this PR, we didn't check that types in a schema were valid. This
is because TorchScript treats unknown types as type variables.

This PR checks types in a schema for the TORCH_LIBRARY APIs. To do this,
we add an `allow_typevars` flag to parseSchema so that TorchScript can
use allow_typevars=True. We also add some error messages for common
mistakes (e.g. using int64_t or double in schema).

Reviewed By: albanD

Differential Revision: D57666659
@zou3519 zou3519 force-pushed the export-D57666659 branch from cc26b8f to 31d0c18 Compare May 22, 2024 17:59
zou3519 added a commit to zou3519/pytorch that referenced this pull request May 22, 2024
Summary:

X-link: pytorch/executorch#3705

co-dev reland of pytorch#124520, which requires
the removal of some executorch tests.

Before this PR, we didn't check that types in a schema were valid. This
is because TorchScript treats unknown types as type variables.

This PR checks types in a schema for the TORCH_LIBRARY APIs. To do this,
we add an `allow_typevars` flag to parseSchema so that TorchScript can
use allow_typevars=True. We also add some error messages for common
mistakes (e.g. using int64_t or double in schema).

Test Plan: Wait for tests

Reviewed By: albanD

Differential Revision: D57666659
@facebook-github-bot
Copy link
Contributor

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

@facebook-github-bot
Copy link
Contributor

This pull request has been merged in 1dd4935.

kirklandsign pushed a commit to kirklandsign/executorch that referenced this pull request May 24, 2024
Summary:
X-link: pytorch/pytorch#126861

Pull Request resolved: pytorch#3705

co-dev reland of pytorch/pytorch#124520, which requires
the removal of some executorch tests.

Before this PR, we didn't check that types in a schema were valid. This
is because TorchScript treats unknown types as type variables.

This PR checks types in a schema for the TORCH_LIBRARY APIs. To do this,
we add an `allow_typevars` flag to parseSchema so that TorchScript can
use allow_typevars=True. We also add some error messages for common
mistakes (e.g. using int64_t or double in schema).

Reviewed By: albanD

Differential Revision: D57666659

fbshipit-source-id: 25b0c247229ea78966725a3678dd01fdcc02c91d
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 Merged
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants