Every boat has its optimum rigging configuration for any given wind and sea conditions, often sail manufacturers will give set up advice which form a good starting point for boat tune but will need deviations as masts, hulls, sailing styles, crew weights, etc will affect the overall performance.
The Sails are the power generators and the trick to optimising the power from the sails in varying wind and sea conditions is to be able to adjust the sail shape, the camber of the sails, the twist etc, using the controls that are available. Thus it is important that the rigging has the ability to be adjusted controlably, repeatably, easily and reliably.
The final aspect is the correct sail trim, i.e. the attitude of the sail to the wind direction relative to the hull, this angle of attack , the angle of the sails to the apparent wind, is only a few degrees variation. Variations in wind direction and strength relative to the hull are dynamic and so the sails need to be adjusted dynamically if the optimum angle of attack is to be maintained in order to generate the optimum power from the sails.
The use of tell tails on the sail luff and leach are key to recognising when the sails are correctly trimmed so getting the optimum power from the sails requires frequent attention. Whilst top sailors develop a feel for boat speed and so are able to maintain good speed whilst giving attention to other matters such as strategy, optimum speed requires constant focus.
I have found that learning how to adjust the sail shape is the hardest thing because you need a combination of knowledge and experience to judge what is happening and what to change and by how much, even minute by minute. Time on the water is the only way to marry these two, preferable sailing with boats of a similar speed so you have something to compare the effects of changes.
The image is of an Enterprise mainsail; Mike Macnamara is explaining how the mainsail shape is affected by mainsheet tension as part of an Enterprise Association coaching session.
From what I can remember the tension causes mast bend high up which means that the belly of the sail remains fairly full whilst the leach is tight giving plenty of camber and is good for pointing. Easing the tension a tiny bit opens the leach a bit and increases the power. (correct me if you think I'm wrong) This is the kind of settings you might use for medium wind strengths.