PointyCastle / pointycastle

Moved into the Bouncy Castle project: https://github.com/bcgit/pc-dart
MIT License
270 stars 76 forks source link

Slow performance on Android #206

Open yhc44 opened 4 years ago

yhc44 commented 4 years ago

Hello,

im thankfully using this lib for decrypting files that are encrypted with AES CTR. (chunk wise)

I made a speedtest, where the decryption of a file with 10 MB took

~2s on iPhone 8 Plus ~15s on Xiaomi Redmi Note 4. ~20s on Sony Xperia Z2

Why is there such a significant performance difference on iOS vs Android?

Thank you :)

wstrange commented 4 years ago

Have you compiled Android in release mode? Apple has a very fast SoC - and those may be older Android models - some of the difference may be expected.

yhc44 commented 4 years ago

Thank you for your fast response.

We compiled it in release mode, but it takes about 15-20 seconds to decrypt.

The Xiaomi Redmi Note 4 has the following specs:

I cant imagine, that the phone is that much slower to an iPhone?

buitrungkhang commented 4 years ago

I have same issue with generating RSA key pair on Android device, it takes 6-20s for other devices. Hope you can attend this issue.