SHAMap performance (RIPD-434)

Commit from previous pull request with updates thanks to suggestions given in that pull requests. Updates and bugfixes to address the missing node bugs:

More separation between snapshot unsharing logic and modified node flushing logic.

Simplify descend* functions so that they no longer modify SHAMapNodeIDs. (They were too tricky to use because it wasn't clear which functions modified SHAMapNodeIDs and whether you were supposed to pass the parent or child ID.0


This comment really applies to the whole file.  Since this is an "Imp" class in a cpp file, I'm assuming that it overrides a lot of virtual methods.  It would be nice if the overridden methods were annotated with (I'm guessing) final.  That may make maintenance easier in the future.  Thanks.