[pypy-svn] r70194 - in pypy/branch/remove-ri386-multimethod/pypy/jit/backend/x86: . test

arigo at codespeak.net arigo at codespeak.net
Fri Dec 18 15:10:54 CET 2009


Author: arigo
Date: Fri Dec 18 15:10:53 2009
New Revision: 70194

Modified:
   pypy/branch/remove-ri386-multimethod/pypy/jit/backend/x86/assembler.py
   pypy/branch/remove-ri386-multimethod/pypy/jit/backend/x86/codebuf.py
   pypy/branch/remove-ri386-multimethod/pypy/jit/backend/x86/jump.py
   pypy/branch/remove-ri386-multimethod/pypy/jit/backend/x86/regalloc.py
   pypy/branch/remove-ri386-multimethod/pypy/jit/backend/x86/rx86.py
   pypy/branch/remove-ri386-multimethod/pypy/jit/backend/x86/test/test_rx86.py
   pypy/branch/remove-ri386-multimethod/pypy/jit/backend/x86/test/test_rx86_32_auto_encoding.py
   pypy/branch/remove-ri386-multimethod/pypy/jit/backend/x86/test/test_rx86_64_auto_encoding.py
Log:
Check-in old local changes (in-progress):
adding MOV_rj and MOV_jr, and starting to
tweak assembler.py (but that part is probably
a bit useless now).


Modified: pypy/branch/remove-ri386-multimethod/pypy/jit/backend/x86/assembler.py
==============================================================================
--- pypy/branch/remove-ri386-multimethod/pypy/jit/backend/x86/assembler.py	(original)
+++ pypy/branch/remove-ri386-multimethod/pypy/jit/backend/x86/assembler.py	Fri Dec 18 15:10:53 2009
@@ -7,11 +7,12 @@
 from pypy.rpython.lltypesystem.rclass import OBJECT
 from pypy.rpython.lltypesystem.lloperation import llop
 from pypy.tool.uid import fixid
-from pypy.jit.backend.x86.regalloc import RegAlloc, WORD, lower_byte,\
-     X86RegisterManager, X86XMMRegisterManager, get_ebp_ofs
+from pypy.jit.backend.x86.regalloc import RegAlloc, WORD, \
+     X86RegisterManager, X86XMMRegisterManager, is_stack, is_reg
 from pypy.rlib.objectmodel import we_are_translated, specialize
 from pypy.jit.backend.x86 import codebuf
-from pypy.jit.backend.x86.ri386 import *
+from pypy.jit.backend.x86 import rx86
+from pypy.jit.backend.x86.rx86 import eax, ecx, edx, ebx, esp, ebp, esi, edi
 from pypy.jit.metainterp.resoperation import rop
 
 
@@ -59,9 +60,8 @@
     method.func_name = name
     return method
 
-for name in dir(codebuf.MachineCodeBlock):
-    if name.upper() == name:
-        setattr(MachineCodeBlockWrapper, name, _new_method(name))
+for name in rx86.all_instructions:
+    setattr(MachineCodeBlockWrapper, name, _new_method(name))
 
 class Assembler386(object):
     mc = None
@@ -179,7 +179,7 @@
 
     def _patchable_stackadjust(self):
         # stack adjustment LEA
-        self.mc.LEA(esp, fixedsize_ebp_ofs(0))
+        self.mc.LEA32_rs(esp, 0)
         return self.mc.tell() - 4
 
     def _patch_stackadjust(self, adr_lea, stack_depth):
@@ -191,45 +191,49 @@
 
     def _assemble_bootstrap_code(self, inputargs, arglocs):
         nonfloatlocs, floatlocs = arglocs
-        self.mc.PUSH(ebp)
-        self.mc.MOV(ebp, esp)
-        self.mc.PUSH(ebx)
-        self.mc.PUSH(esi)
-        self.mc.PUSH(edi)
+        self.mc.PUSH_r(ebp)
+        self.mc.MOV_rr(ebp, esp)
+        self.mc.PUSH_r(ebx)
+        self.mc.PUSH_r(esi)
+        self.mc.PUSH_r(edi)
         # NB. exactly 4 pushes above; if this changes, fix stack_pos().
         # You must also keep _get_callshape() in sync.
         adr_stackadjust = self._patchable_stackadjust()
         tmp = X86RegisterManager.all_regs[0]
         xmmtmp = X86XMMRegisterManager.all_regs[0]
