-
Notifications
You must be signed in to change notification settings - Fork 1
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
Building with PyPy #15
Comments
Hmm. Tracing where this is defined, it seems it is here
What defines |
Maybe there should be a command line option to override it? |
There is supposed to be a command line option:
but it doesn't work:
|
I can work around this by forcing
|
The HPY_ABI_CPYTHON macro is unconditionally defined here: Line 751 in a1f0ad0
Is that on purpose? |
Also this line is tripping up the build, it should be 0.9.0 not a git ref Line 9 in a1f0ad0
|
I pushed some fixes in 23f4a18, building succeeds but import still fails on PyPy |
Something is off with the interaction of |
In order for the PyPy GC to recognize HPyFields, the call to numpy-hpy/numpy/core/src/multiarray/dtypemeta.c Lines 750 to 757 in 23f4a18
I found this by adding debug code inside I do not see a way that PyPy can chase down the HPyField hidden in the numpy-hpy/numpy/core/include/numpy/experimental_dtype_api.h Lines 161 to 171 in 23f4a18
|
does this mean that the numpy code is buggy and that it happens to work "by chance" on CPython and GraalPy, but it actually violates the contract? |
The docs say this:
Which is not the case in the example here, the memory is allocated by |
The code is "wrong", but useful, and it works on HPy + CPython and on HPy + GraalPython. |
ok, I had a deeper look at the code. I confirm that the code is "wrong", i.e. does not respect the HPy contract, at least in the way that we/I designed it. It's also possible that the current HPy API is not powerful enough to cover this case. But I need to think more about this because there is still something not 100% clear in my mind |
ok, I'm confused now.
I think that the code is correct, because HPy_VISIT correctly reports the So, the summary is: I don't know what's going on :) |
Closing. There were a lot of problems with PyPy, I think I have gotten most of them. There is a missing |
When building, I get lots of warnings about using forbidden API. I think this is because the code builds with
HPY_ABI_UNIVERSAL
. Shouldn't it useHPY_ABI_HYBRID
until the migration is complete?The text was updated successfully, but these errors were encountered: