more checks and better usage of tile sizes