diff --git a/mshadow/tensor_cpu-inl.h b/mshadow/tensor_cpu-inl.h index 46baf0fc32dd..4f8b472a9f57 100644 --- a/mshadow/tensor_cpu-inl.h +++ b/mshadow/tensor_cpu-inl.h @@ -140,7 +140,8 @@ inline void MapPlan(TRValue *dst, const expr::Plan &plan) { Shape<2> shape = expr::ShapeCheck::Check(dst->self()).FlatTo2D(); expr::Plan dplan = expr::MakePlan(dst->self()); - for (index_t y = 0; y < shape[0]; ++y) { + #pragma omp parallel for + for (int y = 0; y < shape[0]; ++y) { for (index_t x = 0; x < shape[1]; ++x) { // trust your compiler! -_- they will optimize it Saver::Save(dplan.REval(y, x), plan.Eval(y, x));