mirror of
https://github.com/samsapti/bachelor-project.git
synced 2024-11-25 14:27:54 +00:00
Switch to mod 2^k domain and use encrypted channels
This commit is contained in:
parent
d970b4c35c
commit
e9bb4de556
1
src/CONFIG.mine
Normal file
1
src/CONFIG.mine
Normal file
|
@ -0,0 +1 @@
|
||||||
|
ARCH = -mtune=native -msse4.1 -msse4.2 -maes -mpclmul -mavx -mavx2 -mbmi2 -madx
|
13
src/Makefile
13
src/Makefile
|
@ -1,10 +1,10 @@
|
||||||
MP_SPDZ_PATH := $(CURDIR)/MP-SPDZ
|
MP_SPDZ_PATH := $(CURDIR)/MP-SPDZ
|
||||||
|
|
||||||
all: patch deps
|
all: config deps ssl
|
||||||
$(MAKE) -C $(MP_SPDZ_PATH) all
|
$(MAKE) -C $(MP_SPDZ_PATH) semi2k-party.x
|
||||||
|
|
||||||
patch:
|
config:
|
||||||
-git -C $(MP_SPDZ_PATH) apply $(CURDIR)/config.patch
|
cp -f $(CURDIR)/CONFIG.mine $(MP_SPDZ_PATH)/CONFIG.mine
|
||||||
|
|
||||||
deps: patch
|
deps: patch
|
||||||
sudo apt install automake build-essential clang cmake git libntl-dev \
|
sudo apt install automake build-essential clang cmake git libntl-dev \
|
||||||
|
@ -12,8 +12,11 @@ deps: patch
|
||||||
$(MAKE) -C $(MP_SPDZ_PATH) boost
|
$(MAKE) -C $(MP_SPDZ_PATH) boost
|
||||||
$(MAKE) -C $(MP_SPDZ_PATH) libote mpir
|
$(MAKE) -C $(MP_SPDZ_PATH) libote mpir
|
||||||
|
|
||||||
|
ssl:
|
||||||
|
cd $(MP_SPDZ_PATH) && Scripts/setup-ssl.sh 3
|
||||||
|
|
||||||
%.mpc: _phony
|
%.mpc: _phony
|
||||||
python3 $(MP_SPDZ_PATH)/compile.py $@
|
python3 $(MP_SPDZ_PATH)/compile.py -R 64 $@
|
||||||
|
|
||||||
%:
|
%:
|
||||||
$(MAKE) -C $(MP_SPDZ_PATH) $@
|
$(MAKE) -C $(MP_SPDZ_PATH) $@
|
||||||
|
|
|
@ -1,12 +0,0 @@
|
||||||
diff --git a/CONFIG b/CONFIG
|
|
||||||
index 6d5f0f17..217471f7 100644
|
|
||||||
--- a/CONFIG
|
|
||||||
+++ b/CONFIG
|
|
||||||
@@ -28,7 +28,6 @@ USE_GF2N_LONG = 1
|
|
||||||
# ADX is used to optimize big integer additions
|
|
||||||
# delete the second line to compile for a platform that supports everything
|
|
||||||
ARCH = -mtune=native -msse4.1 -msse4.2 -maes -mpclmul -mavx -mavx2 -mbmi2 -madx
|
|
||||||
-ARCH = -march=native
|
|
||||||
|
|
||||||
MACHINE := $(shell uname -m)
|
|
||||||
ARM := $(shell uname -m | grep x86; echo $$?)
|
|
|
@ -9,9 +9,6 @@ from Compiler.oram import OptimalORAM
|
||||||
from Compiler.library import for_range, do_while, time, if_, print_ln, crash, print_str, break_loop
|
from Compiler.library import for_range, do_while, time, if_, print_ln, crash, print_str, break_loop
|
||||||
from Compiler.gs import OMatrix, OStack
|
from Compiler.gs import OMatrix, OStack
|
||||||
|
|
||||||
# Optimizations
|
|
||||||
program.use_edabit(True)
|
|
||||||
|
|
||||||
|
|
||||||
class Matchmaker:
|
class Matchmaker:
|
||||||
"""
|
"""
|
||||||
|
|
|
@ -8,5 +8,5 @@ if [[ $1 == "-k" ]]; then
|
||||||
fi
|
fi
|
||||||
|
|
||||||
for i in $(seq 0 2); do
|
for i in $(seq 0 2); do
|
||||||
./semi-party.x -N 3 -p "$i" gale_shapley > "../out-p$i.txt" 2>&1 &
|
./semi2k-party.x -N 3 -p "$i" -e gale_shapley > "../out-p$i.txt" 2>&1 &
|
||||||
done
|
done
|
||||||
|
|
Loading…
Reference in a new issue