From 13ecebf7d6c58d65f6df008731bbb41f4c2be2f6 Mon Sep 17 00:00:00 2001 From: jsing <> Date: Thu, 10 Aug 2023 07:15:23 +0000 Subject: Remove MD32_REG_T. This is a hack that is only enabled on a handful of 64 bit platforms, as a workaround for poor compiler optimisation. If you're running an archiac compiler on an archiac architecture, then you can deal with slightly lower performance. ok tb@ --- src/lib/libcrypto/sha/sha1.c | 6 +++--- src/lib/libcrypto/sha/sha256.c | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) (limited to 'src/lib/libcrypto/sha') diff --git a/src/lib/libcrypto/sha/sha1.c b/src/lib/libcrypto/sha/sha1.c index 6e35d797b5..4b48653bdb 100644 --- a/src/lib/libcrypto/sha/sha1.c +++ b/src/lib/libcrypto/sha/sha1.c @@ -1,4 +1,4 @@ -/* $OpenBSD: sha1.c,v 1.11 2023/07/08 12:24:10 beck Exp $ */ +/* $OpenBSD: sha1.c,v 1.12 2023/08/10 07:15:23 jsing Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -141,8 +141,8 @@ static void sha1_block_data_order(SHA_CTX *c, const void *p, size_t num) { const unsigned char *data = p; - unsigned MD32_REG_T A, B, C, D, E, T, l; - unsigned MD32_REG_T X0, X1, X2, X3, X4, X5, X6, X7, + unsigned int A, B, C, D, E, T, l; + unsigned int X0, X1, X2, X3, X4, X5, X6, X7, X8, X9, X10, X11, X12, X13, X14, X15; A = c->h0; diff --git a/src/lib/libcrypto/sha/sha256.c b/src/lib/libcrypto/sha/sha256.c index 0d0c4231ef..231a5a058c 100644 --- a/src/lib/libcrypto/sha/sha256.c +++ b/src/lib/libcrypto/sha/sha256.c @@ -1,4 +1,4 @@ -/* $OpenBSD: sha256.c,v 1.27 2023/07/08 12:24:10 beck Exp $ */ +/* $OpenBSD: sha256.c,v 1.28 2023/08/10 07:15:23 jsing Exp $ */ /* ==================================================================== * Copyright (c) 1998-2011 The OpenSSL Project. All rights reserved. * @@ -135,7 +135,7 @@ sha256_block_data_order(SHA256_CTX *ctx, const void *_in, size_t num) { const uint8_t *in = _in; const SHA_LONG *in32; - unsigned MD32_REG_T a, b, c, d, e, f, g, h, s0, s1, T1; + unsigned int a, b, c, d, e, f, g, h, s0, s1, T1; SHA_LONG X[16]; int i; -- cgit v1.2.3-55-g6feb