Some refactoring, starting to build region coverage