Ryan Gonzalez | 30 May 03:32 2015
Picon

An overview of the RPython language

I wrote a quick overview of the RPython language at http://kirbyfan64.github.io/posts/the-magic-of-rpython.html. Any suggestions for improvement would be appreciated. :)

IMO, this is needed. Most RPython articles are insanely old (from 200x) or just cover the JIT (Andrew Brown's excellent tutorial).

--
Ryan
[ERROR]: Your autotools build scripts are 200 lines longer than your program. Something’s wrong.
_______________________________________________
pypy-dev mailing list
pypy-dev <at> python.org
https://mail.python.org/mailman/listinfo/pypy-dev
Yicong Huang | 28 May 12:31 2015
Picon

How to make a builtin pypy module visible?

Hi,

I tried to write a simple test module in pypy:
1. Make a new directory in pypy/modules, and put the code there.
2. Add the new module name in pypyoption.py and built the new libpypy-c.so

The reason that I put the module in pypy/modules is I tried to make the module build into libpypy-c.so. :)

After that, in pypy console, I am able to import the module and run module's function. 
However, when I tried to import the module in python script, I met the errors:

pypy test.py

Traceback (most recent call last):
  File "<builtin>/app_main.py", line 75, in run_toplevel
  File "test.py", line 1, in <module>
    import pypytest
ImportError: No module named pypytest

Any steps I missed to make the buitin module visible?


_______________________________________________
pypy-dev mailing list
pypy-dev <at> python.org
https://mail.python.org/mailman/listinfo/pypy-dev
Matti Picus | 26 May 22:19 2015
Picon

PyPy 2.6.0 release binaries available

The release packages are available on bitbucket

https://bitbucket.org/pypy/pypy/downloads

Please try them out, we have new buildslaves for win32, macosx and linux64.
We would especially appreciate testing out the vmprof profiling features 
available on linux-64
Comments on the release notice are also welcome, extra points for a name 
incorporating "profiling" in it.

http://pypy.readthedocs.org/en/release-2.6.x/release-2.6.0.html

Matti
Ryan Gonzalez | 26 May 20:30 2015
Picon

What is the oldest version of CPython that can be used to build PyPy?

^ see subject

--
Ryan
[ERROR]: Your autotools build scripts are 200 lines longer than your program. Something’s wrong.
_______________________________________________
pypy-dev mailing list
pypy-dev <at> python.org
https://mail.python.org/mailman/listinfo/pypy-dev
Yicong Huang | 26 May 11:45 2015
Picon

Is there similar PyEval_EvalFrameEx() function in PyPy?

We would like to monitor and log all external function calls from a class: when there the function call happen, we capture and log the frame.

In python, there is the function PyEval_EvalFrameEx() we might add a callback inside.
Is there a similar function in PyPy that would be called when the function call happens?



_______________________________________________
pypy-dev mailing list
pypy-dev <at> python.org
https://mail.python.org/mailman/listinfo/pypy-dev
Matti Picus | 22 May 15:18 2015
Picon

PyPy OSX buildbot needed

this is an explicit call for help. We do not seem to be able to keep a 
nightly OSX buildbot functioning, even one that builds once a week or so 
and can be made available for major merges/releases would be better than 
none.

If you have a lead to a modern OSX machine that can donate cycles to 
PyPy, please respond or join on IRC at #pypy

Thanks
Yicong Huang | 22 May 05:55 2015
Picon

ImportError, No module named pycparser

Hi,

I built pypy with some modules cut off, but met the errors as below for executing python scripts:

debug: OperationError:
debug:  operror-type: ImportError
debug:  operror-value: No module named pycparser

Which modules do pycparser depends on?
I found the module might in /lib_pypy/cffi/_pycparser. But I did not exclude cffi module, and it did not have any problems of importing cffi.

The modules I cut of are:
ssl
bz2
crypt
_csv
_minimal_curse
fcntl
_io
mmap
parser
pyexpat
select
_socket
_ssl
zlib
pwd

And the list of used modules for the build:
[usemodules]
    __pypy__ = True
    _ast = True
    _cffi_backend = True
    _codecs = True
    _collections = True
    _continuation = True
    _hashlib = True
    _locale = True
    _lsprof = True
    _md5 = True
    _minimal_curses = True
    _multibytecodec = True
    _multiprocessing = True
    _pickle_support = True
    _pypyjson = True
    _random = True
    _rawffi = True
    _sha = True
    _sre = True
    _testing = True
    _weakref = True
    array = True
    binascii = True
    cStringIO = True
    cmath = True
    cppyy = True
    cpyext = True
    errno = True
    gc = True
    imp = True
    marshal = True
    math = True
    micronumpy = True
    operator = True
    signal = True
    struct = True
    symbol = True
    termios = True
    thread = True
    time = True
    token = True
    unicodedata = True
    zipimport = True
_______________________________________________
pypy-dev mailing list
pypy-dev <at> python.org
https://mail.python.org/mailman/listinfo/pypy-dev
Antti Mäkinen | 21 May 10:40 2015
Picon

datetime.date support in NumPyPy

Is there any estimate on when NumPyPy will support datetime.date objects in arrays?

Regards,
Antti Mäkinen



_______________________________________________
pypy-dev mailing list
pypy-dev <at> python.org
https://mail.python.org/mailman/listinfo/pypy-dev
Yicong Huang | 21 May 05:12 2015
Picon

Could PyPy callback C code with C function pointer?

With PyPy "pypy_execute_source_ptr()", we could pass a C function pointer to python code.
The funtion pointer was initilized in C code.
Could PyPy use this function pointer callback to C code?
_______________________________________________
pypy-dev mailing list
pypy-dev <at> python.org
https://mail.python.org/mailman/listinfo/pypy-dev
Yicong Huang | 20 May 11:44 2015
Picon

Cannot instantiate ctype 'struct *' of unknown size

Hi,

The below is the code we met troubles;

ffi.cdef('''
  struct API {
     struct api_ret* (*pyudf)(char* str);
  };
''')

ffi.cdef('''
  struct api_ret {
     char *ret1;
     char *ret2;
     char *ret3;
  };
''')

result = ffi.new('struct api_ret*')

At first, we defined struct API with a function pointer that return a pointer to struct api_ret.
And then we defined api_ret, and tried to new the object.
The problem seems to happen when the function pointer and new structure are together.
The below code had no problems.

ffi.cdef('''
  struct API {
     struct api_ret* (*pyudf)(char* str);
  };
''')

ffi.cdef('''
  struct api_ret2 {
     char *ret1;
     char *ret2;
     char *ret3;
  };
''')
#we used different name api_ret2 to work around the issue.
result = ffi.new('struct api_ret2*')
_______________________________________________
pypy-dev mailing list
pypy-dev <at> python.org
https://mail.python.org/mailman/listinfo/pypy-dev
Yicong Huang | 19 May 17:06 2015
Picon

For embedding pypy, how to deal with None value

The document Embedding PyPy shows good examples, but did not tell how to deal with None value.
As Python support None value, it might bring some troubles:
1. How to pass NULL from C to python for None?
2. If python function return None, how to handle the issue in C?

For the above cases, we observed errors like these:

From cffi callback <function add_numbersInt at 0x00007f25f313e110>:
Trying to convert the result back to C:
TypeError: expected integer, got NoneType object


_______________________________________________
pypy-dev mailing list
pypy-dev <at> python.org
https://mail.python.org/mailman/listinfo/pypy-dev

Gmane