MCPcopy Create free account
hub / github.com/Gecode/gecode / ExecStatus edgefinding

Function ExecStatus edgefinding

gecode/int/unary/edge-finding.hpp:39–61  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

37
38 template<class TaskView>
39 forceinline ExecStatus
40 edgefinding(Space& home, TaskViewArray<TaskView>& t) {
41 Region r;
42
43 OmegaLambdaTree<TaskView> ol(r,t);
44 TaskViewIter<TaskView,STO_LCT,false> q(r,t);
45
46 int j = q.task();
47 while (q.left() > 1) {
48 if (ol.ect() > t[j].lct())
49 return ES_FAILED;
50 ol.shift(j);
51 ++q;
52 j = q.task();
53 while (!ol.lempty() && (ol.lect() > t[j].lct())) {
54 int i = ol.responsible();
55 GECODE_ME_CHECK(t[i].est(home,ol.ect()));
56 ol.lremove(i);
57 }
58 }
59
60 return ES_OK;
61 }
62
63 template<class Task>
64 ExecStatus

Callers

nothing calls this directly

Calls 10

taskMethod · 0.80
lectMethod · 0.80
leftMethod · 0.45
ectMethod · 0.45
lctMethod · 0.45
shiftMethod · 0.45
lemptyMethod · 0.45
responsibleMethod · 0.45
estMethod · 0.45
lremoveMethod · 0.45

Tested by

no test coverage detected