Am 08.08.2015 um 19:51 schrieb Ilya Bizyaev: > Hello! > I want to change my application to process data in multiple threads. It uses > AES/GCM (128 for the header and 256 for the file). > Is what I want possible? If you use as many AES-GCM instances as you have threads it's certainly possible. Meaning if you expect 4 threads, you put 4 IVs/Nonces in the file and use those 4 nonces to process 4 chunks of your file and finally verify four tags. This will definitely work. (with arbitrary constant values replacing "4") Encryption and Decryption with CTR (underlying GCM) are also no problem to be parallelized as you can just read in the whole chunk, create your instances and let each instance seek() to the desired position. If I'm reading the code right it's impossible to parallelize GCM if you want to stay with one tag (IsRandomAccess() returns false).
However I doubt that parallelized Encryption / Decryption will be of much value for you (or for anybody requiring production use) as you can reach ~1GiB / s with a modern processor (using AES-NI) per core. Even if you reach "only" 500 MiB / s this means that encryption won't be the bottleneck unless you're running RAID-0 SSDs (SATA-III) or using those new fancy high-speed SSDs (SATAExpress / M.2 over PCIe). > Does Crypto++ use multiple threads itself? > No. Crypto++ doesn't use multiple threads by itself. (with one exception at the moment) Only some part of the (new) Rabin-Williams Signing function uses OpenMP to parallelize some loop (and yields worse performance than linear execution...). BR JPM -- -- You received this message because you are subscribed to the "Crypto++ Users" Google Group. To unsubscribe, send an email to [email protected]. More information about Crypto++ and this group is available at http://www.cryptopp.com. --- You received this message because you are subscribed to the Google Groups "Crypto++ Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
smime.p7s
Description: S/MIME Cryptographic Signature
