diff --git a/mindspore/lite/nnacl/fp32/pack_fp32.c b/mindspore/lite/nnacl/fp32/pack_fp32.c index 69d3f6764d..4ccf3fe5ea 100644 --- a/mindspore/lite/nnacl/fp32/pack_fp32.c +++ b/mindspore/lite/nnacl/fp32/pack_fp32.c @@ -308,7 +308,7 @@ void PackNHWCToNCHWFp32(const void *src, void *dst, int batches, int plane, int return; } task_end = (task_id + 1) == thread_count ? plane : MSMIN(plane, task_start + offset_hw); - hw8 = task_start + (task_end - task_start) >= offset_hw ? offset_hw : 0; + hw8 = task_start + ((task_end - task_start) >= offset_hw ? offset_hw : 0); } else { hw8 *= C8NUM; }