That makes no sense. They both operate at the same pressures at 35k per SAAMI specs that would mean there is no discernible difference in "battering energy" upon the internals morever many people will up the ante and shoot plus p in 9mm pushing the pressure up to 38.5k pounds of pressure that is more than the .40.
That's not really correct. Pressure only effects the barrel and the breech face. And peak pressure only effects the chamber and the first inch or so of barrel. Unless the yield strength of steel is exceeded (i.e., the barrel bursts), then pressure itself is not what eventually tears up or wears out handguns.*
When people talk about "battering internals," they are referring to the parts such as the barrel lugs, slide lugs, links, disconnectors, etc. Those things don't feel or care about pressure unless something is dramatically wrong (i.e, the gun is out of battery when it fires or you are in the process of blowing up the gun with some vastly over-pressure round). Those things
do get battered by recoil energy and, in particular, how vigorously the slide is thrown backwards. The
total area under the pressure curve contributes to this**, but not peak pressure in particular. What
matters is what the total recoil energy put into the system and its components is.
Think about it this way. Let's imagine two guns. One has a .32 caliber bore and a 21k PSI peak pressure max, with a case just over an inch in length. Let's call this a "32 H&R magnum" because that exists. Now, the second gun will have a 3.2 inch bore. It will have a case just under a foot in length. We will also give that a 21k PSI peak pressure max. Instead of throwing 100 grain rounds like the little gun, this one will toss projectiles weighing a couple of pounds. Do you think that these two guns will put similar stresses on their components? No, of course not. Even running at precisely the same peak pressure, the vastly greater momentum of the projectile (and powder ejecta) of the larger gun will, of course, produce vastly greater recoil energy to be dealt with by the gun's systems.
The .40 generally has significantly more recoil energy, precisely because it is throwing a heavier projectile at similar speeds. That's
always going to be more demanding to the components on the gun. Always.
Fortunately, modern gun design makes accommodating these loads no problem in service size guns. Some of the earlier .40 guns that were shoehorned into guns designed around 9mm had durability problems (such as the Hi-Power). But guns designed with the 40 or other similarly powerful rounds in mind (which, from a recoil perspective, would include full power 45 ACP... despite its lower pressure, that round is also more demanding to the working components of guns than the 9mm) are certainly well able to handle it.
One final note: People talk about +P ammo wearing out guns faster. It can, but not because of peak pressure (again, unless you're exceeding the yield strength of steel... bulging barrels and/or blowing up guns). It's because the extra pressure (total under the curve) is being used to throw the bullet faster, resulting in greater recoil energy. As explained above, that is harder on the operating components of semi-auto pistol.
* Things are a little different in bottlnecked rifle rounds, where pressures may have a stronger relationship to throat erosion and barrel life.
** In the way that horsepower output of an engine contributes to vehicle speed.