+        #
+        # 1. read from fail_boxes_ptr/int
         for i in range(len(nonfloatlocs)):
             loc = nonfloatlocs[i]
-            if loc is None:
+            if loc == -1:
                 continue
-            if isinstance(loc, REG):
-                target = loc
-            else:
-                target = tmp
             if inputargs[i].type == REF:
-                # This uses XCHG to put zeroes in fail_boxes_ptr after
-                # reading them
-                self.mc.XOR(target, target)
-                self.mc.XCHG(target, addr_add(imm(self.fail_box_ptr_addr),
-                                              imm(i*WORD)))
+                base = self.fail_box_ptr_addr
             else:
-                self.mc.MOV(target, addr_add(imm(self.fail_box_int_addr),
-                                             imm(i*WORD)))
-            self.mc.MOV(loc, target)
+                base = self.fail_box_int_addr
+            addr = base + i*WORD
+            if is_stack(loc):
+                self.mc.MOV_rj(tmp, addr)
+                self.mc.MOV_sr(loc, tmp)
+            else:
+                self.mc.MOV_rj(loc, addr)
+        #
+        # 2. put zeroes in fail_boxes_ptr to clear them for the GC
+        self.mc.XOR_rr(tmp, tmp)
+        for i in range(len(nonfloatlocs)):
+            loc = nonfloatlocs[i]
+            if loc == -1:
+                continue
+            if inputargs[i].type == REF:
+                self.mc.MOV_jr(self.fail_box_ptr_addr + i*WORD, tmp)
+        #
+        # 3. read from fail_boxes_float
         for i in range(len(floatlocs)):
             loc = floatlocs[i]
-            if loc is None:
+            if loc == -1:
                 continue
-            if isinstance(loc, REG):
-                self.mc.MOVSD(loc, addr64_add(imm(self.fail_box_float_addr),
-                                              imm(i*WORD*2)))
-            else:
-                self.mc.MOVSD(xmmtmp, addr64_add(imm(self.fail_box_float_addr),
-                                               imm(i*WORD*2)))
-                self.mc.MOVSD(loc, xmmtmp)
+            xxx
+        #
         return adr_stackadjust
 
     def dump(self, text):
@@ -920,30 +924,30 @@
         num = getattr(rop, opname.upper())
         genop_list[num] = value
 
-def new_addr_add(heap, mem, memsib):
-    def addr_add(reg_or_imm1, reg_or_imm2, offset=0, scale=0):
-        if isinstance(reg_or_imm1, IMM32):
-            if isinstance(reg_or_imm2, IMM32):
-                return heap(reg_or_imm1.value + offset +
-                            (reg_or_imm2.value << scale))
-            else:
-                return memsib(None, reg_or_imm2, scale, reg_or_imm1.value + offset)
-        else:
-            if isinstance(reg_or_imm2, IMM32):
-                return mem(reg_or_imm1, offset + (reg_or_imm2.value << scale))
-            else:
-                return memsib(reg_or_imm1, reg_or_imm2, scale, offset)
-    return addr_add
-
-addr8_add = new_addr_add(heap8, mem8, memSIB8)
-addr_add = new_addr_add(heap, mem, memSIB)
-addr64_add = new_addr_add(heap64, mem64, memSIB64)
-
-def addr_add_const(reg_or_imm1, offset):
-    if isinstance(reg_or_imm1, IMM32):
-        return heap(reg_or_imm1.value + offset)
-    else:
-        return mem(reg_or_imm1, offset)
+##def new_addr_add(heap, mem, memsib):
+##    def addr_add(reg_or_imm1, reg_or_imm2, offset=0, scale=0):
+##        if isinstance(reg_or_imm1, IMM32):
+##            if isinstance(reg_or_imm2, IMM32):
+##                return heap(reg_or_imm1.value + offset +
+##                            (reg_or_imm2.value << scale))
+##            else:
+##                return memsib(None, reg_or_imm2, scale, reg_or_imm1.value + offset)
+##        else:
+##            if isinstance(reg_or_imm2, IMM32):
+##                return mem(reg_or_imm1, offset + (reg_or_imm2.value << scale))
+##            else:
+##                return memsib(reg_or_imm1, reg_or_imm2, scale, offset)
+##    return addr_add
+
+##addr8_add = new_addr_add(heap8, mem8, memSIB8)
+##addr_add = new_addr_add(heap, mem, memSIB)
+##addr64_add = new_addr_add(heap64, mem64, memSIB64)
+
+##def addr_add_const(reg_or_imm1, offset):
+##    if isinstance(reg_or_imm1, IMM32):
+##        return heap(reg_or_imm1.value + offset)
+##    else:
+##        return mem(reg_or_imm1, offset)
 
 def round_up_to_4(size):
     if size < 4:

