%PDF- %PDF-
Direktori : /snap/core18/current/usr/lib/python3.6/test/__pycache__/ |
Current File : //snap/core18/current/usr/lib/python3.6/test/__pycache__/pystone.cpython-36.pyc |
3 /�$h1 � @ s� d Z dZddlmZ dZedd�\ZZZZZ G dd� d�Z dZdZefd d �Z efdd�Zdaead ad adgd add� tgd D �adadaefdd�Zdd� Zdd� Zdd� Zdd� Zdd� Zdd� Zd d!� Zd"d#� Zd$d%� Z d&d'� Z!d(d)� Z"e#d*k�r�ddl$Z$d+d,� Z%e&e$j'�d Z(e(dk�r4e%d-e( � nLe(dk�r|ye)e$j'd �Z*W n( e+k �rx e%d.e$j'd � Y nX neZ*e e*� dS )/aD "PYSTONE" Benchmark Program Version: Python/1.2 (corresponds to C/1.1 plus 3 Pystone fixes) Author: Reinhold P. Weicker, CACM Vol 27, No 10, 10/84 pg. 1013. Translated from ADA to C by Rick Richardson. Every method to preserve ADA-likeness has been used, at the expense of C-ness. Translated from C to Python by Guido van Rossum. Version History: Version 1.1 corrects two bugs in version 1.0: First, it leaked memory: in Proc1(), NextRecord ends up having a pointer to itself. I have corrected this by zapping NextRecord.PtrComp at the end of Proc1(). Second, Proc3() used the operator != to compare a record to None. This is rather inefficient and not true to the intention of the original benchmark (where a pointer comparison to None is intended; the != operator attempts to find a method __cmp__ to do value comparison of the record). Version 1.1 runs 5-10 percent faster than version 1.0, so benchmark figures of different versions can't be compared directly. Version 1.2 changes the division to floor division. Under Python 3 version 1.1 would use the normal division operator, resulting in some of the operations mistakenly yielding floats. Version 1.2 instead uses floor division making the benchmark an integer benchmark again. iP� � )�timez1.2� � c @ s e Zd Zddd�Zdd� ZdS )�RecordNr c C s"