private static void performWork(String dataStructure, int nrThreads,
		    int nrItems, int workTime, long seed)
			throws InterruptedException {
		Sorted<Integer> sorted = null;
		if (dataStructure.equals(CGL)) {
			sorted = new CoarseGrainedList<Integer>();
		} else if (dataStructure.equals(CGT)) {
			sorted = new CoarseGrainedTree<Integer>();
		} else if (dataStructure.equals(FGL)) {
			sorted = new FineGrainedList<Integer>();
		} else if (dataStructure.equals(FGT)) {
			sorted = new FineGrainedTree<Integer>();
		} else if (dataStructure.equals(LFL)) {
			sorted = new LockFreeList<Integer>();
		} else if (dataStructure.equals(LFT)) {
			sorted = new LockFreeTree<Integer>();
		} else {
			exitWithError();
		}

		startThreads(sorted, nrThreads, nrItems, workTime, seed);
	}