summaryrefslogtreecommitdiffstats
path: root/crypto/bn/bn_lcl.h
diff options
context:
space:
mode:
authorGeoff Thorpe <geoff@openssl.org>2003-12-01 22:11:08 +0000
committerGeoff Thorpe <geoff@openssl.org>2003-12-01 22:11:08 +0000
commit998ae048e74bb7a58eccae30e548b8acfe092925 (patch)
tree2813d5b2b433c6ee2ab2f3f3a15709e24b3d4943 /crypto/bn/bn_lcl.h
parente65c2b9872d52e130e848ac0e9007878f1fb6c78 (diff)
The bn_set_max() macro is only "used" by the bn_set_[low|high]() macros
which, in turn, are used nowhere at all. This is a good thing because bn_set_max() would currently generate code that wouldn't compile (BIGNUM has no 'max' element). The only apparent use for bn_set_[low|high] would be for implementing windowing algorithms, and all of openssl's seem to use bn_***_words() helpers instead (including the BN_div() that Nils fixed recently, which had been using independently-coded versions of what these unused macros are intended for). I'm therefore consigning these macros to cvs oblivion in the name of readability.
Diffstat (limited to 'crypto/bn/bn_lcl.h')
-rw-r--r--crypto/bn/bn_lcl.h32
1 files changed, 0 insertions, 32 deletions
diff --git a/crypto/bn/bn_lcl.h b/crypto/bn/bn_lcl.h
index 4603b4f9f1..18960f191b 100644
--- a/crypto/bn/bn_lcl.h
+++ b/crypto/bn/bn_lcl.h
@@ -249,38 +249,6 @@ extern "C" {
*(++ftl) = 0x0; \
}
-
-/* This macro is to add extra stuff for development checking */
-#ifdef BN_DEBUG
-#define bn_set_max(r) ((r)->max=(r)->top,BN_set_flags((r),BN_FLG_STATIC_DATA))
-#else
-#define bn_set_max(r)
-#endif
-
-/* These macros are used to 'take' a section of a bignum for read only use */
-#define bn_set_low(r,a,n) \
- { \
- (r)->top=((a)->top > (n))?(n):(a)->top; \
- (r)->d=(a)->d; \
- (r)->neg=(a)->neg; \
- (r)->flags|=BN_FLG_STATIC_DATA; \
- bn_set_max(r); \
- }
-
-#define bn_set_high(r,a,n) \
- { \
- if ((a)->top > (n)) \
- { \
- (r)->top=(a)->top-n; \
- (r)->d= &((a)->d[n]); \
- } \
- else \
- (r)->top=0; \
- (r)->neg=(a)->neg; \
- (r)->flags|=BN_FLG_STATIC_DATA; \
- bn_set_max(r); \
- }
-
#ifdef BN_LLONG
#define mul_add(r,a,w,c) { \
BN_ULLONG t; \