Skip to content
This repository has been archived by the owner on Jan 27, 2022. It is now read-only.

AES-NI to slow #101

Closed
t2d opened this issue Nov 6, 2014 · 2 comments
Closed

AES-NI to slow #101

t2d opened this issue Nov 6, 2014 · 2 comments

Comments

@t2d
Copy link

t2d commented Nov 6, 2014

Today I did a test and encryped as many blocks as possible with AES.
The numbers variate around almost the same amount, whether I use use_aesni=True or use_aesni=False.
I checked with python -v and _AESNI.c is loaded at runtime.
How can that be?
If I test with openssl speed AESNI is up to 6 times faster than plain AES.

@dlitz
Copy link
Member

dlitz commented Jul 10, 2015

What does your test code look like? Are you passing a large buffer to .encrypt(...), or are you invoking .encrypt(...) many times with small buffers? The latter is slow simply because of the Python interpreter's overhead.

@t2d
Copy link
Author

t2d commented Jul 10, 2015

yes, it was a lot of small ones. Thanks for the clarification.

@t2d t2d closed this as completed Jul 10, 2015
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants