if (numSteadyPhases == 0) { ASSERT (nPhases == 0); return phase; }
    private PhasingSchedule getSJPhases(int nPhases, boolean isSplitter)    {        PhasingSchedule phase = new PhasingSchedule (stream);                int numSteadyPhases = (isSplitter ? stream.getNumSplitPhases() : stream.getNumJoinPhases());                // round up to a steady-state:        // if there aren't enough executions here to make it worth        // to do the smart compression, just append the lot        // of phases to the phase.        {            int mod = nPhases % numSteadyPhases;                        if (nPhases / numSteadyPhases < 4) mod = nPhases;                        nPhases -= mod;                        for(;mod > 0; mod--)            {                if (isSplitter){                    phase.appendPhase(getSplitSteadyPhase(0));                    advanceSplitSchedule(1);                } else {                    phase.appendPhase(getJoinSteadyPhase(0));                    advanceJoinSchedule(1);                }            }        }                // if I'm not actually adding more phases, quit early        if (nPhases == 0) return phase;                        // create a steady-state phase:        PhasingSchedule steadyState = new PhasingSchedule(stream);        for (int nPhase = 0; nPhase < numSteadyPhases;nPhase++)        {            if (isSplitter)            {                steadyState.appendPhase(getSplitSteadyPhase(nPhase));            } else{                steadyState.appendPhase(getJoinSteadyPhase(nPhase));            }        }                phase.appendPhase(duplicatePhase(steadyState, nPhases/numSteadyPhases));        if(isSplitter)        {            advanceSplitSchedule(nPhases);        } else {            advanceJoinSchedule(nPhases);        }                return phase;    }