[pypy-dev] ctypes create_string_buffer

HY lightdarkadmin at 163.com
Mon Jan 13 02:50:42 CET 2014


thanks you reply my message. 
I think the string is pure struct, mybe should special process; 
want a little of change as soon as possible enablement.
At 2014-01-13 04:53:56,"Armin Rigo" <arigo at tunes.org> wrote:
>Hi,
>
>On Sun, Jan 12, 2014 at 6:28 AM, HY <lightdarkadmin at 163.com> wrote:
>> I test 2f0d7dced731
>> memory isn't large engross. but at the AMD 5000+ CPU, 5 secs CPU 100%.
>> I think this has a BUG. :)
>
>Yes :-)  You can see why it's slow by following the logic in pure
>Python in lib_pypy/_ctypes/, maybe by using just pdb.  It's because
>every character is individually converted to a ctypes object and back
>before being stored into the string buffer.  I guess we could add a
>special case to massively speed up the common "array-of-char.value =
>string".
>
>
>A bientôt,
>
>Armin.


More information about the pypy-dev mailing list