Many people are confused about warming up. Hollywood seems to think that you should stretch before lifting weights because thats what they always seem to show in the movies before they do their ten kazillion sets of bicep curls. Although stretching is great, stretching cold as preparation for lifting is dangerous and it doesn't really help keep you from getting injured lifting anyway. Doing some cardio before lifting weights is a great start to warming up but its not enough by itself.
The goal of warming up is to keep you from getting injured while lifting. The older you get, the longer it takes to warmup properly for heavy lifting. Warming up is about preparing your muscles and your joints for the heavy loads they are about to experience. The older you are, the longer it takes to warmup. For an 18 year old, a 2-3 minute warmup might be enough but for someone 53 like myself, a much longer warmup is required.
Choosing the exercise to use for warmup sets
An isolation exercise is not the best warmup exercise, much better are compound exercises - that is, exercises where two or more joints are rotating at the same time. Also choose the "biggest" compound exercise, the one you can do the most weight on. For example, if you are doing a chest workout which is bench press, inclines, and flys then use the bench press as the warmup exercise. If your chest workout is dumbbell press and flys, then choose dumbbell press for your warmup. With legs, the "biggest" exercise will be the one that works your quads - squats, leg press, or lunges whichever you happen to be doing.
Warming up for younger folks
If you are warming up to do a full body workout then three warmup compound exercises will do it: bench press , lat pulldown, and squats (for example). Do one set at 50% of your normal weight for 12-20 slow reps, then go up to 70% of your normal weight and 10-15 slow reps. No need to rest between warmup sets for any longer than it takes to raise the weight. You could do all the warmups at the beginning of the workout but that isnt very time efficient, much better to warmup as you go, so if you are starting your FBW with legs, only do the squats warmup first, wait and do the bench press warmup until later in the workout when you start working chest - that way you save a lot of racking and unracking of weights.
What if you are not doing a full body workout?
Now if you are doing a split workout rather than a FBW just warmup the affected parts. For example, to warmup for a pull workout just do lat pulldowns or for a push workout, just do bench. If you are doing a 5 day split with just one exercise per bodypart then your warmup will be a bit different, especially for arms. When you workout arms, its almost 100% isolation exercises so for that workout you will be using your primary isolation exercise for a warmup.
Warming up for older folks
OK, now lets talk about old foagies like myself. As I mentioned, the older you are, the longer it takes to warm up - especially the joints. It can take me 20 minutes or more to get my knees ready for a leg workout. For older folks, doing a 5-10 minutes of cardio is a great way to start - make sure to break a sweat, dont just spin your legs while reading the paper, push it. Then start your warmup sets, same as for a younger person. The difference is that you dont rush it, you start at a lower percentage of your max - say 25%. You also move up in weight slower and do more sets. Let your joints be your guide. Dont rush the warmup, wait till you feel good and ready before you hit that first heavy set. If it takes 30 minutes to get your legs and knees feeling like they can do your first set then thats just the way it is. Rushing into your first heavy set before your body is ready for it will just get you injured.
So to warmup for lifting weights, stretching doesnt help at all and cardio alone is not adequate - you gotta to warmup sets at 50%, 70% and 85% of your 8 rep weight. No need to warmup for every exercise, thats a waste of time. Just choose the biggest compound exercise you are doing for that bodypart and do the warmups for that.