git-diff-search selects the midpoint commit in the range of interest, and then restricts the further search to the half on the side of the midpoint that belongs to the better endpoint. However, nothing guarantees that the minimum will be on that side of the midpoint. A known bisecting minimisation algorithm is called 'golden-section-seach', it works as follows: Given three points [A,B,C] with known optimality values [x,y,z], where y is the best of the three, pick a new point D somewhere between B and the range end with the lower value; evaluate it's optimality. If it is better than B, B will be one of the new endpoints and D the new midpoint, otherwise vice versa. This way you guarantee to converge at least to a local minimum. Optimal performance is achieved when D is selected according to the golden section, with the smaller side towards B.
git-diff-searchselects the midpoint commit in the range of interest, and then restricts the further search to the half on the side of the midpoint that belongs to the better endpoint. However, nothing guarantees that the minimum will be on that side of the midpoint. A known bisecting minimisation algorithm is called 'golden-section-seach', it works as follows: Given three points[A,B,C]with known optimality values[x,y,z], whereyis the best of the three, pick a new pointDsomewhere betweenBand the range end with the lower value; evaluate it's optimality. If it is better thanB,Bwill be one of the new endpoints andDthe new midpoint, otherwise vice versa. This way you guarantee to converge at least to a local minimum. Optimal performance is achieved whenDis selected according to the golden section, with the smaller side towardsB.