Construct OperationAttributeLookup

Performance Diagrams

Construct OperationAttributeLookup 001000000100000020000002000000300000030000004000000400000050000005000000600000060000007000000700000080000008000000CPython 2.7Nuitka (master)Nuitka (develop)Nuitka (factory)822386689.78846153846155257.0CPython 2.74975072244.59615384615387354.62160264359295Nuitka (master)4975036399.4038461538462354.62268439198795Nuitka (develop)4975018554.2115384615385354.6232252661854Nuitka (factory)Construct OperationAttributeLookupTicks Construct OperationAttributeLookup 001000000100000020000002000000300000030000004000000400000050000005000000600000060000007000000700000080000008000000CPython 3.5Nuitka (master)Nuitka (develop)Nuitka (factory)844339289.78846153846155257.0CPython 3.55199856244.59615384615387351.92957879414416Nuitka (master)5200027399.4038461538462351.92457408386076Nuitka (develop)5199954554.2115384615385351.92671059760744Nuitka (factory)Construct OperationAttributeLookupTicks

Source Code with Construct

module_value1 = list()
module_value2 = 3000

def calledRepeatedly():
    # Force frame and eliminate forward propagation (currently).
    module_value1

    local_value = module_value1

    s = module_value1
    s.append
# construct_begin
    s.append
# construct_end
    s.append

    return s, local_value

import itertools
for x in itertools.repeat(None, 25000):
    calledRepeatedly()

print("OK.")

Source Code without Construct

module_value1 = list()
module_value2 = 3000

def calledRepeatedly():
    # Force frame and eliminate forward propagation (currently).
    module_value1

    local_value = module_value1

    s = module_value1
    s.append
# construct_begin


    s.append

    return s, local_value

import itertools
for x in itertools.repeat(None, 25000):
    calledRepeatedly()

print("OK.")

Context Diff of Source Code


Construct
Baseline
28     local_value = module_value1 28     local_value = module_value1
29 29
30     s = module_value1 30     s = module_value1
31     s.append 31     s.append
32 # construct_begin 32 # construct_begin
t 33     s.append t 33  
34 # construct_end 34  
35     s.append 35     s.append
36 36
37     return s, local_value 37     return s, local_value
38 38
39 import itertools 39 import itertools

Context Diff of Generated Code


Construct
Baseline
270             assert( ERROR_OCCURRED() ); 270             assert( ERROR_OCCURRED() );
271 271
272             FETCH_ERROR_OCCURRED( &exception_type, &exception_value, &exception_tb ); 272             FETCH_ERROR_OCCURRED( &exception_type, &exception_value, &exception_tb );
273 273
274 274
n 275             exception_lineno = 33; n
276             type_description_1 = "oo";
277             goto frame_exception_exit_1;
278         }
279         Py_DECREF( tmp_attribute_value_2 );
280     }
281     {
282         PyObject *tmp_source_name_3;
283         PyObject *tmp_attribute_value_3;
284         CHECK_OBJECT( var_s );
285         tmp_source_name_3 = var_s;
286         tmp_attribute_value_3 = LOOKUP_ATTRIBUTE( tmp_source_name_3, const_str_plain_append );
287         if ( tmp_attribute_value_3 == NULL )
288         {
289             assert( ERROR_OCCURRED() );
290  
291             FETCH_ERROR_OCCURRED( &exception_type, &exception_value, &exception_tb );
292  
293  
294             exception_lineno = 35; 275             exception_lineno = 35;
295             type_description_1 = "oo"; 276             type_description_1 = "oo";
296             goto frame_exception_exit_1; 277             goto frame_exception_exit_1;
297         } 278         }
t 298         Py_DECREF( tmp_attribute_value_3 ); t 279         Py_DECREF( tmp_attribute_value_2 );
299     } 280     }
300 281
301 #if 0 282 #if 0
302     RESTORE_FRAME_EXCEPTION( frame_1fc88d9cbdb674588adc5fd770108146 ); 283     RESTORE_FRAME_EXCEPTION( frame_1fc88d9cbdb674588adc5fd770108146 );
303 #endif 284 #endif