Construct CallCompiledInstanceMethodPosArgsConstant6_27

Performance Diagrams

Construct CallCompiledInstanceMethodPosArgsConstant6_27 002000000020000000400000004000000060000000600000008000000080000000100000000100000000120000000120000000140000000140000000160000000160000000180000000180000000200000000200000000220000000220000000240000000240000000260000000260000000CPython 2.7Nuitka (historic)Nuitka (master)Nuitka (develop)Nuitka (factory)27312923972.9230769230769257.0CPython 2.7103004273194.46153846153845410.9216253803176Nuitka (historic)91257319316.0421.54975536888037Nuitka (master)90306735437.53846153846143422.4098021790618Nuitka (develop)90307723559.0769230769231422.408908279892Nuitka (factory)Construct CallCompiledInstanceMethodPosArgsConstant6_27Ticks

Source Code with Construct

from __future__ import print_function

class C:
    def compiled_method(self, a,b,c,d,e,f):
        return a, b, c, d, e, f

def calledRepeatedly():
    inst = C()

    # This is supposed to make a call to a non-compiled function, which is
    # being optimized separately.
# construct_begin
    inst.compiled_method("some", "random", "values", "to", "check", "call")
    inst.compiled_method("some", "other", "values", "to", "check", "call")
    inst.compiled_method("some", "new", "values", "to", "check", "call")

# construct_alternative



for x in xrange(50000):
    calledRepeatedly()

print("OK.")

Source Code without Construct

from __future__ import print_function

class C:
    def compiled_method(self, a,b,c,d,e,f):
        return a, b, c, d, e, f

def calledRepeatedly():
    inst = C()

    # This is supposed to make a call to a non-compiled function, which is
    # being optimized separately.
# construct_begin




# construct_alternative
    pass
# construct_end

for x in xrange(50000):
    calledRepeatedly()

print("OK.")

Context Diff of Source Code


Construct
Baseline
27     inst = C() 27     inst = C()
28 28
29     # This is supposed to make a call to a non-compiled function, which is 29     # This is supposed to make a call to a non-compiled function, which is
30     # being optimized separately. 30     # being optimized separately.
31 # construct_begin 31 # construct_begin
n 32     inst.compiled_method("some", "random", "values", "to", "check", "call") n 32  
33     inst.compiled_method("some", "other", "values", "to", "check", "call") 33  
34     inst.compiled_method("some", "new", "values", "to", "check", "call") 34  
35 35
36 # construct_alternative 36 # construct_alternative
t 37   t 37     pass
38   38 # construct_end
39 39
40 for x in xrange(50000): 40 for x in xrange(50000):
41     calledRepeatedly() 41     calledRepeatedly()
42 42
43 print("OK.") 43 print("OK.")