diff --git a/Programs/Source/test_permute.mpc b/Programs/Source/test_permute.mpc index 40ee6a4a..cdb79a34 100644 --- a/Programs/Source/test_permute.mpc +++ b/Programs/Source/test_permute.mpc @@ -140,7 +140,6 @@ def test_permute_matrix(timer_base: int, value_type=sint) -> None: p1 = sint.get_secure_shuffle(5) p2 = sint.get_secure_shuffle(5) - start_timer(timer_base + 1) m1.secure_permute(p1, n_parallel=1) stop_timer(timer_base + 1) @@ -164,13 +163,13 @@ def test_permute_matrix(timer_base: int, value_type=sint) -> None: print_ln("%s", row) test_permuted_matrix(m2, p2) -# test_allocator() -# test_case([5,10], 10) -# test_case([5, 10, 15, 20], 20) -# test_case([4,8,16], 30) -# test_case([5], 40) -# -# test_parallel_permutation_equals_sequential_permutation([5,10],50) -# -# test_permute_matrix(60) -# test_permute_matrix(70, value_type=sfix) \ No newline at end of file +test_allocator() +test_case([5,10], 10) +test_case([5, 10, 15, 20], 20) +test_case([4,8,16], 30) +test_case([5], 40) + +test_parallel_permutation_equals_sequential_permutation([5,10],50) + +test_permute_matrix(60) +test_permute_matrix(70, value_type=sfix) \ No newline at end of file diff --git a/Programs/Source/test_print.mpc b/Programs/Source/test_print.mpc new file mode 100644 index 00000000..310845b5 --- /dev/null +++ b/Programs/Source/test_print.mpc @@ -0,0 +1 @@ +print_ln("%s", cfix(0)) \ No newline at end of file diff --git a/Protocols/Rep3Shuffler.hpp b/Protocols/Rep3Shuffler.hpp index f8bc7efc..b9a7cc95 100644 --- a/Protocols/Rep3Shuffler.hpp +++ b/Protocols/Rep3Shuffler.hpp @@ -59,7 +59,7 @@ void Rep3Shuffler::apply(StackedVector& a, size_t n, int unit_size, } template -void Rep3Shuffler::applyMultiple(vector& a, vector& sizes, vector& destinations, vector& sources, +void Rep3Shuffler::applyMultiple(StackedVector& a, vector& sizes, vector& destinations, vector& sources, vector& unit_sizes, vector& handles, vector& reverses, store_type& store) { vector shuffles; for (size_t &handle : handles) { @@ -71,7 +71,7 @@ void Rep3Shuffler::applyMultiple(vector& a, vector& sizes, vector< } template -void Rep3Shuffler::applyMultiple(vector &a, vector &sizes, vector &destinations, +void Rep3Shuffler::applyMultiple(StackedVector &a, vector &sizes, vector &destinations, vector &sources, vector &unit_sizes, vector &shuffles, vector &reverses) { const auto n_shuffles = sizes.size(); diff --git a/Protocols/SecureShuffle.h b/Protocols/SecureShuffle.h index 74c6115a..5a656e80 100644 --- a/Protocols/SecureShuffle.h +++ b/Protocols/SecureShuffle.h @@ -79,8 +79,8 @@ private: void pre(StackedVector& a, size_t n, size_t input_base); void post(StackedVector& a, size_t n, size_t input_base); - vector> waksman_round_init(StackedVector& toShuffle, size_t shuffle_unit_size, int depth, vector>& iter_waksman_config, bool inwards, bool reverse); - void waksman_round_finish(StackedVector& toShuffle, size_t unit_size, vector> indices); + vector> waksman_round_init(vector& toShuffle, size_t shuffle_unit_size, int depth, vector>& iter_waksman_config, bool inwards, bool reverse); + void waksman_round_finish(vector& toShuffle, size_t unit_size, vector> indices); public: map stats;