Author: Alex Gaynor <alex.gay...@gmail.com>
Branch: 
Changeset: r62567:dfeafbb406c6
Date: 2013-03-20 13:19 -0700
http://bitbucket.org/pypy/pypy/changeset/dfeafbb406c6/

Log:    Remove unused callbench directory

diff --git a/pypy/interpreter/callbench/bltn04.py 
b/pypy/interpreter/callbench/bltn04.py
deleted file mode 100644
--- a/pypy/interpreter/callbench/bltn04.py
+++ /dev/null
@@ -1,40 +0,0 @@
-from sup import run
-
-def w(N, start):
-    c = chr
-
-    start()
-    i = 0
-    while i < N:
-        c(65)
-        c(65)
-        c(65)
-        c(65)
-        c(65)
-        c(65)
-        c(65)        
-        c(65)
-        c(65)
-        c(65)
-        c(65)
-        c(65)
-        c(65)
-        c(65)
-        c(65)
-        c(65)
-        c(65)
-        c(65)
-        c(65)        
-        c(65)
-        c(65)
-        c(65)
-        c(65)
-        c(65)
-        c(65)
-        c(65)
-        c(65)
-        c(65)
-        c(65)        
-        i+=1
-
-run(w, 1000)
diff --git a/pypy/interpreter/callbench/bltn_instantiate.py 
b/pypy/interpreter/callbench/bltn_instantiate.py
deleted file mode 100644
--- a/pypy/interpreter/callbench/bltn_instantiate.py
+++ /dev/null
@@ -1,22 +0,0 @@
-from sup import run
-
-def w(N, start):
-    o = object
-    start()
-    i = 0
-    while i < N:
-        o()
-        o()
-        o()
-        o()
-        o()
-        o()
-        o()
-        o()
-        o()
-        o()
-        o()
-        o()        
-        i+=1
-    
-run(w, 1000)
diff --git a/pypy/interpreter/callbench/bltna1.py 
b/pypy/interpreter/callbench/bltna1.py
deleted file mode 100644
--- a/pypy/interpreter/callbench/bltna1.py
+++ /dev/null
@@ -1,28 +0,0 @@
-from sup import run
-
-def w(N, start):
-    l = []
-    start()
-    i = 0
-    while i < N:
-        l.__init__()
-        l.__init__()
-        l.__init__()
-        l.__init__()
-        l.__init__()
-        l.__init__()
-        l.__init__()
-        l.__init__()
-        l.__init__()
-        l.__init__()
-        l.__init__()
-        l.__init__()
-        l.__init__()
-        l.__init__()
-        l.__init__()
-        l.__init__()
-        l.__init__()
-        l.__init__()
-        i+=1
-    
-run(w, 1000)
diff --git a/pypy/interpreter/callbench/bltna2.py 
b/pypy/interpreter/callbench/bltna2.py
deleted file mode 100644
--- a/pypy/interpreter/callbench/bltna2.py
+++ /dev/null
@@ -1,29 +0,0 @@
-from sup import run
-
-def w(N, start):
-    l = []
-    start()
-    i = 0
-    z = l.__init__
-    while i < N:
-        z()
-        z()
-        z()
-        z()
-        z()
-        z()
-        z()
-        z()
-        z()
-        z()
-        z()
-        z()
-        z()
-        z()
-        z()
-        z()
-        z()
-        z()
-        i+=1
-    
-run(w, 1000)
diff --git a/pypy/interpreter/callbench/bm14.py 
b/pypy/interpreter/callbench/bm14.py
deleted file mode 100644
--- a/pypy/interpreter/callbench/bm14.py
+++ /dev/null
@@ -1,51 +0,0 @@
-from sup import run
-
-def w(N, start):
-    class A(object):
-        def f0(self):
-            pass
-        def f1(self, a):
-            pass
-        def f2(self, a, b):
-            pass
-        def f3(self, a, b, c):
-            pass
-        def f4(self, a, b, c, d):
-            pass
-
-    a = A()
-    f0 = a.f0
-    f1 = a.f1
-    f2 = a.f2
-    f3 = a.f3
-    f4 = a.f4
-
-    start()
-    i = 0
-    while i < N:
-        f0()
-        f0()
-        f0()
-        f0()
-        f1(1)
-        f1(1)
-        f1(1)
-        f1(1)
-        f2(1, 2)
-        f2(1, 2)
-        f2(1, 2)
-        f3(1, 2, 3)
-        f3(1, 2, 3)
-        f4(1, 2, 3, 4)
-
-        f0()
-        f0()
-        f0()
-        f1(1)
-        f1(1)
-        f1(1)
-        f2(1, 2)
-        
-        i+=1
-
-run(w, 1000)
diff --git a/pypy/interpreter/callbench/bmabvararg.py 
b/pypy/interpreter/callbench/bmabvararg.py
deleted file mode 100644
--- a/pypy/interpreter/callbench/bmabvararg.py
+++ /dev/null
@@ -1,29 +0,0 @@
-from sup import run
-
-def w(N, start):
-    class A(object):
-        def f(self, a, b, *args):
-            pass
-
-    a = A()
-    f = a.f
-    z = (3, 4, 5)
-
-    start()
-    i = 0
-    while i < N:
-        f(1, 2, *z)
-        f(1, 2, *z)
-        f(1, 2, *z)
-        f(1, 2, *z)
-        f(1, 2, *z)
-        f(1, 2, *z)
-        f(1, 2, *z)
-        f(1, 2, *z)
-        f(1, 2, *z)
-        f(1, 2, *z)
-        f(1, 2, *z)
-        f(1, 2, *z)
-        i+=1
-
-run(w, 1000)
diff --git a/pypy/interpreter/callbench/bmfilter.py 
b/pypy/interpreter/callbench/bmfilter.py
deleted file mode 100644
--- a/pypy/interpreter/callbench/bmfilter.py
+++ /dev/null
@@ -1,20 +0,0 @@
-from sup import run
-
-def w(N, start):
-    x = range(50)
-    class A(object):
-        def f1(self, a):
-            return False
-
-    x = range(50)
-    a = A()
-    f1 = a.f1
-    flt = filter
-
-    start()
-    i = 0
-    while i < N:
-        flt(f1, x)
-        i+=1
-
-run(w, 200)
diff --git a/pypy/interpreter/callbench/bmmore.py 
b/pypy/interpreter/callbench/bmmore.py
deleted file mode 100644
--- a/pypy/interpreter/callbench/bmmore.py
+++ /dev/null
@@ -1,30 +0,0 @@
-from sup import run
-
-def w(N, start):
-    class A(object):
-        def f4(self, a, b, c, d):
-            pass
-        def f5(self, a, b, c, d, e):
-            pass
-    a = A()
-    f4 = a.f4
-    f5 = a.f5
-
-    start()
-    i = 0
-    while i < N:
-        f4(1, 2, 3, 4)
-        f4(1, 2, 3, 4)
-        f4(1, 2, 3, 4)    
-        f5(1, 2, 3, 4, 5)
-        f5(1, 2, 3, 4, 5)
-        f5(1, 2, 3, 4, 5)
-        f4(1, 2, 3, 4)
-        f4(1, 2, 3, 4)
-        f4(1, 2, 3, 4)    
-        f5(1, 2, 3, 4, 5)
-        f5(1, 2, 3, 4, 5)
-        f5(1, 2, 3, 4, 5)        
-        i+=1
-    
-run(w, 1000)
diff --git a/pypy/interpreter/callbench/compare.py 
b/pypy/interpreter/callbench/compare.py
deleted file mode 100644
--- a/pypy/interpreter/callbench/compare.py
+++ /dev/null
@@ -1,22 +0,0 @@
-# compare.py <results-file> <reference-results-file>
-
-import sys
-
-def main(cur, ref):
-    cur = open(cur, 'rU')
-    ref = open(ref, 'rU')
-    try:
-        while True:
-            cur_line = cur.next()
-            ref_line = ref.next()
-            cur_name, cur_t = cur_line.split()
-            ref_name, ref_t = ref_line.split()
-            assert cur_name == ref_name
-            cur_t = float(cur_t)
-            ref_t = float(ref_t)            
-            print "%-16s %.06g (x%.02f)" % (cur_name, cur_t, cur_t/ref_t)
-    except StopIteration:
-        pass
-
-if __name__ == '__main__':
-    main(sys.argv[1], sys.argv[2])
diff --git a/pypy/interpreter/callbench/f04.py 
b/pypy/interpreter/callbench/f04.py
deleted file mode 100644
--- a/pypy/interpreter/callbench/f04.py
+++ /dev/null
@@ -1,39 +0,0 @@
-from sup import run
-
-def w(N, start):
-    def f0():
-        pass
-    def f1(a):
-        pass
-    def f2(a, b):
-        pass
-    def f3(a, b, c):
-        pass
-    def f4(a, b, c, d):
-        pass
-    def f5(a, b, c, d, e):
-        pass
-
-    start()
-    i = 0
-    while i < N:
-        f0()
-        f0()
-        f0()
-        f1(1)
-        f1(1)
-        f2(1, 2)
-        f3(1, 2, 3)
-        f4(1, 2, 3, 4)
-        f5(1, 2, 3, 4, 5)
-        f0()
-        f0()
-        f0()
-        f1(1)
-        f1(1)
-        f2(1, 2)
-        f3(1, 2, 3)
-        f4(1, 2, 3, 4)        
-        i+=1
-
-run(w, 1000)
diff --git a/pypy/interpreter/callbench/fabvararg.py 
b/pypy/interpreter/callbench/fabvararg.py
deleted file mode 100644
--- a/pypy/interpreter/callbench/fabvararg.py
+++ /dev/null
@@ -1,26 +0,0 @@
-from sup import run
-
-def w(N, start):
-    def f(a, b, *args):
-        pass
-
-    z = (3, 4, 5)
-    start()
-
-    i = 0
-    while i < N:
-        f(1, 2, *z)
-        f(1, 2, *z)    
-        f(1, 2, *z)
-        f(1, 2, *z)
-        f(1, 2, *z)
-        f(1, 2, *z)
-        f(1, 2, *z)
-        f(1, 2, *z)    
-        f(1, 2, *z)
-        f(1, 2, *z)
-        f(1, 2, *z)
-        f(1, 2, *z)        
-        i+=1
-
-run(w, 1000)
diff --git a/pypy/interpreter/callbench/ffilter.py 
b/pypy/interpreter/callbench/ffilter.py
deleted file mode 100644
--- a/pypy/interpreter/callbench/ffilter.py
+++ /dev/null
@@ -1,14 +0,0 @@
-from sup import run
-
-def w(N, start):
-    def f1(a):
-        return False
-    x = range(50)
-
-    start()
-    i = 0
-    while i < N:
-        filter(f1, x)
-        i+=1
-    
-run(w, 200)
diff --git a/pypy/interpreter/callbench/ffunccall.py 
b/pypy/interpreter/callbench/ffunccall.py
deleted file mode 100644
--- a/pypy/interpreter/callbench/ffunccall.py
+++ /dev/null
@@ -1,36 +0,0 @@
-from sup import run
-
-def w(N, start):
-    class A(object):
-        def foo(self, x):
-            pass
-
-        __add__ = foo
-
-    a = A()
-    a1 = A()
-
-    start()
-    i = 0
-    while i < N:
-        a + a1
-        a + a1
-        a + a1
-        a + a1
-        a + a1
-        a + a1
-        a + a1
-        a + a1
-        a + a1
-        a + a1
-        a + a1
-        a + a1
-        a + a1
-        a + a1
-        a + a1
-        a + a1
-        a + a1
-        a + a1
-        i+=1
-    
-run(w, 1000)
diff --git a/pypy/interpreter/callbench/fmore.py 
b/pypy/interpreter/callbench/fmore.py
deleted file mode 100644
--- a/pypy/interpreter/callbench/fmore.py
+++ /dev/null
@@ -1,28 +0,0 @@
-from sup import run
-
-def w(N, start):
-    def f5(a, b, c, d, e):
-        pass
-    def f6(a, b, c, d, e, f):
-        pass
-
-    start()
-
-    i = 0
-    while i < N:
-        f5(1, 2, 3, 4, 5)
-        f5(1, 2, 3, 4, 5)
-        f5(1, 2, 3, 4, 5)
-        f5(1, 2, 3, 4, 5)
-        f5(1, 2, 3, 4, 5)
-        f5(1, 2, 3, 4, 5)
-
-        f6(1, 2, 3, 4, 5, 6)
-        f6(1, 2, 3, 4, 5, 6)
-        f6(1, 2, 3, 4, 5, 6)
-        f6(1, 2, 3, 4, 5, 6)
-        f6(1, 2, 3, 4, 5, 6)
-        f6(1, 2, 3, 4, 5, 6)            
-        i+=1
-
-run(w, 1000)
diff --git a/pypy/interpreter/callbench/inst.py 
b/pypy/interpreter/callbench/inst.py
deleted file mode 100644
--- a/pypy/interpreter/callbench/inst.py
+++ /dev/null
@@ -1,26 +0,0 @@
-from sup import run
-
-def w(N, start):
-    class A(object):
-        def __init__(self):
-            pass
-
-    class B(object):
-        def __init__(self, x, y):
-            pass
-
-    start()
-    i = 0
-    while i < N:
-        A()
-        A()
-        A()
-        A()
-        A()
-        B(1, 2)
-        B(1, 2)
-        B(1, 2)   
-        B(1, 2)
-        i+=1
-    
-run(w, 1000)
diff --git a/pypy/interpreter/callbench/inst_no_init.py 
b/pypy/interpreter/callbench/inst_no_init.py
deleted file mode 100644
--- a/pypy/interpreter/callbench/inst_no_init.py
+++ /dev/null
@@ -1,22 +0,0 @@
-from sup import run
-
-def w(N, start):
-    class A(object):
-        pass
-
-    start()
-    i = 0
-    while i < N:
-        A()
-        A()
-        A()
-        A()
-        A()
-        A()
-        A()
-        A()
-        A()
-        A()
-        i+=1
-    
-run(w, 1000)
diff --git a/pypy/interpreter/callbench/instcall.py 
b/pypy/interpreter/callbench/instcall.py
deleted file mode 100644
--- a/pypy/interpreter/callbench/instcall.py
+++ /dev/null
@@ -1,35 +0,0 @@
-from sup import run
-
-def w(N, start):
-    class A(object):
-        def __call__(self):
-            pass
-
-    a = A()
-
-    start()
-    i = 0
-    while i < N:
-        a()
-        a()
-        a()
-        a()
-        a()
-        a()
-        a()
-        a()
-        a()
-        a()
-        a()
-        a()
-        a()
-        a()
-        a()
-        a()
-        a()
-        a()        
-        a()
-        a()
-        i+=1
-    
-run(w, 1000)
diff --git a/pypy/interpreter/callbench/sup.py 
b/pypy/interpreter/callbench/sup.py
deleted file mode 100644
--- a/pypy/interpreter/callbench/sup.py
+++ /dev/null
@@ -1,39 +0,0 @@
-import sys, time
-
-def ref(N, start):
-    start()
-    i = 0
-    while i < N:
-        i+=1
-
-
-def run(func, n):
-    n *= int(sys.argv[1])
-    st = [None]
-    t = time.time
-
-    def start():
-        st[0] = t()
-
-    ref(n, start)
-    elapsed_ref1 = t() - st[0]
-    ref(n, start)
-    elapsed_ref2 = t() - st[0]
-    ref(n, start)
-    elapsed_ref3 = t() - st[0]    
-    elapsed_ref = min(elapsed_ref1, elapsed_ref2, elapsed_ref3)
-
-    func(n, start)
-    elapsed1 = t() - st[0]
-    func(n, start)
-    elapsed2 = t() - st[0]
-    func(n, start)
-    elapsed3 = t() - st[0]
-    elapsed = min(elapsed1, elapsed2, elapsed3)    
-
-    #if elapsed < elapsed_ref*10:
-    #    print "not enough meat", elapsed, elapsed_ref
-
-    print sys.argv[0].replace('.py', ''), elapsed-elapsed_ref
-    
-
_______________________________________________
pypy-commit mailing list
pypy-commit@python.org
http://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to