For all intents and purposes, .25 ACP velocities top out from a 7 inch barrel. Here's the data in muzzle energy from ballistics by the inch:
From a comparable barrel length, hyper velocity .22 LR ammo (CCI Stinger, Velocitor, Aguila Interceptor, Supermaximum, and Winchester Hyper Speed) will generally always have a muzzle energy about the same as or greater than .25 ACP.
There is no threshold where the .25 ACP makes better use of a scarce length compared to the .22.
Now, there may be times where the .25 will be 1 to 5 ft/lbs more, but when we're talking about energies less than 130 ft/lbs, I don't consider an extra 5 ft/lbs to be that much to be impressed by.
However, the most important part of using a low caliber gun for defense isn't muzzle energy, because there's really not enough to consider it powerful for stopping a threat, but penetration. .25 ACP FMJ bullets (which are the only projectile that should be used for defense in the .25) are 20% heavier than the 40 grain hyper velocity .22 and about 40% heavier than the 30 to 32 grain .22 ammo and the bullet is round nosed, thus it is a low drag projectile in soft tissue.
That translates to better penetration.
Secondary to penetration is the priming system and cartridge geometry. The .25 is centerfire, so it's more reliable, the .22 isn't and is inherently less reliable. The .25 ACP is a semi-rimmed cartridge while the .22 is fully rimmed. Both can cause issues in detachable magazines called rimlock.
The one aspect of the .22 LR that contributes to possibly being a better choice than a .25 ACP is there are many more revolvers chambered in .22 LR than .25 ACP. Revolvers are more reliable than semi auto's, so that magazine feeding issues and the rimlock possibility is eliminated.
Personally, if someone is looking for a small pocket gun with lowest recoil, decent energy and penetration, and excellent reliability, the .32 revolver is the best choice available.