Pool<Nodeid> cacheRevs = new Pool<Nodeid>();
Pool<Path> cacheFiles = new Pool<Path>();
Internals implRepo = Internals.getInstance(repo);
final DirstateBuilder dirstateBuilder = new DirstateBuilder(implRepo);
dirstateBuilder.fillFrom(new DirstateReader(implRepo, new Path.SimpleSource(repo.getSessionContext().getPathFactory(), cacheFiles)));
final HgChangelog clog = repo.getChangelog();
final Nodeid headCset1 = clog.getRevision(firstCset);
dirstateBuilder.parents(headCset1, clog.getRevision(secondCset));
//
MergeStateBuilder mergeStateBuilder = new MergeStateBuilder(implRepo);