Server : LiteSpeed
System : Linux server51.dnsbootclub.com 4.18.0-553.62.1.lve.el8.x86_64 #1 SMP Mon Jul 21 17:50:35 UTC 2025 x86_64
User : nandedex ( 1060)
PHP Version : 8.1.33
Disable Function : NONE
Directory :  /opt/cppython/lib/python3.8/test/__pycache__/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]


Current File : //opt/cppython/lib/python3.8/test/__pycache__/time_hashlib.cpython-38.opt-1.pyc
U

>��g�@s>ddlZddlZddlZdd�Zdd�Zdd�Zdd	�Zejd
Zedkrte	de�e	d
ed�e
ded�n�edkr�eej�dkr�ddlZe	dejd�e
dejde
eejd��n�edk�reej�dk�rddlZe	dejd�e
dejd�nVeee��rLee
ee�d��rLe
ee�Ze
dee
ee��ne	de�e
de�z
e�WnTek
�r�e
�e
d�e
d�e
d�e
d�e
d �e
d!�e
��YnXe�ed"d#d$�ed%d&d$�ed'd(d$�ed)d*d$�ed+d,d$�ed-d.d$�ed/d0d$�ee�jd1d$�ed2d3d$�dS)4�NcCstd��dS)Nzeek, creatorFunc not overridden)�RuntimeError�rr�0/opt/cppython/lib/python3.8/test/time_hashlib.py�creatorFunc	src	Csfd|d}d|}t}t��}t|�D]}||���}q(t��}td||d|dt|�d|�dS)N�ٞ��Z�%2.2f�seconds�x�bytes)r�time�perf_counter�range�digest�print�len)	�scale�nameZ
iterationsZlongStrZlocalCF�start�fr�endrrr�test_scaled_msgsrcCs<t��}td�D]
}t�}qt��}td||dd�dS)N� Nr	r
z[20000 creations])r
rrrr)rr�drrrr�test_creates
rcCs@t��}td�D]}t���}qt��}td||dd�dS)Nrr	r
z[20000 "" digests])r
rrrrr)rrrrrrr�	test_zero s
r�)Z_md5Z_shazimport zcreatorFunc = z.newztesting speed of oldzlegacy interface�_hashlib�zcreatorFunc = _hashlib.%s�ztesting speed of _hashlib.%sz+creatorFunc = lambda x=_hashlib.new : x(%r)z!testing speed of _hashlib.new(%r)�__call__ztesting speed of hashlib.z*creatorFunc = lambda x=hashlib.new : x(%r)z testing speed of hashlib.new(%r)z8pass argument(s) naming the hash to run a speed test on:z6 '_md5' and '_sha' test the legacy builtin md5 and shaz= '_hashlib' 'openssl_hName' 'fast' tests the builtin _hashlibz6 '_hashlib' 'hName' tests builtin _hashlib.new(shaFOO)z> 'hName' tests the hashlib.hName() implementation if it existsz.         otherwise it uses hashlib.new(hName).rz[huge data])rri|)z[large data]i&z
[medium data]i�z[4*small data]iPz[3*small data]��z[2*small data]�jz[small data]z[digest_size data]�
z[tiny data])�sysr
Zhashlibrrrr�argvZhName�execrrr�getattr�hasattr�
ValueError�digest_sizerrrr�<module>s\

"



F1le Man4ger