Merge pull request #42032 from kitstar:master

PiperOrigin-RevId: 327036995
Change-Id: I974887aea30cf656b9fbb26a06aa14cc3edc608e
This commit is contained in:
TensorFlower Gardener 2020-08-17 09:50:02 -07:00
commit 48ee9cdb66

View File

@ -425,7 +425,7 @@ void AdaptiveSharedBatchScheduler<TaskType>::MaybeScheduleNextBatch() {
return;
}
auto best_it = batches_.end();
double best_score;
double best_score = (std::numeric_limits<double>::max)();
int64 now_micros = GetEnv()->NowMicros();
for (auto it = batches_.begin(); it != batches_.end(); it++) {
if ((*it)->schedulable_time_micros() > now_micros) continue;