Improve efficiency of logical fixes

This improves performance by an order of complexity. Rather than doing one
logical fix per pass, we apply all fixes that do not overlap per pass.

This is related to #101.