Skip to content

Modernize extension-cpp; refactor code #86

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Apr 24, 2024
Merged

Conversation

zou3519
Copy link
Contributor

@zou3519 zou3519 commented Apr 10, 2024

Stack from ghstack (oldest at bottom):

This PR:

  • creates a single unified build for extension-cpp (instead of having
    separate cpu/cuda setup.pys).
  • Updates the build system to use pyproject.toml (instead of only
    setup.py)
  • Uses TORCH_LIBRARY to bind operators (instead of using PyBind)

There will be more future work to add improvements (e.g. torch.compile
support) and also fix up the corresponding C++ extensions tutorial.

Test Plan:

  • Refactored all of the tests under test/

This PR:
- creates a single unified build for extension-cpp (instead of having
  separate cpu/cuda setup.pys).
- Updates the build system to use pyproject.toml (instead of only
  setup.py)
- Uses TORCH_LIBRARY to bind operators (instead of using PyBind)

There will be more future work to add improvements (e.g. torch.compile
support) and also fix up the corresponding C++ extensions tutorial.

Test Plan:
- Refactored all of the tests under test/

[ghstack-poisoned]
zou3519 added a commit that referenced this pull request Apr 10, 2024
This PR:
- creates a single unified build for extension-cpp (instead of having
  separate cpu/cuda setup.pys).
- Updates the build system to use pyproject.toml (instead of only
  setup.py)
- Uses TORCH_LIBRARY to bind operators (instead of using PyBind)

There will be more future work to add improvements (e.g. torch.compile
support) and also fix up the corresponding C++ extensions tutorial.

Test Plan:
- Refactored all of the tests under test/

ghstack-source-id: 9c3f83a
Pull Request resolved: #86
@zou3519 zou3519 requested review from albanD and drisspg April 10, 2024 21:15
Copy link

@drisspg drisspg left a comment

Choose a reason for hiding this comment

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

🚀

This PR:
- creates a single unified build for extension-cpp (instead of having
  separate cpu/cuda setup.pys).
- Updates the build system to use pyproject.toml (instead of only
  setup.py)
- Uses TORCH_LIBRARY to bind operators (instead of using PyBind)

There will be more future work to add improvements (e.g. torch.compile
support) and also fix up the corresponding C++ extensions tutorial.

Test Plan:
- Refactored all of the tests under test/

[ghstack-poisoned]
zou3519 added a commit that referenced this pull request Apr 10, 2024
This PR:
- creates a single unified build for extension-cpp (instead of having
  separate cpu/cuda setup.pys).
- Updates the build system to use pyproject.toml (instead of only
  setup.py)
- Uses TORCH_LIBRARY to bind operators (instead of using PyBind)

There will be more future work to add improvements (e.g. torch.compile
support) and also fix up the corresponding C++ extensions tutorial.

Test Plan:
- Refactored all of the tests under test/

ghstack-source-id: a31d059
Pull Request resolved: #86
This was referenced Apr 10, 2024
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!

@zou3519 zou3519 merged commit 3076890 into gh/zou3519/1/base Apr 24, 2024
1 check passed
zou3519 added a commit that referenced this pull request Apr 24, 2024
This PR:
- creates a single unified build for extension-cpp (instead of having
  separate cpu/cuda setup.pys).
- Updates the build system to use pyproject.toml (instead of only
  setup.py)
- Uses TORCH_LIBRARY to bind operators (instead of using PyBind)

There will be more future work to add improvements (e.g. torch.compile
support) and also fix up the corresponding C++ extensions tutorial.

Test Plan:
- Refactored all of the tests under test/

ghstack-source-id: a31d059
Pull Request resolved: #86
@zou3519 zou3519 deleted the gh/zou3519/1/head branch April 24, 2024 19:13
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.

5 participants