Modified: pypy/branch/remove-ri386-multimethod/pypy/jit/backend/x86/codebuf.py
==============================================================================
--- pypy/branch/remove-ri386-multimethod/pypy/jit/backend/x86/codebuf.py	(original)
+++ pypy/branch/remove-ri386-multimethod/pypy/jit/backend/x86/codebuf.py	Fri Dec 18 15:10:53 2009
@@ -1,11 +1,11 @@
 
 import os
 from pypy.rpython.lltypesystem import lltype, rffi
-from pypy.jit.backend.x86.ri386 import I386CodeBuilder
+from pypy.jit.backend.x86.rx86 import X86_32_CodeBuilder
 from pypy.rlib.rmmap import PTR, alloc, free
 
 
-class InMemoryCodeBuilder(I386CodeBuilder):
+class InMemoryCodeBuilder(X86_32_CodeBuilder):
     _last_dump_start = 0
 
     def __init__(self, start, end):
@@ -18,21 +18,10 @@
         self._size = map_size
         self._pos = 0
 
-    def overwrite(self, pos, data):
-        assert pos + len(data) <= self._size
-        for c in data:
-            self._data[pos] = c
-            pos += 1
-        return pos
-
-    def write(self, data):
-        self._pos = self.overwrite(self._pos, data)
-
-    def writechr(self, n):
-        # purely for performance: don't convert chr(n) to a str
+    def writechar(self, char):
         pos = self._pos
         assert pos + 1 <= self._size
-        self._data[pos] = chr(n)
+        self._data[pos] = char
         self._pos = pos + 1
 
     def get_relative_pos(self):

Modified: pypy/branch/remove-ri386-multimethod/pypy/jit/backend/x86/jump.py
==============================================================================
--- pypy/branch/remove-ri386-multimethod/pypy/jit/backend/x86/jump.py	(original)
+++ pypy/branch/remove-ri386-multimethod/pypy/jit/backend/x86/jump.py	Fri Dec 18 15:10:53 2009
@@ -1,22 +1,6 @@
 import sys
 from pypy.tool.pairtype import extendabletype
-from pypy.jit.backend.x86.ri386 import *
-
-class __extend__(OPERAND):
-    __metaclass__ = extendabletype
-    def _getregkey(self):
-        raise AssertionError("should only happen to registers and stack "
-                             "positions")
-
-class __extend__(REG):
-    __metaclass__ = extendabletype
-    def _getregkey(self):
-        return ~self.op
-
-class __extend__(MODRM):
-    __metaclass__ = extendabletype
-    def _getregkey(self):
-        return self.position
+#from pypy.jit.backend.x86.rx86 import ...
 
 
 def remap_stack_layout(assembler, src_locations, dst_locations, tmpreg):

Modified: pypy/branch/remove-ri386-multimethod/pypy/jit/backend/x86/regalloc.py
==============================================================================
--- pypy/branch/remove-ri386-multimethod/pypy/jit/backend/x86/regalloc.py	(original)
+++ pypy/branch/remove-ri386-multimethod/pypy/jit/backend/x86/regalloc.py	Fri Dec 18 15:10:53 2009
@@ -5,7 +5,9 @@
 from pypy.jit.metainterp.history import (Box, Const, ConstInt, ConstPtr,
                                          ResOperation, ConstAddr, BoxPtr,
                                          LoopToken, INT, REF, FLOAT)
-from pypy.jit.backend.x86.ri386 import *
+from pypy.jit.backend.x86.rx86 import eax, ecx, edx, ebx, esi, edi
+from pypy.jit.backend.x86.rx86 import xmm0, xmm1, xmm2, xmm3
+from pypy.jit.backend.x86.rx86 import xmm4, xmm5, xmm6, xmm7
 from pypy.rpython.lltypesystem import lltype, ll2ctypes, rffi, rstr
 from pypy.rlib.objectmodel import we_are_translated
 from pypy.rlib.unroll import unrolling_iterable
