Results: I removed the other hash algorithm on test.cpp and gave as an
input a ~700MB file.
Upstream:
$ time ./cryptest.exe m ~/ubuntu-16.10-server-ppc64el.iso
SHA-256: d14bdb413ea6cdc8d9354fcbc37a834b7de0c23f992deb0c6764d0fd5d65408e
real 0m18.811s
user 0m18.456s
sys 0m0.356s
This patch:
$ time ./cryptest.exe m ~/ubuntu-16.10-server-ppc64el.iso
SHA-256: d14bdb413ea6cdc8d9354fcbc37a834b7de0c23f992deb0c6764d0fd5d65408e
real 0m4.158s
user 0m3.992s
sys 0m0.168s
This approach used altivec + VSX instructions found on POWER8 systems
and newer.
If unwanted on PPC, "cmake" it with -DDISABLE_ALTIVEC=1 or "make" it
with USE_ALTIVEC=0.
Port rdrand.S to Cygwin and OS X
Add DISABLE_NATIVE_ARCH to CmakefileList and GNUmakefile. It supresses the addition of -march=native. DISABLE_NATIVE_ARCH replaces DISABLE_CXXFLAGS_OPTIMIZATIONS in CmakefileList (the latter is now deprecated).
Targets with only object inputs do not work correctly with some
generators (like Xcode, see issue #355). Defining these directly in
terms of the source code files (rather than a reused set of object
files) allows correct builds in such cases. This can now be controlled
through a new option USE_INTERMEDIATE_OBJECTS_TARGET which defaults to
ON.
handy when packaging should control optimization without build system
masking. Especially handy when building to common architecture.
no change of behavior if DISABLE_CXXFLAGS_OPTIMIZATIONS is unset.
Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
Add CRYPTOPP_CROSS_COMPILE variable. Guard host uname calls on CROSS_COMPILE. Set CMAKE_CXX_LINK_FLAGS to CMAKE_CXX_FLAGS. Change to SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} <option>") pattern.