#include <botan/internal/aes.h>
#include <botan/compiler.h>
#include <botan/internal/cpuid.h>
#include <altivec.h>
Go to the source code of this file.
|
#define | AES_DECRYPT_4(B0, B1, B2, B3, K) |
|
#define | AES_DECRYPT_4_LAST(B0, B1, B2, B3, K) |
|
#define | AES_ENCRYPT_4(B0, B1, B2, B3, K) |
|
#define | AES_ENCRYPT_4_LAST(B0, B1, B2, B3, K) |
|
#define | AES_XOR_4(B0, B1, B2, B3, K) |
|
◆ AES_DECRYPT_4
#define AES_DECRYPT_4 |
( |
| B0, |
|
|
| B1, |
|
|
| B2, |
|
|
| B3, |
|
|
| K ) |
Value: do { \
B0 = __builtin_crypto_vncipher(B0, K); \
B1 = __builtin_crypto_vncipher(B1, K); \
B2 = __builtin_crypto_vncipher(B2, K); \
B3 = __builtin_crypto_vncipher(B3, K); \
} while(0)
Definition at line 82 of file aes_power8.cpp.
82#define AES_DECRYPT_4(B0, B1, B2, B3, K) \
83 do { \
84 B0 = __builtin_crypto_vncipher(B0, K); \
85 B1 = __builtin_crypto_vncipher(B1, K); \
86 B2 = __builtin_crypto_vncipher(B2, K); \
87 B3 = __builtin_crypto_vncipher(B3, K); \
88 } while(0)
◆ AES_DECRYPT_4_LAST
#define AES_DECRYPT_4_LAST |
( |
| B0, |
|
|
| B1, |
|
|
| B2, |
|
|
| B3, |
|
|
| K ) |
Value: do { \
B0 = __builtin_crypto_vncipherlast(B0, K); \
B1 = __builtin_crypto_vncipherlast(B1, K); \
B2 = __builtin_crypto_vncipherlast(B2, K); \
B3 = __builtin_crypto_vncipherlast(B3, K); \
} while(0)
Definition at line 90 of file aes_power8.cpp.
90#define AES_DECRYPT_4_LAST(B0, B1, B2, B3, K) \
91 do { \
92 B0 = __builtin_crypto_vncipherlast(B0, K); \
93 B1 = __builtin_crypto_vncipherlast(B1, K); \
94 B2 = __builtin_crypto_vncipherlast(B2, K); \
95 B3 = __builtin_crypto_vncipherlast(B3, K); \
96 } while(0)
◆ AES_ENCRYPT_4
#define AES_ENCRYPT_4 |
( |
| B0, |
|
|
| B1, |
|
|
| B2, |
|
|
| B3, |
|
|
| K ) |
Value: do { \
B0 = __builtin_crypto_vcipher(B0, K); \
B1 = __builtin_crypto_vcipher(B1, K); \
B2 = __builtin_crypto_vcipher(B2, K); \
B3 = __builtin_crypto_vcipher(B3, K); \
} while(0)
Definition at line 66 of file aes_power8.cpp.
66#define AES_ENCRYPT_4(B0, B1, B2, B3, K) \
67 do { \
68 B0 = __builtin_crypto_vcipher(B0, K); \
69 B1 = __builtin_crypto_vcipher(B1, K); \
70 B2 = __builtin_crypto_vcipher(B2, K); \
71 B3 = __builtin_crypto_vcipher(B3, K); \
72 } while(0)
◆ AES_ENCRYPT_4_LAST
#define AES_ENCRYPT_4_LAST |
( |
| B0, |
|
|
| B1, |
|
|
| B2, |
|
|
| B3, |
|
|
| K ) |
Value: do { \
B0 = __builtin_crypto_vcipherlast(B0, K); \
B1 = __builtin_crypto_vcipherlast(B1, K); \
B2 = __builtin_crypto_vcipherlast(B2, K); \
B3 = __builtin_crypto_vcipherlast(B3, K); \
} while(0)
Definition at line 74 of file aes_power8.cpp.
74#define AES_ENCRYPT_4_LAST(B0, B1, B2, B3, K) \
75 do { \
76 B0 = __builtin_crypto_vcipherlast(B0, K); \
77 B1 = __builtin_crypto_vcipherlast(B1, K); \
78 B2 = __builtin_crypto_vcipherlast(B2, K); \
79 B3 = __builtin_crypto_vcipherlast(B3, K); \
80 } while(0)
◆ AES_XOR_4
#define AES_XOR_4 |
( |
| B0, |
|
|
| B1, |
|
|
| B2, |
|
|
| B3, |
|
|
| K ) |
Value: do { \
B0 = vec_xor(B0, K); \
B1 = vec_xor(B1, K); \
B2 = vec_xor(B2, K); \
B3 = vec_xor(B3, K); \
} while(0)
Definition at line 58 of file aes_power8.cpp.
58#define AES_XOR_4(B0, B1, B2, B3, K) \
59 do { \
60 B0 = vec_xor(B0, K); \
61 B1 = vec_xor(B1, K); \
62 B2 = vec_xor(B2, K); \
63 B3 = vec_xor(B3, K); \
64 } while(0)