We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 75d10ed commit 8f2433dCopy full SHA for 8f2433d
ortools/sat/subsolver.h
@@ -101,11 +101,12 @@ class SubSolver {
101
// called sequentially. Subclasses do not need to call this.
102
void AddTaskDuration(double duration_in_seconds) {
103
++num_finished_tasks_;
104
- wall_time_ += duration_in_seconds;
105
- timing_.AddTimeInSec(duration_in_seconds);
+ if (duration_in_seconds > 0) {
+ wall_time_ += duration_in_seconds;
106
+ timing_.AddTimeInSec(duration_in_seconds);
107
+ }
108
}
109
- // Note that this is protected by the global execution mutex and so it is
110
111
void NotifySelection() { ++num_scheduled_tasks_; }
112
0 commit comments