@@ -36,20 +38,6 @@
     def call_result_location(self, v):
         return eax
 
-    def convert_to_imm(self, c):
-        if isinstance(c, ConstInt):
-            return imm(c.value)
-        elif isinstance(c, ConstPtr):
-            if we_are_translated() and c.value and rgc.can_move(c.value):
-                print "convert_to_imm: ConstPtr needs special care"
-                raise AssertionError
-            return imm(rffi.cast(lltype.Signed, c.value))
-        elif isinstance(c, ConstAddr):
-            return imm(ll2ctypes.cast_adr_to_int(c.value))
-        else:
-            print "convert_to_imm: got a %s" % c
-            raise AssertionError
-
 BASE_CONSTANT_SIZE = 1000
 
 # cheat cheat cheat....
@@ -82,15 +70,15 @@
         self.constant_arrays[-1][1] = NAN
         self.constant_array_counter = 2
 
-    def convert_to_imm(self, c):
-        if self.constant_array_counter >= BASE_CONSTANT_SIZE:
-            self.constant_arrays.append(self.new_const_array())
-            self.constant_array_counter = 0
-        res = self.constant_array_counter
-        self.constant_array_counter += 1
-        arr = self.constant_arrays[-1]
-        arr[res] = c.getfloat()
-        return self.get_addr_of_const_float(-1, res)
+##    def convert_to_imm(self, c):
+##        if self.constant_array_counter >= BASE_CONSTANT_SIZE:
+##            self.constant_arrays.append(self.new_const_array())
+##            self.constant_array_counter = 0
+##        res = self.constant_array_counter
+##        self.constant_array_counter += 1
+##        arr = self.constant_arrays[-1]
+##        arr[res] = c.getfloat()
+##        return self.get_addr_of_const_float(-1, res)
 
     def get_addr_of_const_float(self, num_arr, num_pos):
         arr = self.constant_arrays[num_arr]
@@ -157,8 +145,8 @@
     def _process_inputargs(self, inputargs):
         # XXX we can sort out here by longevity if we need something
         # more optimal
-        floatlocs = [None] * len(inputargs)
-        nonfloatlocs = [None] * len(inputargs)
+        floatlocs = [-1] * len(inputargs)
+        nonfloatlocs = [-1] * len(inputargs)
         # Don't use all_regs[0] for passing arguments around a loop.
         # Must be kept in sync with consider_jump().
         # XXX this should probably go to llsupport/regalloc.py
@@ -913,3 +901,9 @@
         return dl
     else:
         raise NotImplementedError()
+
+def is_stack(loc):
+    return loc < 0
+
+def is_reg(loc):
+    return loc >= 0

Modified: pypy/branch/remove-ri386-multimethod/pypy/jit/backend/x86/rx86.py
==============================================================================
--- pypy/branch/remove-ri386-multimethod/pypy/jit/backend/x86/rx86.py	(original)
+++ pypy/branch/remove-ri386-multimethod/pypy/jit/backend/x86/rx86.py	Fri Dec 18 15:10:53 2009
@@ -1,3 +1,4 @@
+import py
 from pypy.rlib.rarithmetic import intmask, r_ulonglong
 from pypy.rlib.objectmodel import ComputedIntSymbolic, we_are_translated
 from pypy.rlib.objectmodel import specialize
@@ -14,15 +15,12 @@
 esi = 6
 edi = 7
 
+# xmm registers
+xmm0, xmm1, xmm2, xmm3, xmm4, xmm5, xmm6, xmm7 = range(8)
+
 # the following are extra registers available only on 64 bits
-r8  = 8
-r9  = 9
-r10 = 10
-r11 = 11
-r12 = 12
-r13 = 13
-r14 = 14
-r15 = 15
+r8, r9, r10, r11, r12, r13, r14, r15  = range(8, 16)
+xmm8, xmm9, xmm10, xmm11, xmm12, xmm13, xmm14, xmm15 = range(8, 16)
 
 def single_byte(value):
     return -128 <= value < 128
@@ -64,6 +62,7 @@
     return 0
 
 def register(argnum, factor=1):
+    assert factor in (1, 8)
     return encode_register, argnum, factor, rex_register
 
 # ____________________________________________________________
@@ -125,6 +124,8 @@
 def encode_mem_reg_plus_const(mc, reg1_offset, _, orbyte):
     reg1 = reg_number_3bits(mc, intmask(reg1_offset >> 32))
     offset = intmask(reg1_offset)
