First attempt at upgrading branch to the head of the trunk. This should include all of the simplification branch from the merge in Dec 2015.