Meaning there is no "if 9mm gained so much performance, surely the 40 gained just as much performance"...
It is true that all ammo in all calibers have gotten better, and roughly at equal amounts. The problem with this argument is the assumption that 9mm used to be inferior.
Having confidence in your personal defense weapon and caliber is more important than actual performance, in reality they are all about the same and always have been. The 9mm has never been inferior to 45 ACP. All objective tests conducted over the last 100+ years have always shown the 2 to be equal performers when comparable bullets were used. For example 9mm FMJ vs 45 FMJ or the same HP bullet designs.
But American shooters have only recently become comfortable with and accepted the idea. They have always had more confidence in larger calibers even though there was no real proof they were any better.
The 40 was introduced at a time when cops wanted more ammo available than revolvers or 45 cal. pistols of reasonable size would allow. And they weren't ready to accept 9mm. The 40 was a very good round, and still is, but I'd just as soon skip over 40 and go straight to 10mm if I wanted anything bigger than 9mm. The 45 ACP pistols are just for nostalgia anymore.
But I see 40 S&W slowly fading. There are still a very large number of dept's and individuals using 40 S&W, but as LE depts. upgrade I predict more and more going to 9mm. If 9mm, 40, and 45 all do exactly the same thing with comparable ammo, and they do. Why limit ammo capacity, increase recoil, costs, and firearm size?