aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorlloyd <[email protected]>2008-09-14 17:27:20 +0000
committerlloyd <[email protected]>2008-09-14 17:27:20 +0000
commit25ba9a0d49922338e5ebb7afb737ac3dbe67b4dd (patch)
treec71684ce697c71eca49b91e877762b10a8bc3268 /src
parent6a16f4855a1645a0cbb677c6a6a9188f5dcc648b (diff)
Rename blocks to the slightly more descriptive x_size_8
Diffstat (limited to 'src')
-rw-r--r--src/mp_mulop.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/mp_mulop.cpp b/src/mp_mulop.cpp
index cb17d5e16..3ab28d306 100644
--- a/src/mp_mulop.cpp
+++ b/src/mp_mulop.cpp
@@ -18,7 +18,7 @@ extern "C" {
void bigint_simple_mul(word z[], const word x[], u32bit x_size,
const word y[], u32bit y_size)
{
- const u32bit blocks = x_size - (x_size % 8);
+ const u32bit x_size_8 = x_size - (x_size % 8);
clear_mem(z, x_size + y_size);
@@ -28,10 +28,10 @@ void bigint_simple_mul(word z[], const word x[], u32bit x_size,
word carry = 0;
- for(u32bit j = 0; j != blocks; j += 8)
+ for(u32bit j = 0; j != x_size_8; j += 8)
carry = word8_madd3(z + i + j, x + j, y_i, carry);
- for(u32bit j = blocks; j != x_size; ++j)
+ for(u32bit j = x_size_8; j != x_size; ++j)
z[i+j] = word_madd3(x[j], y_i, z[i+j], &carry);
z[x_size+i] = carry;
@@ -48,7 +48,7 @@ that x == y
*************************************************/
void bigint_simple_sqr(word z[], const word x[], u32bit x_size)
{
- const u32bit blocks = x_size - (x_size % 8);
+ const u32bit x_size_8 = x_size - (x_size % 8);
clear_mem(z, 2*x_size);
@@ -57,10 +57,10 @@ void bigint_simple_sqr(word z[], const word x[], u32bit x_size)
const word x_i = x[i];
word carry = 0;
- for(u32bit j = 0; j != blocks; j += 8)
+ for(u32bit j = 0; j != x_size_8; j += 8)
carry = word8_madd3(z + i + j, x + j, x_i, carry);
- for(u32bit j = blocks; j != x_size; ++j)
+ for(u32bit j = x_size_8; j != x_size; ++j)
z[i+j] = word_madd3(x[j], x_i, z[i+j], &carry);
z[x_size+i] = carry;