In the drops, on the hoods, or on the tops? I'm guessing you weren't in the drops. You need to get down there!
If your cardio/lungs give out before your legs, then push a harder gear (lower cadence). I find these work best when everything maxes out at the same time.
You might also try doing a set of 5, then do a (nearly) complete recovery, and follow that with a second set of five if you have the time.