Clarify comments about use of rzr on ge functions and abs function.

This commit is contained in:
Gregory Maxwell
2020-01-09 13:07:36 +00:00
parent 2241ae6d14
commit d567b779fe
2 changed files with 4 additions and 3 deletions

View File

@@ -15,6 +15,7 @@
/* This is like `ECMULT_TABLE_GET_GE` but is constant time */
#define ECMULT_CONST_TABLE_GET_GE(r,pre,n,w) do { \
int m; \
/* Extract the sign-bit for a constant time absolute-value. */ \
int mask = (n) >> (sizeof(n) * CHAR_BIT - 1); \
int abs_n = ((n) + mask) ^ mask; \
int idx_n = abs_n >> 1; \