.40: More power and larger wound channel...both of which are negligible differences from the 9mm.
9mm: slightly less power, but easier recoil, which means little if you can shoot a .40 well.
For use against a human, you will see NO difference in effectiveness, shot-for-shot. It has been shown to be true over thousands of shootings over many years. It all boils down to shot placement. I've read dozens of medical and ballistic studies, all of which come to the same general conclusion. I am unaware of any single incident in the world where the stop could be attributed to the bullet diameter (such as a .40 hitting the heart, where the 9mm would miss by a fraction of a millimeter), all else equal.
Where does the .40 shine? It will allow for better barrier penetration with less deflection than the 9mm in dense media, and will pack more punch out at further ranges. Where does the 9mm shine? It has greater capacity and is more controllable than any .40 round, allowing for faster, more accurate follow-ups. In soft tissue, both rounds are much more than adequate to reach vital organs, even from odd angles. Those angles that make a 9mm fall short will equally do the same with the .40 (on average). The bleed rate difference between the primary wound channels is negligible, shot-for-shot...basically due to the fact that bleed-out is entirely too slow as a fight-stopper, unless it is done by hitting a major organ or vessel (shot placement). Also, both rounds will penetrate bone and muscle equally well, again on average. This is evident by the avg. Jell-o test results for both rounds; both penetrate about the same and expand about the same on avg.
One problem that goes unaddressed in these debates is that the positives and negatives associated with each round can actually reverse roles in some scenarios, where a positive aspect can be a negative in one case, but not another. For example, a 9mm that is deflected by a bone INTO a vital organ makes that "negative" aspect a positive one. There is always going to be an exception to the rule, and because of that, we can never say definitively that one round's characteristics make it better than another all the time.
Considering also that no one will be LASER accurate under fight-or-flight stress, rapid fire, and movement, I would take all the advantages I can get (capacity increase and controllability).
What I may lose by choosing the 9mm is the ability to fire through auto glass with accuracy, or to penetrate some common, but dense objects that are all around us, and still have enough power to hit vitals. One situation where this could come up is in defense against a deadly road rage incident (where deadly force is allowed). You could have to fire out through your closed window. You could have to fire through your window into the BG's window, then into the BG. You never know...
All this jumping around may seem confusing, but it's the kind of little stuff that can drastically change the outcome of the fight. We can't predict the circumstances of a gunfight. This is why the debate never ends...