Suitable asymmetric microstructures can be used to control the direction of motion in microorganism populations. This rectification process makes it possible to accumulate swimmers in a region of space or to sort different swimmers. Here we study numerically how the separation process depends on the specific motility strategies of the microorganisms involved. Crucial properties such as the separation efficiency and the separation time for two bacterial strains are precisely defined and evaluated. In particular, the sorting of two bacterial populations inoculated in a box consisting of a series of chambers separated by columns of asymmetric obstacles is investigated. We show how the sorting efficiency is enhanced by these obstacles and conclude that this kind of sorting can be efficiently used even when the involved populations differ only in one aspect of their swimming strategy.