Commits

Maciej Fijalkowski  committed b48aeb3

introduce a jit driver, although it's a bit pointless right now

  • Participants
  • Parent commits 6fe5770
  • Branches numpy-indexing-by-arrays-2

Comments (0)

Files changed (1)

File pypy/module/micronumpy/interp_numarray.py

     reds=['concr', 'argi', 'ri', 'frame', 'v', 'res', 'self'],
     name='numpy_filter',
 )
+filter_set_driver = jit.JitDriver(
+    greens=['shapelen', 'sig'],
+    virtualizables=['frame'],
+    reds=['idx', 'idxi', 'frame', 'arr'],
+    name='numpy_filterset',
+)
 
 def _find_shape_and_elems(space, w_iterable):
     shape = [space.len_w(w_iterable)]
         frame = sig.create_frame(arr)
         idxi = idx.create_iter()
         while not frame.done():
+            filter_set_driver.jit_merge_point(idx=idx, idxi=idxi, sig=sig,
+                                              frame=frame, arr=arr,
+                                              shapelen=shapelen)
             if idx.dtype.getitem_bool(idx.storage, idxi.offset):
                 sig.eval(frame, arr)
                 frame.next_from_second(1)