In this illustration, we have a sailboat race with a start line that starts out square, but then there is a shift in the wind. This changes what would normally be a square situation to one that now creates a shorter overall distance to sail.
The red boat has a shorter distance to sail. You can see that to the point that the red and black boat cross, the black boat has a further distance. After that, they each have to sail 1/2 of the remaining rectangle. Assuming that one side of the course does not have stronger breeze than the other side, the red boat will reach the mark first.
This illustrates the term “lifted tack.” The angle the red boat has going upwind is closer to the mark than the angle that the black boat has. The wind shift creates an advantage to sailing that direction.
The other advantage to it is that when the red boat finally does get to the layline (the brown line in our illustration), it will be in a better position to judge when to tack because it will be closer to the mark when it tacks. It will also experience less leeway (slippage of the boat to leeward) on its way to the mark.
It is important to note that all of my examples are a bit simplified in that the two boats sail all the way to the layline, tack once and go to the mark. Sometimes that makes sense, but only on really short courses or ones that are very skewed. in any case, you want to spend much more time on the lifted tack as you work your way up the course. You’ll sail less distance overall.