-
Notifications
You must be signed in to change notification settings - Fork 39
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
Provide CMake-driver for building libcustom_calls #1345
base: main
Are you sure you want to change the base?
Conversation
Hello. You may have forgotten to update the changelog!
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🤔 I deleted the build directory for our dialects and then pip install -e . --extra-index...
but the directory didn't get rebuilt. Is this something that will be implemented in this PR?
Ok, looks like something funky happened --- feel free to ignore this for now until I can see why that is going on. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @mlxd, these are nice additions!
Currently getting this error for
|
Co-authored-by: David Ittah <[email protected]>
Co-authored-by: David Ittah <[email protected]>
I presume the Makefile is doing something very different then to the wheel builds? If so, we may want to unify these to a single build driver and just do that. I'll reproduce the above locally and take a look |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #1345 +/- ##
=======================================
Coverage 97.17% 97.17%
=======================================
Files 79 79
Lines 8447 8447
Branches 873 873
=======================================
Hits 8208 8208
Misses 186 186
Partials 53 53 ☔ View full report in Codecov by Sentry. |
I cannot reproduce this locally: $~ make frontend
...
Successfully installed PennyLane-Catalyst-0.10.0.dev22 appdirs-1.4.4 astunparse-1.6.3 autograd-1.7.0 autoray-0.7.0 cachetools-5.5.0 certifi-2024.8.30 charset-normalizer-3.4.0 diastatic-malt-2.15.2 gast-0.6.0 idna-3.10 jax-0.4.28 jaxlib-0.4.28 ml-dtypes-0.5.0 networkx-3.4.2 numpy-2.0.2 opt-einsum-3.4.0 packaging-24.2 pennylane-0.40.0.dev20 pennylane-lightning-0.40.0.dev30 pennylane-lightning-kokkos-0.40.0.dev30 requests-2.32.3 rustworkx-0.15.1 scipy-1.14.1 scipy-openblas32-0.3.28.0.2 six-1.17.0 termcolor-2.5.0 toml-0.10.2 typing_extensions-4.12.2 urllib3-2.2.3 wheel-0.45.1
rm -r frontend/PennyLane_Catalyst.egg-info Can you try to purge your existing venv and build cache, and create a fresh one? Since the build driver is different than before, it may be resolved by this. If not, I'm a little confused. |
I think the only difference really is that |
Yep, the editable build was the issue --- it apparently does not respect parts of the I can look into (when time permits) injecting the right types with a restructuring of the CMakeExtension to instead have an additional (non ext module) builder wrapper, or to replace setuptools+distutils with a more modern build driver |
…nto cmakeify_frontend
Context: This PR migrates the custom calls library from setup.py driven compilation to CMake. Setuptools is still used to drive the build steps for the extension module, but with full support for a cmake-only build.
This PR also introduces scaffolding to allow the entire ecosystem to later be built from a single CMake driver, with subsequent work being undertaken in https://github.com/PennyLaneAI/catalyst/tree/cmakify_ecosystem
Description of the Change: As above. This PR also restricts the MacOS wheels to only their targeted host as a platform, removing the intermediate
universal2
wheel on ARM platforms.Benefits: Ensures all compiled modules can be produced with CMake.
Possible Drawbacks:
Related GitHub Issues: