Example #1
0
 double FMLPAnalysis::holding_time(const TaskRes &task, const CriticalSection &req)
 {
     // of course, req must be a long resource
     double tot = req.get_duration();
     CSSet work = short_outermost_cs(req.begin(), req.end());
     for (auto cs : work) {
         Resource r = get_res(req.get_resource());
         tot += compute_spin(task, r);
     } 
     return tot;
 }