[Stackless] verify my performance numbers?

Andrew Dalke dalke at dalkescientific.com
Sat Jan 27 11:36:11 CET 2007


On Jan 27, 2007, at 7:29 AM, Richard Tew wrote:
> I would be interested in seeing the difference if a non-stackless
> version of Python was used as well.  The generator implementation in
> stackless for instance is supposed to be slower than in basic Python
> itself, and Stackless' changes to the core Python code may have some
> effect on the timing.

Here's pybench comparing
   Python built from svn on Oct. 1, 2006
   Stackless built from svn a couple of days ago

The numbers are close enough that I'll want to rebuild Python from
svn and make a few more timing tests to make any definitive statement.

Note though that pybench does not benchmark list comprehensions,
generator comprehensions nor generators.

------------------------------------------------------------------------ 
-------
Benchmark: 2007-01-27 10:24:58
------------------------------------------------------------------------ 
-------

     Rounds: 10
     Warp:   10
     Timer:  time.time

     Machine Details:
        Platform ID:  Darwin-7.9.0-Power_Macintosh-powerpc-32bit
        Processor:    powerpc

     Python:
        Executable:   /usr/local/bin/spython
        Version:      2.5.0
        Compiler:     GCC 3.3 20030304 (Apple Computer, Inc. build 1495)
        Bits:         32bit
        Build:        Jan 24 2007 16:19:13 (#release25-maint:53542)
        Unicode:      UCS2


------------------------------------------------------------------------ 
-------
Comparing with: /Users/dalke/tmp/timings.dat
------------------------------------------------------------------------ 
-------

     Rounds: 10
     Warp:   10
     Timer:  time.time

     Machine Details:
        Platform ID:  Darwin-7.9.0-Power_Macintosh-powerpc-32bit
        Processor:    powerpc

     Python:
        Executable:    
/Users/dalke/cvses/python-svn/Tools/pybench/../../python.exe
        Version:      2.6a0.0
        Compiler:     GCC 3.3 20030304 (Apple Computer, Inc. build 1495)
        Bits:         32bit
        Build:        Oct  1 2006 16:11:56 (#trunk:52082M)
        Unicode:      UCS2


Test                             minimum run-time        average   
run-time
                                  this    other   diff    this    other   
  diff
------------------------------------------------------------------------ 
-------
           BuiltinFunctionCalls:   558ms   546ms   +2.3%   577ms   558ms  
   +3.4%
            BuiltinMethodLookup:   500ms   499ms   +0.1%   540ms   506ms  
   +6.8%
                  CompareFloats:   396ms   399ms   -0.6%   415ms   413ms  
   +0.7%
          CompareFloatsIntegers:   425ms   421ms   +0.9%   440ms   449ms  
   -2.0%
                CompareIntegers:   307ms   308ms   -0.1%   315ms   327ms  
   -3.7%
         CompareInternedStrings:   523ms   437ms  +19.6%   535ms   456ms  
  +17.4%
                   CompareLongs:   339ms   340ms   -0.2%   352ms   348ms  
   +1.1%
                 CompareStrings:   414ms   361ms  +14.7%   435ms   370ms  
  +17.5%
                 CompareUnicode:   383ms   385ms   -0.6%   400ms   391ms  
   +2.2%
                  ConcatStrings:   531ms   555ms   -4.3%   548ms   567ms  
   -3.2%
                  ConcatUnicode:   364ms   384ms   -5.1%   381ms   398ms  
   -4.3%
                CreateInstances:   537ms   520ms   +3.3%   560ms   555ms  
   +1.0%
             CreateNewInstances:   466ms   445ms   +4.6%   487ms   478ms  
   +1.9%
        CreateStringsWithConcat:   429ms   429ms   -0.1%   440ms   447ms  
   -1.5%
        CreateUnicodeWithConcat:   507ms   480ms   +5.4%   519ms   497ms  
   +4.5%
                   DictCreation:   368ms   368ms   -0.1%   384ms   377ms  
   +2.1%
              DictWithFloatKeys:   574ms   613ms   -6.4%   598ms   623ms  
   -4.0%
            DictWithIntegerKeys:   412ms   414ms   -0.5%   428ms   424ms  
   +0.9%
             DictWithStringKeys:   369ms   373ms   -1.2%   380ms   395ms  
   -3.8%
                       ForLoops:   333ms   299ms  +11.3%   350ms   318ms  
  +10.0%
                     IfThenElse:   241ms   240ms   +0.3%   253ms   256ms  
   -1.3%
                    ListSlicing:   442ms   442ms   +0.0%   468ms   456ms  
   +2.7%
                 NestedForLoops:   433ms   401ms   +8.1%   452ms   412ms  
   +9.6%
           NormalClassAttribute:   514ms   496ms   +3.6%   534ms   507ms  
   +5.4%
        NormalInstanceAttribute:   444ms   446ms   -0.5%   477ms   454ms  
   +4.9%
            PythonFunctionCalls:   433ms   399ms   +8.4%   449ms   410ms  
   +9.6%
              PythonMethodCalls:   605ms   557ms   +8.7%   631ms   587ms  
   +7.6%
                      Recursion:   659ms   584ms  +12.9%   680ms   615ms  
  +10.5%
                   SecondImport:   437ms   428ms   +2.3%   471ms   437ms  
   +7.8%
            SecondPackageImport:   447ms   438ms   +2.1%   471ms   454ms  
   +3.6%
          SecondSubmoduleImport:   544ms   540ms   +0.9%   570ms   548ms  
   +4.0%
        SimpleComplexArithmetic:   537ms   535ms   +0.4%   575ms   550ms  
   +4.5%
         SimpleDictManipulation:   412ms   408ms   +0.8%   444ms   429ms  
   +3.5%
          SimpleFloatArithmetic:   419ms   424ms   -1.2%   437ms   460ms  
   -5.0%
       SimpleIntFloatArithmetic:   286ms   286ms   -0.1%   296ms   308ms  
   -3.6%
        SimpleIntegerArithmetic:   285ms   289ms   -1.2%   292ms   301ms  
   -3.0%
         SimpleListManipulation:   333ms   333ms   -0.0%   344ms   345ms  
   -0.2%
           SimpleLongArithmetic:   383ms   382ms   +0.2%   396ms   390ms  
   +1.6%
                     SmallLists:   458ms   439ms   +4.5%   478ms   452ms  
   +5.9%
                    SmallTuples:   387ms   382ms   +1.4%   408ms   390ms  
   +4.5%
          SpecialClassAttribute:   504ms   485ms   +3.9%   518ms   500ms  
   +3.6%
       SpecialInstanceAttribute:   582ms   584ms   -0.2%   607ms   616ms  
   -1.5%
                 StringMappings:   439ms   425ms   +3.4%   470ms   451ms  
   +4.1%
               StringPredicates:   490ms   478ms   +2.4%   532ms   494ms  
   +7.7%
                  StringSlicing:   498ms   462ms   +7.9%   516ms   481ms  
   +7.2%
                      TryExcept:   358ms   358ms   -0.1%   373ms   367ms  
   +1.6%
                 TryRaiseExcept:   396ms   396ms   +0.2%   420ms   402ms  
   +4.5%
                   TupleSlicing:   424ms   412ms   +2.7%   444ms   425ms  
   +4.5%
                UnicodeMappings:   498ms   491ms   +1.5%   508ms   511ms  
   -0.7%
              UnicodePredicates:   494ms   450ms   +9.7%   515ms   483ms  
   +6.8%
              UnicodeProperties:   485ms   461ms   +5.3%   552ms   478ms  
  +15.6%
                 UnicodeSlicing:   497ms   460ms   +8.0%   521ms   472ms  
  +10.4%
------------------------------------------------------------------------ 
-------
Totals:                         23098ms 22486ms   +2.7% 24188ms 23337ms  
   +3.7%

(this=2007-01-27 10:24:58, other=/Users/dalke/tmp/timings.dat)


> I do not have Itunes so I cannot run the tests myself.

You only need a largish XML file with a lot of elements.
Nothing in my test requires it to be iTunes formatted.

					Andrew
					dalke at dalkescientific.com


_______________________________________________
Stackless mailing list
Stackless at stackless.com
http://www.stackless.com/mailman/listinfo/stackless



More information about the Stackless mailing list