+    if mc.WORD == 8:
+        offset = offset & 0xFFFFFFFF
     no_offset = offset == 0
     SIB = -1
     # 64-bits special cases for reg1 == r12 or r13
@@ -189,12 +190,12 @@
         SIB = chr(encoding & 0xFF)
     offset = intmask(reg1_reg2_scaleshift_offset)
     no_offset = offset == 0
-    # 64-bits special cases for reg1 == r13
+    # 64-bits special case for reg1 == r13
     # (which look like ebp after being truncated to 3 bits)
     if mc.WORD == 8:
         if (encoding & 7) == ebp:
             no_offset = False
-    # end of 64-bits special cases
+    # end of 64-bits special case
     if no_offset:
         mc.writechar(chr(0x04 | orbyte))
         mc.writechar(SIB)
@@ -315,6 +316,7 @@
     # "MOV reg1, [reg2+offset]" and the opposite direction
     MOV_rm = insn(rex_w, '\x8B', register(1,8), mem_reg_plus_const(2))
     MOV_mr = insn(rex_w, '\x89', register(2,8), mem_reg_plus_const(1))
+    #MOV_mi = insn(rex_w, '\xC7', mem_reg_plus_const(1), immediate(2))
 
     # "MOV reg1, [reg2+reg3*scale+offset]" and the opposite direction
     MOV_ra = insn(rex_w, '\x8B', register(1,8),
@@ -322,6 +324,10 @@
     MOV_ar = insn(rex_w, '\x89', register(2,8),
                                  mem_reg_plus_scaled_reg_plus_const(1))
 
+    # "MOV reg1, [immediate2]" and the opposite direction
+    MOV_rj = insn(rex_w, '\x8B', register(1,8), '\x05', immediate(2))
+    MOV_jr = insn(rex_w, '\x89', register(2,8), '\x05', immediate(1))
+
     ADD_ri, ADD_rr, ADD_rs = common_modes(0)
     OR_ri,  OR_rr,  OR_rs  = common_modes(1)
     AND_ri, AND_rr, AND_rs = common_modes(4)
@@ -359,6 +365,12 @@
         else:
             AbstractX86CodeBuilder.MOV_ri(self, reg, immed)
 
+    # unsupported yet
+    def MOV_rj(self, reg, mem_immed):
+        py.test.skip("MOV_rj unsupported yet")
+    def MOV_jr(self, mem_immed, reg):
+        py.test.skip("MOV_jr unsupported yet")
+
 # ____________________________________________________________
 
 all_instructions = [name for name in AbstractX86CodeBuilder.__dict__

Modified: pypy/branch/remove-ri386-multimethod/pypy/jit/backend/x86/test/test_rx86.py
==============================================================================
--- pypy/branch/remove-ri386-multimethod/pypy/jit/backend/x86/test/test_rx86.py	(original)
+++ pypy/branch/remove-ri386-multimethod/pypy/jit/backend/x86/test/test_rx86.py	Fri Dec 18 15:10:53 2009
@@ -93,3 +93,10 @@
     s.MOV_ri(r12, 0x80000042)
     assert s.getvalue() == ('\x48\xC7\xC1\xFE\xFF\xFF\xFF' +
                             '\x49\xBC\x42\x00\x00\x80\x00\x00\x00\x00')
+
+def test_mov_rm_64():
+    s = CodeBuilder64()
+    s.MOV_rm(edx, reg_offset(edi, 0))
+    s.MOV_rm(edx, reg_offset(r12, 0))
+    s.MOV_rm(edx, reg_offset(r13, 0))
+    assert s.getvalue() == '\x48\x8B\x17\x49\x8b\x14\x24\x49\x8b\x55\x00'

Modified: pypy/branch/remove-ri386-multimethod/pypy/jit/backend/x86/test/test_rx86_32_auto_encoding.py
==============================================================================
--- pypy/branch/remove-ri386-multimethod/pypy/jit/backend/x86/test/test_rx86_32_auto_encoding.py	(original)
+++ pypy/branch/remove-ri386-multimethod/pypy/jit/backend/x86/test/test_rx86_32_auto_encoding.py	Fri Dec 18 15:10:53 2009
@@ -22,7 +22,7 @@
         if char != self.expected[self.index:self.index+1]:
             print self.op
             print "\x09from rx86.py:", hexdump(self.expected[self.instrindex:self.index] + char)+"..."
-            print "\x09from 'as':   ", hexdump(self.expected[self.instrindex:self.index+1])+"..."
+            print "\x09from 'as':   ", hexdump(self.expected[self.instrindex:self.index+15])+"..."
             raise Exception("Differs")
         self.index += 1
 
@@ -87,6 +87,7 @@
             'm': self.memory_tests,
             'a': self.array_tests,
             'i': self.imm32_tests,
+            'j': self.imm32_tests,
             }
 
     def assembler_operand_reg(self, regnum):
@@ -120,6 +121,9 @@
     def assembler_operand_imm(self, value):
         return '$%d' % value
 
+    def assembler_operand_imm_addr(self, value):
+        return '%d' % value
+
     def get_all_assembler_operands(self):
         return {
             'r': self.assembler_operand_reg,
@@ -127,6 +131,7 @@
             'm': self.assembler_operand_memory,
             'a': self.assembler_operand_array,
             'i': self.assembler_operand_imm,
+            'j': self.assembler_operand_imm_addr,
             }
 
     def run_test(self, methname, instrname, argmodes, args_lists):
@@ -204,37 +209,10 @@
                             'SUB_ri', 'XOR_ri'):
                 if args[0] == rx86.eax:
                     return []     # ADD EAX, constant: there is a special encoding
