It's called a chip -- Google is your friend.
The guys with the big pickups do it all the time I believe, but deviating from the factory setup might be less than legal (if it increases pollution, for example) and might void warranties or damage equipment. Usually they are trying to increase some aspect of the 'one-size-fitz-all' program to something specific to heavy towing, like delayed shifting into higher gear for greater power.
My belief is that if there was a clean, mechanically safe, way to increase mileage with different algorithms in computer, they would have already done it to get competitive advantage. Chipping is extending the range of the operating parameters further into the safety factors that the engineers set up to the equipment, pushing it closer to the edge.
Along those lines, some transmissions have 'chip on the fly', where one puts it in Tow or Haul or Performance Mode to get more power, or takes it out to get better mileage. I would guess that the average vehicle is already set up for mileage over performance. I had an early Saturn with that feature and it worked for towing a small trailer.
I certainly wouldn't buy a used vehicle if I thought the previous owner had chipped it because the modifications may have shortened the useful life of the machinery by exceeding design limits - YMMV!