Luff and foot rounds were how draft was introduced to bolt-roped sails, especially in the absence of broadseaming, especially in small low cost boats. If you attach a convexly curved sail to a straight spar, a baggy pocket is generated near the mast and boom. Fill it with wind, that excess cloth becomes your airfoil shape. Not an especially great airfoil shape, but it was a cheap and quick way to accomplish that end. The preferred way to induce draft, especially with modern, low-stretch synthetics, is to build in draft by curving the seams between panels (broadseaming). This allows you to control the draft location and depth much better. But it is more labor-intensive than just cutting a luff curve. For the ultimate in airfoil shaping, sailmakers have begun molding the panels over three dimensional dies to get curvature just right. That's really expensive.
The other reason to build a positive curve into your mainsail luff and foot is, as ShockT notes, because most masts and many booms (esp. with mid-boom sheeting or vangs) exhibit a certain degree of bend. If your sail's luff and foot were straight, any flex in the spars would pull all the draft out of the sail and cause embarrassing creases. This Wayfarer mast pre-bend is a bit exaggerated, but you get the idea:
On some boats, pre-bend is critical for driving upwind, esp. in chop. It can also help the mast resist bowing forward downwind, which can be bad. Depends on the boat, tho. BTW, most headsails have a negative (concave) luff curve, to accommodate headstay sag.