Changeset 3232 in MondoRescue for branches/3.2/mindi-busybox/libbb/hash_md5prime.c
- Timestamp:
- Jan 1, 2014, 12:47:38 AM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/3.2/mindi-busybox/libbb/hash_md5prime.c
r2725 r3232 60 60 * 61 61 * Reintroduced the loop unrolling in md5_transform and added the 62 * MD5_S IZE_VS_SPEEDoption for configurability. Define below as:62 * MD5_SMALL option for configurability. Define below as: 63 63 * 0 fully unrolled loops 64 64 * 1 partially unrolled (4 ops per loop) … … 76 76 77 77 /* 1: fastest, 3: smallest */ 78 #if CONFIG_MD5_S IZE_VS_SPEED< 179 # define MD5_S IZE_VS_SPEED180 #elif CONFIG_MD5_S IZE_VS_SPEED> 381 # define MD5_S IZE_VS_SPEED378 #if CONFIG_MD5_SMALL < 1 79 # define MD5_SMALL 1 80 #elif CONFIG_MD5_SMALL > 3 81 # define MD5_SMALL 3 82 82 #else 83 # define MD5_S IZE_VS_SPEED CONFIG_MD5_SIZE_VS_SPEED83 # define MD5_SMALL CONFIG_MD5_SMALL 84 84 #endif 85 85 … … 153 153 { 154 154 uint32_t a, b, c, d, x[16]; 155 #if MD5_S IZE_VS_SPEED> 1155 #if MD5_SMALL > 1 156 156 uint32_t temp; 157 157 const unsigned char *ps; … … 163 163 6, 10, 15, 21 164 164 }; 165 #endif /* MD5_S IZE_VS_SPEED> 1 */166 167 #if MD5_S IZE_VS_SPEED> 0165 #endif /* MD5_SMALL > 1 */ 166 167 #if MD5_SMALL > 0 168 168 const uint32_t *pc; 169 169 const unsigned char *pp; … … 199 199 }; 200 200 201 #endif /* MD5_S IZE_VS_SPEED> 0 */201 #endif /* MD5_SMALL > 0 */ 202 202 203 203 memcpy32_le2cpu(x, block, 64); … … 208 208 d = state[3]; 209 209 210 #if MD5_S IZE_VS_SPEED> 2210 #if MD5_SMALL > 2 211 211 pc = C; 212 212 pp = P; … … 234 234 a = d; d = c; c = b; b = temp; 235 235 } 236 #elif MD5_S IZE_VS_SPEED> 1236 #elif MD5_SMALL > 1 237 237 pc = C; 238 238 pp = P; … … 261 261 temp = d; d = c; c = b; b = a; a = temp; 262 262 } 263 #elif MD5_S IZE_VS_SPEED> 0263 #elif MD5_SMALL > 0 264 264 pc = C; 265 265 pp = P;
Note:
See TracChangeset
for help on using the changeset viewer.