Skip to content

Commit 1ea910e

Browse files
committed
cryptoTools bump
1 parent 3fd504d commit 1ea910e

File tree

5 files changed

+22
-27
lines changed

5 files changed

+22
-27
lines changed

CMakePresets.json

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,11 @@
99
"binaryDir": "${sourceDir}/out/build/${presetName}",
1010
"cacheVariables": {
1111
"CMAKE_BUILD_TYPE": "Debug",
12+
"FETCH_AUTO": true,
1213
"ENABLE_ALL_OT": true,
1314
"ENABLE_SSE": false,
14-
"ENABLE_AVX": false,
1515
"ENABLE_BITPOLYMUL": false,
16+
"ENABLE_CIRCUITS": true,
1617
"LIBOTE_STD_VER": "17",
1718
"CMAKE_PREFIX_PATH": "${sourceDir}/../out/install",
1819
"CMAKE_INSTALL_PREFIX": "${sourceDir}/out/install/${presetName}"
@@ -71,16 +72,16 @@
7172
"cacheVariables": {
7273
"CMAKE_BUILD_TYPE": "RelWithDebInfo",
7374
"LIBOTE_STD_VER": "17",
74-
"ENABLE_ALL_OT": true,
75-
"ENABLE_RELIC": true,
76-
"ENABLE_SODIUM": true,
77-
"ENABLE_BOOST": true,
75+
"ENABLE_ALL_OT": false,
76+
"ENABLE_RELIC": false,
77+
"ENABLE_SODIUM": false,
78+
"ENABLE_BOOST": false,
7879
"ENABLE_OPENSSL": false,
7980
"FETCH_AUTO": true,
8081
"ENABLE_CIRCUITS": true,
81-
"ENABLE_BITPOLYMUL": true,
82+
"ENABLE_BITPOLYMUL": false,
8283
"VERBOSE_FETCH": true,
83-
"ENABLE_PIC": true,
84+
"ENABLE_PIC": false,
8485
"ENABLE_ASAN": false,
8586
"CMAKE_INSTALL_PREFIX": "${sourceDir}/out/install/${presetName}"
8687
},

frontend/benchmark.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ namespace osuCrypto
1818
inline void QCCodeBench(CLP& cmd)
1919
{
2020

21+
#ifdef ENABLE_BITPOLYMUL
2122
u64 trials = cmd.getOr("t", 10);
2223

2324
// the message length of the code.
@@ -34,7 +35,6 @@ namespace osuCrypto
3435
// verbose flag.
3536

3637

37-
#ifdef ENABLE_BITPOLYMUL
3838
oc::Timer timer;
3939
QuasiCyclicCode code;
4040
auto p = nextPrime(n);
@@ -231,8 +231,8 @@ namespace osuCrypto
231231

232232
inline void transpose(const CLP& cmd)
233233
{
234-
u64 trials = cmd.getOr("trials", 1ull << 18);
235234
#ifdef ENABLE_AVX
235+
u64 trials = cmd.getOr("trials", 1ull << 18);
236236
{
237237

238238

libOTe/Tools/LinearCode.cpp

Lines changed: 10 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -456,14 +456,7 @@ namespace osuCrypto
456456
// create a local to store the partial codeword
457457
// and zero it out.
458458
block c[8];
459-
c[0] = c[0] ^ c[0];
460-
c[1] = c[1] ^ c[1];
461-
c[2] = c[2] ^ c[2];
462-
c[3] = c[3] ^ c[3];
463-
c[4] = c[4] ^ c[4];
464-
c[5] = c[5] ^ c[5];
465-
c[6] = c[6] ^ c[6];
466-
c[7] = c[7] ^ c[7];
459+
memset(c, 0, sizeof(block) * 8);
467460

468461
// for performance reasons, we have multiplt implementations, one for
469462
// each size under 9 blocks wide. There is a general case at the end.
@@ -729,14 +722,15 @@ namespace osuCrypto
729722
// create a local to store the partial codeword
730723
// and zero it out.
731724
block c[8];
732-
c[0] = c[0] ^ c[0];
733-
c[1] = c[1] ^ c[1];
734-
c[2] = c[2] ^ c[2];
735-
c[3] = c[3] ^ c[3];
736-
c[4] = c[4] ^ c[4];
737-
c[5] = c[5] ^ c[5];
738-
c[6] = c[6] ^ c[6];
739-
c[7] = c[7] ^ c[7];
725+
memset(c, 0, sizeof(block) * 8);
726+
//c[0] = c[0] ^ c[0];
727+
//c[1] = c[1] ^ c[1];
728+
//c[2] = c[2] ^ c[2];
729+
//c[3] = c[3] ^ c[3];
730+
//c[4] = c[4] ^ c[4];
731+
//c[5] = c[5] ^ c[5];
732+
//c[6] = c[6] ^ c[6];
733+
//c[7] = c[7] ^ c[7];
740734

741735
block* g0 = mG8.data() + 0 * rowSize + input[0] * codeSize;
742736
block* g1 = mG8.data() + 1 * rowSize + input[1] * codeSize;

thirdparty/SimplestOT/gfe4x.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,7 @@ void gfe4x_unpack_single(gfe4x *r, const unsigned char * x, int i)
147147
r->v[11].v[i] = r->v[11].v[i] + _2_234 - _2_255;
148148
}
149149

150-
void gfe4x_unpack(gfe4x *r, const unsigned char x[128])
150+
void gfe4x_unpack(gfe4x *r, const unsigned char* x)
151151
{
152152
gfe4x_unpack_single(r, x, 0);
153153
gfe4x_unpack_single(r, x, 1);

0 commit comments

Comments
 (0)