[pypy-svn] r70443 - pypy/branch/morearraycopy/pypy/rpython/lltypesystem
arigo at codespeak.net
arigo at codespeak.net
Thu Jan 7 21:18:17 CET 2010
Author: arigo
Date: Thu Jan 7 21:18:17 2010
New Revision: 70443
Modified:
pypy/branch/morearraycopy/pypy/rpython/lltypesystem/rlist.py
Log:
Use rgc.ll_arraycopy in the only loop in rpython/lltypesystem/rlist.py.
Modified: pypy/branch/morearraycopy/pypy/rpython/lltypesystem/rlist.py
==============================================================================
--- pypy/branch/morearraycopy/pypy/rpython/lltypesystem/rlist.py (original)
+++ pypy/branch/morearraycopy/pypy/rpython/lltypesystem/rlist.py Thu Jan 7 21:18:17 2010
@@ -376,8 +376,7 @@
else:
LIST = typeOf(l).TO
newitems = malloc(LIST.items.TO, n)
- for i in range(n):
- newitems[i] = olditems[i]
+ rgc.ll_arraycopy(olditems, newitems, 0, 0, n)
return newitems
ll_list2fixed.oopspec = 'list.list2fixed(l)'
More information about the Pypy-commit
mailing list