<ronan> the random idea is just a concept. I don't really know what the concrete consequences can be. I guess we'd need to implement HPyField in pypy or GraalPython to see if it makes any sense
<antocuni> _hf2py on pypy means that you need to create an HPy, which means you might have to resize HandleManager.handles_w, which might trigger a reallocation
<antocuni> I don't know if that's possible from within a custom GC tracer but I doubt it
<Hodgestar> Could tp_traverse for HPy walk HPyField's directly? I.e. not care about handles at all?
<Hodgestar> Then one wouldn't have to load anything?
<Hodgestar> (I have not been following the conversation that closely).
computerfarmer has joined #hpy
computerfarmer has quit [Remote host closed the connection]
computerfarmer has joined #hpy
computerfarmer has quit [Read error: Connection reset by peer]
computerfarmer has joined #hpy
computerfarmer has quit [Read error: Connection reset by peer]
computerfarmer has joined #hpy
computerfarmer has quit [Read error: Connection reset by peer]
computerfarmer has joined #hpy
computerfarmer has quit [Client Quit]
<antocuni> Hodgestar: ronan's problem is that to know where the HPyFields are inside a numpy array, he needs to manipulate app-level objects
<antocuni> because those info are stored inside the dtype
<Hodgestar> Ah, so not on the object being traversed?
<Hodgestar> But on an object referenced by the object being traversed.
<antocuni> yes
<Hodgestar> Ah. Bleh.
<antocuni> I think it's about "structured arrays": https://numpy.org/doc/stable/user/basics.rec.html
<antocuni> i.e. arrays whose items are C-like structs. The problem is to know which of the struct fields contain PyObject/HPyField
<antocuni> if I understood correctly
<mattip> We could limit the hpy numpy support to the array API standard
<mattip> which does not allow object and structured dtypes
<mattip> at least as a first step
<mattip> people who want structured arrays or object arrays can use the c-api
ammar2 has quit [Ping timeout: 250 seconds]
ammar2 has joined #hpy