diff --git a/src/executor/graph_executor.cc b/src/executor/graph_executor.cc index 7386de4d12e3..33c6f574a044 100644 --- a/src/executor/graph_executor.cc +++ b/src/executor/graph_executor.cc @@ -1282,7 +1282,7 @@ void GraphExecutor::InitDataEntryMemory(std::vector* shared_pool) { for (size_t i = 0; i < pool_info.size(); i++) { sorted_pool_index.push_back(i); } - auto pool_comparator = [&pool_info](int lhs, int rhs){ + auto pool_comparator = [&pool_info](size_t lhs, size_t rhs){ return pool_info[lhs].bytes > pool_info[rhs].bytes; }; std::sort(sorted_pool_index.begin(), sorted_pool_index.end(), pool_comparator);