presto-main/src/main/java/io/prestosql/execution/SqlTaskExecution.java/SqlTaskExecution/removeAllSplits
class SqlTaskExecution:        public Set<ScheduledSplit> removeAllSplits()
        {
            checkState(state == ADDING_SPLITS || state == NO_MORE_SPLITS);
            Set<ScheduledSplit> result = splits;
            splits = new HashSet<>();
            return result;
        }