aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/block/shacal2
Commit message (Collapse)AuthorAgeFilesLines
* Avoid including rotate.h in bswap.hJack Lloyd2018-12-211-0/+1
| | | | | | | It was only needed for one case which is easily hardcoded. Include rotate.h in all the source files that actually use rotr/rotl but implicitly picked it up via loadstor.h -> bswap.h -> rotate.h include chain.
* Remove SIMD_32 typedefJack Lloyd2018-11-051-6/+6
| | | | | It is confusing since its not clear from the name how many elements it has, and this gives consistency with SIMD_8x32 type.
* Add missing ISA annotationsJack Lloyd2018-01-041-0/+1
| | | | Lack of these broke single file amalgamation (GH #1386)
* Format tweaksJack Lloyd2017-11-021-2/+2
|
* Add checks that keyed algorithms are actually keyed before useJack Lloyd2017-10-261-0/+4
| | | | | Previously calling update or encrypt without calling set_key first would result in invalid outputs or else crashing.
* Add compile-time rotation functionsJack Lloyd2017-10-122-10/+10
| | | | | | | | | | | | | | | | | The problem with asm rol/ror is the compiler can't schedule effectively. But we only need asm in the case when the rotation is variable, so distinguish the two cases. If a compile time constant, then static_assert that the rotation is in the correct range and do the straightforward expression knowing the compiler will probably do the right thing. Otherwise do a tricky expression that both GCC and Clang happen to have recognize. Avoid the reduction case; instead require that the rotation be in range (this reverts 2b37c13dcf). Remove the asm rotations (making this branch illnamed), because now both Clang and GCC will create a roll without any extra help. Remove the reduction/mask by the word size for the variable case. The compiler can't optimize that it out well, but it's easy to ensure it is valid in the callers, especially now that the variable input cases are easy to grep for.
* Correct an error in SHACAL2 x86 code in unrolled caseJack Lloyd2017-09-201-3/+3
| | | | [ci skip]
* Change header guard format to BOTAN_FOO_H_Jack Lloyd2017-09-201-2/+2
| | | | | | ISO C++ reserves names with double underscores in them Closes #512
* More annotationsJack Lloyd2017-09-191-1/+1
|
* In SHACAL2 be smarter about how the round keys are loadedJack Lloyd2017-08-161-9/+15
| | | | | | Using _mm_set_epi32 caused 2 distinct (adjacent) loads followed by an unpack to combine the registers. Have not tested on hardware to see if this actually improves performance.
* Optimize SHACAL2Jack Lloyd2017-08-162-46/+20
| | | | | | Combine several shuffle operations into one. Thanks to jww for the hint. Probably not noticably faster on any system.
* Add 2x unrolling for SHACAL2 on x86Jack Lloyd2017-08-141-2/+71
|
* Add support for SHACAL2 using x86 SHA extensionsJack Lloyd2017-08-144-0/+109
|
* Notify callers of parallel ops for AES, IDEA, Noekeon, SHACAL2 and ThreefishJack Lloyd2017-08-142-0/+21
|
* Pass by reference for MSVC x86Jack Lloyd2017-08-141-6/+8
| | | | | It complains it cannot pass the __m128i without loss of alignment. (Why, I have no idea.)
* Add SHACAL2 in generic SIMDJack Lloyd2017-08-134-0/+157
| | | | Bit over 2x faster on my desktop
* Add SHACAL2Jack Lloyd2017-08-133-0/+209
256 bit ARX block cipher with hardware support, what's not to love.