• [^] # Re: show me the code

    Posté par (site web personnel) . En réponse au journal Pythran 0.2 : Python peut-il être aussi rapide que du C ?. Évalué à 6.

    Homme de peu de foi !

    Test efectué à l'instant avec la branche compas2013 du dépot sus-cité
    Sur l'archive http://ridee.enstb.org/sguelton/hyantes_bench.tgz

    En supposant pythran installé quelque par

    # la ref
    clang -O2 hyantes.c -lm -o hyantes
    time ./hyantes 'Rhone-alpesXYLongLat_pop.txt' 1.1 32 4 35 0.01 40 > /dev/null
    real 0m22.223s
    CXX=clang++ pythran -O2 hyantes_core.py
    time python hyantes.py > /dev/null
    real 0m22.767s
    # pareil avec gcc
    gcc -O2 hyantes.c -lm -o hyantes
    time ./hyantes 'Rhone-alpesXYLongLat_pop.txt' 1.1 32 4 35 0.01 40 > /dev/null
    real 0m25.905s
    CXX=g++ python ~/sources/pythran/scripts/pythran -O2 hyantes_core.py
    time python hyantes.py > /dev/null
    real 0m26.362s
    
    

    Le tout sur un Core I7.

    à vot' service Saint Thomas !