It depends on what you think your 40D is lacking. If the 40D is not fast enough or the AF performance is not adequate for the fast moving sports shots, then the 7D or 1D Mark IV will be a great replacement. If you own a lot of larger aperture lenses with f/2.8 or wider, the 1D Mark IV's new AF system will definitely be superior to the 7D.

On the other hand, if your 40D is adequate for your sports and wildlife, then you can consider the 5D MarkII, which has slower performance than the 40D but it is full frame and can achieve wider angles and shallower depth of field with the large aperture lenses. The 5D Mk II is great for people portraits, landscape and macros. The HD video has amazing quality but you cannot AF, so don't use it for sports.

I upgraded from 30D to 5D Mk II. I still use the 30D for most of the action shots (faster fps and 1.6x crop factor gives me longer reach). But for very low light actions, I use the 5D Mk II due to its better and higher ISO availability (7D also has the expanded ISO). My low light/night action lens is usually the EF 70-200mm f/2.8L IS, and the ISO 3200 still looks great with the 5D Mk II, the ISO 6400 is useable but higher ISO is only fit for smaller prints or web gallery. The center AF of the 5D Mk II is also a cross type AF sensitive for f/2.8, like the 50D and 7D. I find the image quality of the 5D Mk II to be great, a definite improvement over the 30D. The HD movie has replaced my HD camcorder for family clips and my kid's stage performance. But I still use the HD camcorder for sports actions and longer family movies. You have to pre-focus or use manual focus during videotaping to adjust focus.