Commit 1cf11d7b authored by deshpande's avatar deshpande
Browse files

Made changes to possible problems in the code

parent f2c62fb3
Loading
Loading
Loading
Loading
+29 −0
Original line number Original line Diff line number Diff line
@@ -274,6 +274,35 @@ module LibCommon_Sync {
        f_serverWaitForAllClientsToStop();
        f_serverWaitForAllClientsToStop();
      }
      }


      /**
       * @desc   Implements synchronization of 4 clients from server side
       *         on one or more synchronization points.
       *         If problem occurs, then server sends STOP to all clients.
       *         Waits for PX_TSYNC_TIME_LIMIT to let clients
       *         finish executing their behavior until this
       *         synchronization point. After passing all synchronization
       *         points successfuly the server waits for all clients
       *         to stop.
       *         See f_serverSyncClientsTimed for overwriting this
       *         the timing constraint!
       *         This function sets the server component verdict.
       * @remark The use of this function requires prior connection  of
       *         the server sync ports!
       * @see    LibCommon_Sync.f_connect4SelfOrClientSync
       * @see    LibCommon_Sync.PX_TSYNC_TIME_LIMIT
       * @see    LibCommon_Sync.f_serverSyncClientsTimed
       * @see    LibCommon_Sync.f_serverWaitForAllClientsToStop
       * @param  p_syncPointIds list of synchronization point name/ids
       */
      function f_serverSync4ClientsAndStop( in SyncPointList p_syncPointIds )
      runs on ServerSyncComp {
        var integer i, v_noOfSyncIds := sizeof(p_syncPointIds);
        for ( i := 0; i < v_noOfSyncIds; i := i+1 ) {
          f_serverSyncClientsTimed(4,p_syncPointIds[i], PX_TSYNC_TIME_LIMIT);
        }
        f_serverWaitForAllClientsToStop();
      }

      /**
      /**
       * @desc   Implements synchronization of N clients from server side
       * @desc   Implements synchronization of N clients from server side
       *         on one or more synchronization points.
       *         on one or more synchronization points.