-
Notifications
You must be signed in to change notification settings - Fork 48
Open
Description
Hi, the MPC compiler on the mpc_aws branch seems to have an issue with the modulo operation.
Here is an example:
int main() {
return (0-1) % 10;
}This returns 5.
It works as expected when using a secret input instead of 0-1:
int main(__attribute__(private(0)) int x) {
return x % 10;
}Compilation command:
export CARGO_MANIFEST_DIR="$PWD"; ./target/release/examples/circ --parties 2 examples/C/mpc/program.c mpc --cost-model "empirical" --selection-scheme css
Execution command:
/path/to/ABY/build/bin/aby_interpreter -m mpc -f ./scripts/aby_tests/tests/program_c -t ./scripts/aby_tests/test_inputs/program.txt -r 0 & /path/to/ABY/build/bin/aby_interpreter -m mpc -f ./scripts/aby_tests/tests/program_c -t ./scripts/aby_tests/test_inputs/program.txt -r 1
Thanks for looking into this!
Metadata
Metadata
Assignees
Labels
No labels