diff --git a/hpvm/projects/torch2hpvm/torch2hpvm/template_hpvm.cpp.in b/hpvm/projects/torch2hpvm/torch2hpvm/template_hpvm.cpp.in index fa252a3e0ce063697d56e771afbfbde69d0c5641..d74893984561297c9dc60d43a83d2c677885f87e 100644 --- a/hpvm/projects/torch2hpvm/torch2hpvm/template_hpvm.cpp.in +++ b/hpvm/projects/torch2hpvm/torch2hpvm/template_hpvm.cpp.in @@ -89,7 +89,7 @@ int main(int argc, char *argv[]){ __hpvm__init(); startMemTracking(); - #pragma clang loop unroll(disable) +#pragma clang loop unroll(disable) for (int i = 0; i < batch_count; i++){ int start = i * batch_size, end = start + batch_size; void *{{input_name}} = readInputBatch(input_path.c_str(), 0, start, end, {{input_shape|join(', ')}}); diff --git a/hpvm/projects/torch2hpvm/torch2hpvm/template_hpvm_inspect.cpp.in b/hpvm/projects/torch2hpvm/torch2hpvm/template_hpvm_inspect.cpp.in index 3d6ddd7c75b196e25aa732a733d9c4b1d789f1c8..7db01d87af8dbfb0341c77b3c471cfba3cc289c4 100644 --- a/hpvm/projects/torch2hpvm/torch2hpvm/template_hpvm_inspect.cpp.in +++ b/hpvm/projects/torch2hpvm/torch2hpvm/template_hpvm_inspect.cpp.in @@ -140,6 +140,7 @@ int main(){ // Keep this open so the other side knows we have more batches to write auto* fp = open_fifo("{{fifo_path_w}}", "wb"); float total_accuracy = 0; +#pragma clang loop unroll(disable) for (int i = 0; i < batch_count; i++){ int start = i * batch_size, end = start + batch_size; void *{{input_name}} = readInputBatch(input_pth, 0, start, end, {{input_shape|join(', ')}});