Commit Graph

23 Commits

Author SHA1 Message Date
Jeffrey Walton
37e02f9e0e
Revert AltiVec and Power8 commits
The strategy of "cleanup under-aligned buffers" is not scaling well. Corner cases are still turing up. The library has some corner-case breaks, like old 32-bit Intels. And it still has not solved the AltiVec and Power8 alignment problems.
For now we are backing out the changes and investigating other strategies
2017-09-05 16:28:00 -04:00
Jeffrey Walton
6b1a56cf72
Fixup under-aligned buffers for DefaultEncryptors and DefaultDecryptors on AltiVec and Power8
This commit supports the upcoming AltiVec and Power8 processor support for DefaultEncryptors and DefaultDecryptors. The commit favors AlignedSecByteBlock over SecByteBlock in places where messages are handled on the AltiVec and Power8 processor data paths. The data paths include all block cipher modes of operation, and some filters like FilterWithBufferedInput.

Intel and ARM processors are tolerant of under-aligned buffers when using crypto intstructions. AltiVec and Power8 are less tolerant, and they simply ignore the three low-order bits to ensure an address is aligned. The AltiVec and Power8 have caused a fair number of wild writes on the stack and in the heap.

Testing on a 64-bit Intel Skylake show a marked improvement in performance. We suspect GCC is generating better code since it knows the alignment of the pointers, and does not have to emit fixup code for under-aligned and mis-aligned data. Testing on an mid-2000's 32-bit VIA C7-D with SSE2+SSSE3 showed no improvement, and no performance was lost.
2017-09-04 10:47:55 -04:00
Jeffrey Walton
6f36c7deae
Cleared UBsan finding in Default's GenerateKeyIV
passed:  128 deflates and inflates
passed:  128 zlib decompress and compress
default.cpp:69:2: runtime error: null pointer passed as argument 2, which is declared to never be null
/usr/include/x86_64-linux-gnu/bits/string3.h:53:71: runtime error: null pointer passed as argument 2, which is declared to never be null

Information Dispersal and Secret Sharing...
2017-08-15 08:51:03 -04:00
Jeffrey Walton
f5aa6f1f06
Cast enums to int for comparison 2017-08-11 17:15:13 -04:00
Jeffrey Walton
5efb019d8b
Add C++ nullptr support (Issue 383) 2017-03-01 06:10:06 -05:00
Jeffrey Walton
81b1a18063
Change file preamble to include "originally written by Wei Dai"
We have made a fair number of changes, and we don't want WD to receive credit for issues he was not part of
2017-01-27 07:05:45 -05:00
Jeffrey Walton
7ece03d762
Updated documentation (Issue 345) 2016-12-11 06:44:18 -05:00
Jeffrey Walton
bfbcfeec7c
Update DefaultEncryptor, DefaultEncryptorWithMAC and friends (Issue 345) 2016-12-11 05:09:42 -05:00
Jeffrey Walton
ba75834ae9
Removed VC++ 5.0 and 6.0 workarounds (Issue 342) 2016-12-03 05:05:56 -05:00
Jeffrey Walton
40230dd3bf
Removed MAINTAIN_BACKWARDS_COMPATIBILITY_562 (Issue 70) 2016-12-03 00:32:07 -05:00
Jeffrey Walton
298988a5b9 Crypto++ 5.6.3 check-in 2015-11-22 19:17:15 -05:00
Jeffrey Walton
62618fda97 Revert botched "Crypto++ 5.6.3 check-in". Corruption due to VMware adding garbage to the end of some source files during drag and drop from guest to host.
This reverts commit c454358122.
2015-11-22 19:11:31 -05:00
Jeffrey Walton
c454358122 Crypto++ 5.6.3 check-in 2015-11-20 19:15:33 -05:00
Jeffrey Walton
48809d4e85 CRYPTOPP 5.6.3 RC6 checkin 2015-11-05 01:59:46 -05:00
Jeffrey Walton
1e103c0e5b Completed cutover to unscoped auto_ptr (which will use Crypto++'s namespace version) 2015-08-03 19:11:23 -04:00
Jeffrey Walton
22c3e41133 Removed USING_NAMESPACE(std). Changed cout → std::cout, cerr → std::cerr, ... 2015-07-30 17:35:58 -04:00
Jeffrey Walton
ef318d5423 Fixed compiler errors on Apple due to cross product of {C++03,C++11} x {libc++, libstdc++}. It included bringing in the correct <memory> in <stdcpp.h>, and then only including <stdcpp.h> when <memory> was needed. 2015-07-27 16:01:55 -04:00
Jeffrey Walton
c23c02171d Cleared "signed/unsigned" warning under GCC 4.8 2015-07-26 00:18:25 -04:00
Jeffrey Walton
a14a5696e1 Added GCC_DIAGNOSTIC_AWARE to help suppress some warnings on contemporary compilers. The macro was needed to help with managing old compilers, like GCC 4.2.1, present on OpenBSD 2015-06-29 02:09:02 -04:00
weidai
d8a644fc4e changes for 5.6:
- added AuthenticatedSymmetricCipher interface class and Filter wrappers
    - added CCM, GCM (with SSE2 assembly), CMAC, and SEED
    - improved AES speed on x86 and x64
    - removed WORD64_AVAILABLE; compiler 64-bit int support is now required
2009-03-02 02:39:17 +00:00
weidai
1db8ea5084 port to MSVC .NET 2005 beta 2 2005-07-12 04:23:32 +00:00
weidai
b3924f2108 changes done for FIPS-140 lab code drop 2005-01-20 04:19:35 +00:00
weidai
a3b6ece7ab Initial revision 2002-10-04 17:31:41 +00:00