Re: [pypy-dev] subclassing ndarray, was Memap in numpypy

2013-07-04 Thread Mike Beller
Matti/Amaury Well -- that's excellent. The basic functionality of memmap.py seems to work fine now, against the ndarray-subtype branch. I had copied the tests from the original modules doctest into a pytest module. Had to modify because numpypy doesn't support .flags attribute, and also because

Re: [pypy-dev] subclassing ndarray, was Memap in numpypy

2013-07-04 Thread Matti Picus
True. changeset fd71a983d387 includes the start of tests for __array_finalize__ and a "few" failing tests Help is welcome :) Matti On 07/04/2013 10:30 PM, Amaury Forgeot d'Arc wrote: Hi Matti, I think you still have to implement the __array_finalize__ protocol. Otherwise methods like .transpose

Re: [pypy-dev] subclassing ndarray, was Memap in numpypy

2013-07-04 Thread Amaury Forgeot d'Arc
Hi Matti, I think you still have to implement the __array_finalize__ protocol. Otherwise methods like .transpose() won't work on a memmap object. 2013/7/4 Matti Picus > You correctly point out, in other words, that it was an ugly hack. > It is on the way to being removed by adding a space argum

Re: [pypy-dev] subclassing ndarray, was Memap in numpypy

2013-07-04 Thread Matti Picus
You correctly point out, in other words, that it was an ugly hack. It is on the way to being removed by adding a space argument to calls to from_space...(). Let us know how your tests progress. Matti On 07/04/2013 09:57 PM, Mike Beller wrote: Matti That's great. I was stuck trying to figure o

Re: [pypy-dev] subclassing ndarray, was Memap in numpypy

2013-07-04 Thread Mike Beller
Matti That's great. I was stuck trying to figure out how to deal with the fact that if subtype was not-none, the from_shape (and friends) would also need access to 'space'. I see you addressed that with subtype_and_space=(None,None).It's not a pattern I'd seen in the pypy codebase. I keep t

[pypy-dev] stmgc: about major collections

2013-07-04 Thread Armin Rigo
Hi Remi, Just a note about major collections and the handling of h_original in stmgc: as you said in an XXX we don't need to *trace* the h_original object, but only keep it alive. But also, I thought some time ago about a trick to improve the overall performance of prebuilt objects, which is to c

Re: [pypy-dev] Pypy translation fails on MIPS (without JIT)

2013-07-04 Thread Armin Rigo
Hi Alexis, On Thu, Jul 4, 2013 at 9:48 AM, Alexis BRENON wrote: > Maybe there is a deeper reason of all these failures. But I can't point out > which or where... Any idea ? The same as I already said in my previous reply. Try from the other side: write a 5-lines example C program, try to compil

Re: [pypy-dev] Pypy translation fails on MIPS (without JIT)

2013-07-04 Thread Alexis BRENON
Le 04/07/2013 08:44, Armin Rigo a écrit : Hi Alexis, On Wed, Jul 3, 2013 at 4:04 PM, Alexis BRENON wrote: Is anyone got any idea where I can search to debug this ? Check first that compiling programs works at all. Then, still with a 5-lines example .c, try to add options to gcc one at a time