Just to keep things straight, the motor produces the power whether in terms of horsepower or torque. Gearing does not produce torque or power. Gearing provides mechanical advantage.
Think of the gears on a 10 speed bike. If the front gear with the pedals attached has 40 teeth and is connected by a chain to a rear gear with forty teeth, you have no mechanical advantage. If the rear gear has 80 teeth, the front gear must turn twice for every revolution of the rear gear. To the rider working the pedals this mechanical advantage makes the pedals easier to pump. An advantage when going up a hill. The disadvantage is that the rider must pump the pedals twice as fast to achieve the same speed. Obviously, the opposite is true if the rear gear has 20 teeth.
Think of a car with no transmission but only a shaft linking the motor to the rear end. In this situation, we would have to determine how much power the motor makes and select a rear end gear which would allow the power of the motor to readily overcome inertia as well as propell the car uphill plus allow for the greatest maximum speed. The trade offs become obvious. The trannny's multiple gear selection offers a method to overcome these trade offs.
In addition, the tranny gears provide further mechanical advantages. First gear is not as fast as second but will accelerate quicker, second gear is not as fast as third but will accelerate quicker, etc..
Generally, the greater the power produced by the motor, the less steep the rear gear. For example, a 225 hp 5.0 is better paired with a 373 gear rear end than a 3.08. Some might even prefer the 410's with the stock 5.0. Many believe the 355's to be a good choice to go with the 5.0. My windsor produces 437 hp and the rears are 373's. For me this is a great combination; ample acceleration plus proper rpm for 100 mph cruising.
All the best,