Running out of gas is a leading cause of piston aircraft engine failures. So you'd think that pilots would have zero tolerance for the shoddy fuel gauges installed in many aircraft, such as the ones installed in the Cirrus SR22. But instead, they tend to make excuses for the manufacturers. "It would be too expensive to make gauges that work." Or, "you shouldn't trust a fuel gauge anyway." Or, my favorite:
Well, you know, the regulations require that the gauge be accurate only when reading empty."
That last one makes the least sense of all. A pilot doesn't need a gauge to tell him his tanks have just reached "empty." The aircraft has another way of informing the pilot the very moment that happens.
I don't know how this stuff about the regulations started. But I've heard it from dozens of pilots over the years. Even from those who work for manufacturers, and so should know better.
The Regulations Do Not Say that the Fuel Gauge Must be Accurate "Only When Reading Zero"
Most aircraft carry "unusable fuel." For example, perhaps there are three gallons that sit in a fuel line that can't be pumped to the engine. So while the aircraft carries 53 gallons of fuel on board, only 50 are "usable." The federal aviation regulations, not surprisingly, require that the gauge read "zero" when there are three gallons left on the aircraft, since that's when the engine will stop.
Each fuel quantity indicator must be calibrated to read "zero" during level flight when the quantity of fuel remaining in the tank is equal to the unusable fuel supply . . ."
Put another way, the gauge must read "zero" when there is no usable fuel on board. But it doesn't follow that when there is usable fuel on board, the gauge need not be accurate.
The Gauge Must Be Accurate At All Fuel Levels.
The regulations require the gauge to show the quantity of usable fuel in each tank "during flight." It doesn't matter whether there is a quarter tank, a half tank, or a full tank of usable fuel. The gauge must indicate the quantity accurately. The only time the gauge need not be accurate is when the aircraft is sitting on the ground.
If a fuel indicating system does not comply with the regulations, it is defective. Plain and simple.
The relevant part of the aviation regulations is as follows:
§ 23.1337 Powerplant instruments installation.
Fuel quantity indication. There must be a means to indicate to the flightcrew members the quantity of usable fuel in each tank during flight. An indicator calibrated in appropriate units and clearly marked to indicate those units must be used. In addition:  Each fuel quantity indicator must be calibrated to read "zero" during level flight when the quantity of fuel remaining in the tank is equal to the unusable fuel supply. . .