Optimize TestFreeRow

This commit has not fully tested yet. If you experience problems, please submit an issue.