33 #include <libff/common/profiling.hpp> 
   34 #include <libff/common/utils.hpp> 
   41 int main(
int argc, 
const char *argv[])
 
   43     default_r1cs_se_ppzksnark_pp::init_public_params();
 
   44     libff::start_profiling();
 
   46     if (argc == 2 && strcmp(argv[1], 
"-v") == 0) {
 
   47         libff::print_compilation_info();
 
   51     if (argc != 3 && argc != 4) {
 
   52         printf(
"usage: %s num_constraints input_size [Fr|bytes]\n", argv[0]);
 
   55     const int num_constraints = atoi(argv[1]);
 
   56     int input_size = atoi(argv[2]);
 
   58         assert(strcmp(argv[3], 
"Fr") == 0 || strcmp(argv[3], 
"bytes") == 0);
 
   59         if (strcmp(argv[3], 
"bytes") == 0) {
 
   60             input_size = libff::div_ceil(
 
   61                 8 * input_size, libff::Fr<libff::default_ec_pp>::capacity());
 
   65     libff::enter_block(
"Generate R1CS example");
 
   68             libff::Fr<default_r1cs_se_ppzksnark_pp>>(
 
   69             num_constraints, input_size);
 
   70     libff::leave_block(
"Generate R1CS example");
 
   72     libff::print_header(
"(enter) Profile R1CS SEppzkSNARK");
 
   73     const bool test_serialization = 
true;
 
   74     run_r1cs_se_ppzksnark<default_r1cs_se_ppzksnark_pp>(
 
   75         example, test_serialization);
 
   76     libff::print_header(
"(leave) Profile R1CS SEppzkSNARK");