Richard Plangger | 24 Feb 19:18 2015

Vectorizing numpy traces


i'm currently trying to find a way to generate simd code for python
loops that operate on numpy arrays.
The IRC is quite busy so I think I'd rather post it as an email...

I have familiarized myself with pypy and read most of the docs and read
the code in the metainterp to understand how the traces are built.

I translated pypy with --withmod-micronumpy enabled (installed numpy
pypy fork in an virtual env) and gave the jitviewer a try.
Here is a sample program that does not really make sense, but I think it
would contain opportunity to generate SIMD instructions.

import numpy
def invoke():
    a = numpy.zeros(1024)
    b = numpy.zeros(1024)
    c = numpy.zeros(1024)
    # (2)
    for i in range(0,1024):
        c[i] = a[i] + b[i]
    # (3)
    c = a + b

if __name__ == '__main__':
    i = 0
    # (1)
    while i < 500:
(Continue reading)

Matti Picus | 21 Feb 22:58 2015

fdopen(fd, 'w') whe fd is opened 'r'

Looking at this test test_fdopen_keeps_fd_open_on_errors which fails on win32

It also fails when run with python -A, on cpython. It even fails in C when running the code from the MSDN example of fdopen,
if you replace the mode flag "r" with "w", windows will happily repopen a read-only file in write mode.

The MSDN documentation is quiet on the issue of mode conflict between fd and a call to fdopen, where posix explicitly will return an error "The mode of the stream (one of the values "r", "r+", "w", "w+", "a", "a+") must be compatible with the mode of the file descriptor." I could find any google results for complaints about win32's reckless behaviour.

Two courses of action are possible:
- fix the test to reflect current cpython and pypy behaviour on win32
- file a bug with cpython and fix our win32 implementation to pass the current test

Any thoughts?
pypy-dev mailing list
pypy-dev <at>
Maciej Fijalkowski | 21 Feb 17:04 2015

freebsd 7 and 8 buildslave

there is a freebsd 8 buildslave called "ananke" which is offline, who
is the admin?

Also freebsd 7 fails to compile for an idiotic reason, should we take
this one down?
Ahmed Abdalrahman | 17 Feb 17:16 2015

contribute in the project

hello ,
my name is Ahmed ,

                              i want to join u and i am interested in open source what ever your will join google summer of code or not
i want to coding , trying to learn and help you if i can please tell me,

my experience ,
                      below average in python 
thanks for reading  
pypy-dev mailing list
pypy-dev <at>
黄若尘 | 17 Feb 09:48 2015

Pyrlang Post

pypy-dev mailing list
pypy-dev <at>
Christian Walder | 15 Feb 21:36 2015

Fwd: pypy memory test

Hi there,

I seem to be running into a problem with freeing memory.

Under OS X all is well, but under Linux there seems to be a problem in the case of linked data structures. 

I have attached a python program which demonstrates the problem. The output of the script for both linux and OS X are below.

Thanks very much in advance, and for the amazing work on PyPy.



2.7.8 (857f34cd4254, Oct 14 2014, 22:01:17)

[PyPy 2.5.0-alpha0 with GCC 4.2.1 Compatible Apple LLVM 6.0 (clang-600.0.51)]

Darwin 14.1.0 ('', '', '')


initial 20 MB


0 558 MB

0 30 MB


1 558 MB

1 31 MB


2 558 MB

2 32 MB





2.7.8 (dfffd5d7cc7e, Feb 08 2015, 14:59:48)

[PyPy 2.5.0 with GCC 4.8.2]

Linux 3.13.0-44-generic ('debian', 'jessie/sid', '')


initial 82 MB


0 626 MB

0 626 MB


1 627 MB

1 627 MB


2 627 MB

2 627 MB

Attachment ( text/x-python-script, 923 bytes
pypy-dev mailing list
pypy-dev <at>
Rohan Goel | 15 Feb 21:23 2015

GSoC 2015

Dear Developers,

I am Rohan Goel ,  Computer Science undergraduate at BITS Pilani , India and am interested in working for your organization in GSoC 2015. As I am a beginner in open source coding , it would be great help if you guide me where to start from. My primary language of interest is Python.

Thanking You,

Rohan Goel

Under Graduate, B.E. (Hons) Computer Science 
Birla Institute of Technology and Science, Pilani
K.K Birla Goa Campus
+91 7722047225 | rohangoel0296 <at>
pypy-dev mailing list
pypy-dev <at>
anatoly techtonik | 14 Feb 09:48 2015

mix-and-match approach to implementation decisions


Reading to see if I can
understand the text without a formal CS education. What does
"mix-and-match approach to implementation decisions" mean?


anatoly t.
Matti Picus | 13 Feb 14:46 2015

could it be that cpyext is faster than python + cffi?

I am close to releasing a blog post about numpy.linalg

Note the benchmark section, this is not a typo. Here's how I got to the 
conclusion that cpyext is faster than python+cffi.

I installed numpy from the pypy/numpy repo on a nightly after 2.5.0

pip install git+

I then benchmarked the two pypy methods of calling numpy.linalg.inv() 
via this script which simply calls linalg.inv() for different sized ndarray.

$pypy 10
UserWarning: npy_clear_floatstatus, npy_set_floatstatus_invalid not found
   warn('npy_clear_floatstatus, npy_set_floatstatus_invalid not found')
after   999999, for n= 10, time=20.64,     20.64 msec/1000 loops


$USE_CPYEXT=yes pypy 10
after   999999, for n= 10, time= 8.52,      8.52 msec/1000 loops

Any thoughts? Comments on the blog post?
Matti Picus | 13 Feb 12:36 2015

Re: report of some experience in Pyrlang and RPython

Here's a quick edit job, again as both PDF and docx (with revision marks).
Graphs are still missing axis labels and some kind of captioning

  On Thu, Feb 12, 2015 at 7:23 AM, 黄若尘<hrc706 <at>>  wrote:

> I like the blog post. It's full of technical details and might need
> some editing, but otherwise fine. I'm also happy to just send it as it
> is (but please add numbers and explanations on axis of graphs
> On Thu, Feb 12, 2015 at 7:23 AM, 黄若尘<hrc706 <at>>  wrote:
> Hi, Fijal,
> I have modified some contents of my post and added the section about the comparison among Pyrlang, Erlang
and HiPE.
> I think the last part of the comparison is interesting, which showed a slowing down when the scale of
benchmark become quite huge.
> The docx format seems has something wrong so I also attached the pdf one.
> Cheers,
> Huang

Attachment (Some Experiments in Pyrlang with RPython.docx): application/vnd.openxmlformats-officedocument.wordprocessingml.document, 891 KiB
pypy-dev mailing list
pypy-dev <at>
Maciej Fijalkowski | 11 Feb 10:46 2015

numpy installation


There is STILL no clear installation path for PyPy + numpy, with no
instructions anywhere, can you please do something about it?

Ideally pip install numpy-pypy should work and we should be done (this
+ info on will do)

I asked about this months ago, if noone picks it up, I'll deal with
it, but this is by far the biggest problem for PyPy+numpy users (they
can't install it).