Skip to content

Commit

Permalink
unit test fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
ladnir committed Apr 5, 2024
1 parent 987f05b commit 9b9db48
Show file tree
Hide file tree
Showing 5 changed files with 435 additions and 419 deletions.
4 changes: 2 additions & 2 deletions libOTe/Tools/ExConvCode/ExConvChecker.h
Original file line number Diff line number Diff line change
Expand Up @@ -254,8 +254,8 @@ namespace osuCrypto
// encode a batch of batchSize=1024 unit vectors...
encoder.template dualEncode<detail::GetGeneratorBatch, CoeffCtxGF2>(x.data(), {});

u64 mk = divCeil(min, 8);
auto i128 = i / 128;
//u64 mk = divCeil(min, 8);
//auto i128 = i / 128;

// x[j,p] is the (i+p)-th bit of the j-th codeword.
// We want g[j, i+p] = x[j,p]
Expand Down
12 changes: 8 additions & 4 deletions libOTe/Tools/Pprf/RegularPprf.h
Original file line number Diff line number Diff line change
Expand Up @@ -132,12 +132,14 @@ namespace osuCrypto
leafStepSize = u64{},
encOffset = u64{},
leafOffset = u64{},
min = u64{}
min = u64{},
dd = u64{}
);

setTimePoint("SilentMultiPprfSender.reserve");

pprf::allocateExpandTree(roundUpTo((mDomain + 1) / 2, 2), mTempBuffer, levels);
dd = mDomain > 2 ? roundUpTo((mDomain + 1) / 2, 2) : 1;
pprf::allocateExpandTree(dd, mTempBuffer, levels);
assert(levels.size() == mDepth);

if (!mEagerSend)
Expand Down Expand Up @@ -722,7 +724,8 @@ namespace osuCrypto
leafStepSize = u64{},
encOffset = u64{},
leafOffset = u64{},
min = u64{}
min = u64{},
dd = u64{}
);

setTimePoint("SilentMultiPprfReceiver.start");
Expand All @@ -731,7 +734,8 @@ namespace osuCrypto

//setTimePoint("SilentMultiPprfSender.reserve");

pprf::allocateExpandTree(roundUpTo((mDomain + 1) / 2, 2), mTempBuffer, levels);
dd = mDomain > 2 ? roundUpTo((mDomain + 1) / 2, 2) : 1;
pprf::allocateExpandTree(dd, mTempBuffer, levels);
assert(levels.size() == mDepth);


Expand Down
2 changes: 0 additions & 2 deletions libOTe/Tools/QuasiCyclicCode.h
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,6 @@ namespace osuCrypto

void init2(u64 messageSize, u64 codeSize)
{
auto scaler = divCeil(codeSize, messageSize);

mMessageSize = messageSize;
mPrimeModulus = nextPrime(messageSize);
mCodeSize = codeSize;
Expand Down
Loading

0 comments on commit 9b9db48

Please sign in to comment.