conda-forge / numba-feedstock

A conda-smithy repository for numba.
BSD 3-Clause "New" or "Revised" License
0 stars 27 forks source link

Rebuild for PyPy3.8 and PyPy3.9 #120

Closed regro-cf-autotick-bot closed 1 month ago

regro-cf-autotick-bot commented 1 year ago

This PR has been triggered in an effort to update pypy38.

Notes and instructions for merging this PR:

  1. Please merge the PR only after the tests have passed.
  2. Feel free to push to the bot's branch to update this PR if needed.

Please note that if you close this PR we presume that the feedstock has been rebuilt, so if you are going to perform the rebuild yourself don't close this PR until the your rebuild has been merged.

If this PR was opened in error or needs to be updated please add the bot-rerun label to this PR. The bot will close this PR and schedule another one. If you do not have permissions to add this label, you can use the phrase code>@<space/conda-forge-admin, please rerun bot in a PR comment to have the conda-forge-admin add it for you.

This PR was created by the regro-cf-autotick-bot. The regro-cf-autotick-bot is a service to automatically track the dependency graph, migrate packages, and propose package version updates for conda-forge. Feel free to drop us a line if there are any issues! This PR was generated by https://github.com/regro/cf-scripts/actions/runs/5022272672, please use this URL for debugging.

conda-forge-webservices[bot] commented 1 year ago

Hi! This is the friendly automated conda-forge-linting service.

I just wanted to let you know that I linted all conda-recipes in your PR (recipe) and found it was in an excellent condition.

jakirkham commented 1 year ago

@conda-forge-admin, please re-render

jakirkham commented 1 year ago

@conda-forge-admin, please re-render

jakirkham commented 1 year ago

Marking as draft as it looks like there are build issues with PyPy. In particular this C_TRACE macro is relying on member access to the opaque PyThreadState struct. It appears PyPy's PyThreadState implementation doesn't include these attributes

cc @mattip

mattip commented 1 year ago

That code depends on specific CPython internals, that do not exist on PyPy. Taking a high level view, is there a design description of what the code is trying to do? Maybe we could suggest an alternative.

jakirkham commented 1 year ago

There's a comment at the top of the file that says the following:

Notes on the C_TRACE macro:

The original C_TRACE macro (from ceval.c) would call PyTrace_C_CALL et al., for which the frame argument wouldn't be usable. Since we explicitly synthesize a frame using the original Python code object, we call PyTrace_CALL instead so the profiler can report the correct source location.

Likewise, while ceval.c would call PyTrace_C_EXCEPTION in case of error, the profiler would simply expect a RETURN in case of a Python function, so we generate that here (making sure the exception state is preserved correctly).

Does that provide more insight?

jakirkham commented 1 month ago

PyPy has been dropped in conda-forge: https://github.com/conda-forge/conda-forge-pinning-feedstock/pull/6345

Closing as won't fix

That said, am deeply appreciative of your help here Matti! Diving down some of these rabbit holes was not easy and took a lot of detective work 🙏