-    ##        if methname == "MOV_":
-    ####            if args[0] == args[1]:
-    ####                return []   # MOV reg, same reg
-    ##            if ((args[0][1] in (i386.eax, i386.al))
-    ##                and args[1][1].assembler().lstrip('-').isdigit()):
-    ##                return []   # MOV accum, [constant-address]
-    ##            if ((args[1][1] in (i386.eax, i386.al))
-    ##                and args[0][1].assembler().lstrip('-').isdigit()):
-    ##                return []   # MOV [constant-address], accum
-    ##        if instrname == "MOV16":
-    ##            return []   # skipped
-    ##        if instrname == "LEA":
-    ##            if (args[1][1].__class__ != i386.MODRM or
-    ##                args[1][1].is_register()):
-    ##                return []
-    ##        if instrname == "INT":
-    ##            if args[0][1].value == 3:
-    ##                return []
-    ##        if instrname in ('SHL', 'SHR', 'SAR'):
-    ##            if args[1][1].assembler() == '$1':
-    ##                return []
-    ##        if instrname in ('MOVZX', 'MOVSX'):
-    ##            if args[1][1].width == 4:
-    ##                return []
-    ##        if instrname == "TEST":
-    ##            if (args[0] != args[1] and
-    ##                isinstance(args[0][1], i386.REG) and
-    ##                isinstance(args[1][1], i386.REG)):
-    ##                return []   # TEST reg1, reg2  <=>  TEST reg2, reg1
-    ##        if instrname.endswith('cond'):
-    ##            return []
+            if methname == 'MOV_rj' and args[0] == rx86.eax:
+                return []   # MOV EAX, [immediate]: there is a special encoding
+            if methname == 'MOV_jr' and args[1] == rx86.eax:
+                return []   # MOV [immediate], EAX: there is a special encoding
             return [args]
 
     def get_code_checker_class(self):

Modified: pypy/branch/remove-ri386-multimethod/pypy/jit/backend/x86/test/test_rx86_64_auto_encoding.py
==============================================================================
--- pypy/branch/remove-ri386-multimethod/pypy/jit/backend/x86/test/test_rx86_64_auto_encoding.py	(original)
+++ pypy/branch/remove-ri386-multimethod/pypy/jit/backend/x86/test/test_rx86_64_auto_encoding.py	Fri Dec 18 15:10:53 2009
@@ -14,6 +14,12 @@
                    rx86.r8,  rx86.r9,  rx86.r10, rx86.r11,
                    rx86.r12, rx86.r13, rx86.r14, rx86.r15]
 
+    def array_tests(self):
+        # reduce a little bit -- we spend too long in these tests
+        lst = super(TestRx86_64, self).array_tests()
+        random.shuffle(lst)
+        return lst[:int(len(lst) * 0.2)]
+
     def imm64_tests(self):
         v = [-0x80000001, 0x80000000,
              -0x8000000000000000, 0x7FFFFFFFFFFFFFFF]



More information about the Pypy-commit mailing list