The reason you warm up is mainly to ready the muscles for work so you don't surprise them with too much strain and cause a problem. Warming up for your average gardening does not need to be extensive. Perform some essential stretches and walk briskly or jog for a couple of minutes to get the heart rate up and the blood flowing.
You should warm up before you do any lifting or bending since those are the activities you are most likely to injure yourself with when cold.
If you have a particular problem, like tendonitis or arthritis you should take steps to prevent aggravating the condition as well. Using good ergonomic gardening equipment and proper body mechanics is a good start.
If you plan a strenuous gardening activity, like tilling or re-potting large pots, save that until you've been active for at least a half hour. You should be good and warm by then and as ready for the heavy stuff as you'll ever be.
A good cool down is even more important to injury prevention than a good warm up. Don't just sit down when you are done. Take 10-15 minutes to really stretch. Loosening up the muscles as they wind down improves their health and yours.
So enjoy your garden and take care of your body so you can enjoy again and again and again.