Commit 3e02b091 authored by Jack Doerner's avatar Jack Doerner

Minor cleanings

parent 169bbd89
......@@ -2,20 +2,9 @@
#include <omp.h>
#include <openssl/conf.h>
#include <openssl/evp.h>
#include <openssl/err.h>
#include <wmmintrin.h>
#include <tmmintrin.h>
// gcc -c -O3 -maes -I/usr/include -I . -I ../../src/ -std=c99 -fopenmp floram_util.c -o floram_util.o -I ../ext/oblivc
static int sslinits = 0;
static void* sslzero;
static omp_lock_t * ssllocks;
void get_random_bytes(void *buf, size_t bytes) {
//only supported on recent linuxes, unfortunately.
//getrandom(buf, bytes, 0);
......@@ -60,19 +49,6 @@ void openmp_thread_cleanup(void) {
//OPENSSL_free(ssllocks);
}
void network_parallelizer(generic_function fn1, generic_function fn2, void* data1, void* data2) {
//#pragma omp sections
{
//#pragma omp section
fn1(data1);
//#pragma omp section
fn2(data2);
}
}
void offline_expand_init() {
/*if (sslinits == 0) {
openmp_thread_setup();
......
......@@ -17,9 +17,6 @@
void get_random_bytes(void *buf, size_t bytes);
int floram_pma(void** dst, size_t alignment, size_t size);
typedef void (* generic_function)(void *);
void network_parallelizer(generic_function fn1, generic_function fn2, void* data1, void* data2);
void offline_expand_init();
void offline_expand_deinit();
void offline_expand(uint8_t * dest, uint8_t * src, size_t n);
......
......@@ -47,7 +47,6 @@ void scanrom_encrypt_offline(uint8_t * out, uint8_t * in, uint8_t* key, size_t i
}
}
free(kex);
}
......
......@@ -77,6 +77,8 @@ void test_main(void*varg) {
oram_set_default_type(ORAM_TYPE_LINEAR);
} else if (strcmp(optarg,"fssl") == 0) {
oram_set_default_type(ORAM_TYPE_FSSL);
} else if (strcmp(optarg,"fssl_cprg") == 0) {
oram_set_default_type(ORAM_TYPE_FSSL_CPRG);
} else {
fprintf (stderr, "Invalid argument for -%c.\n", arg);
return;
......
......@@ -80,6 +80,8 @@ void test_main(void*varg) {
oram_set_default_type(ORAM_TYPE_LINEAR);
} else if (strcmp(optarg,"fssl") == 0) {
oram_set_default_type(ORAM_TYPE_FSSL);
} else if (strcmp(optarg,"fssl_cprg") == 0) {
oram_set_default_type(ORAM_TYPE_FSSL_CPRG);
} else {
fprintf (stderr, "Invalid argument for -%c.\n", arg);
return;
......
......@@ -49,6 +49,8 @@ void test_main(void*varg) {
oram_set_default_type(ORAM_TYPE_LINEAR);
} else if (strcmp(optarg,"fssl") == 0) {
oram_set_default_type(ORAM_TYPE_FSSL);
} else if (strcmp(optarg,"fssl_cprg") == 0) {
oram_set_default_type(ORAM_TYPE_FSSL_CPRG);
} else {
fprintf (stderr, "Invalid argument for -%c.\n", arg);
return;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment