[pypy-svn] pypy numpy-exp: Start adding sse_float_add ops
fijal
commits-noreply at bitbucket.org
Sun Feb 13 16:16:05 CET 2011
Author: Maciej Fijalkowski <fijall at gmail.com>
Branch: numpy-exp
Changeset: r41880:084ea2d068ea
Date: 2011-02-12 15:06 +0200
http://bitbucket.org/pypy/pypy/changeset/084ea2d068ea/
Log: Start adding sse_float_add ops
diff --git a/pypy/rpython/lltypesystem/lloperation.py b/pypy/rpython/lltypesystem/lloperation.py
--- a/pypy/rpython/lltypesystem/lloperation.py
+++ b/pypy/rpython/lltypesystem/lloperation.py
@@ -441,6 +441,10 @@
'get_write_barrier_from_array_failing_case': LLOp(sideeffects=False),
'gc_get_type_info_group': LLOp(sideeffects=False),
+ # __________ vectorization ops _______
+
+ 'sse_float_add': LLOp(sideeffects=False, canrun=True),
+
# __________ GC operations __________
'gc__collect': LLOp(canunwindgc=True),
diff --git a/pypy/rpython/lltypesystem/opimpl.py b/pypy/rpython/lltypesystem/opimpl.py
--- a/pypy/rpython/lltypesystem/opimpl.py
+++ b/pypy/rpython/lltypesystem/opimpl.py
@@ -570,6 +570,10 @@
def op_shrink_array(array, smallersize):
return False
+def op_sse_float_add(arr1, arr2, arr_res, index):
+ arr_res[index] = arr1[index] + arr2[index]
+ arr_res[index + 1] = arr1[index + 1] + arr2[index + 1]
+
# ____________________________________________________________
def get_op_impl(opname):
More information about the Pypy-commit
mailing list