The PS4 and the PS4 Pro, as well as the Xbox One and Xbox One X, speak the same respective languages. A PS4 Pro is a PS4. Higher clock speeds generally become a problem when a game's logic is tied to clock speed. For example, some older PC games can run too quickly on more modern hardware. It's also a problem when a game's animations are tied to frame rate, and a higher frame rate would break them. Think of the old PS1 and PS2 Final Fantasy games. FFX runs at 30 FPS even on Steam.
More modern games don't really have this problem as they avoid these programming methods and design flaws. I only know of 3 games that fail to run properly on PS4 Pro's boost mode (all 3 are non-AAA games), and the problems they exhibit are minor. The PS4 Pro doesn't need a compatibility mode to run the vast, vast majority of the PS4's library. That whole thing of disabling boost mode by default was a CYA move.
The Xbox Series Whatever also runs Xbox One games natively. It doesn't emulate them. It doesn't have a system-on-chip solution. It just runs them. The non-patched games can be improved at a system level similar to how you can toggle settings in your GPU's settings application, like forcing vsync or anisoptropic filtering (Xbox One X also did this). It's a very good feature but it's not like some kind of engineering feat Microsoft pulled off.
In other words, the Xbox One and the Xbox Series S/X speak the same general language, but the Series S\X not only speaks it more quickly but has a fuller vocabulary. Sure, it's "backwards compatible" but not in the same way the PS2 was backwards compatible with PS1 games (system on chip) or how the Xbox 360 was backwards compatible with some Xbox games (emulation).
You have the overall concepts correct but almost everything you saying is wrong.
Xbox one games run in a container, on a custom Hypervisor which is why Microsoft can say with greater confidence than sony that a larger percentage of their games will be compatible.
It's impressive because Ms has been planning and building this since before the start of this current generation.
It's execution time for MS and their backward compatibility initiative and it has given them a competitive edge against sony and all others.
What, to a large extent got Windows in the "dance" is the user's ability to run Dos programs, windows 98, windows me , windows 2000 etc... on the latest windows.(backward compatibility)
They have effectively implemented this ideology in their console business.
The execution is different because they have control over the hardware, so they made sure the graphics hardware could mimic the previous hardware in terms of the execution path.(same as PS5 I believe)
but there is some level of significant emulation going on for everything else even if its a recompiler of some sort.
There is a reason why no one else is doing it to the same extent as MS(the largest software company in the world) and its not because it low-hanging fruit as your post is suggesting.
Consoles games frequently have chunks of their code designed to target specific hardware features.
how is it Xbox one S game run flawlessly on Xbox one X hardware?
Xbox one X memory designed is completely different for key features on the one S and to get any kind of performance out of the one S you have to hyper-target its strengths meaning lots of architectural specific code, however, I'm yet to hear of the one X being incompatible with Xbox one S games.
all of the consoles being X86 and have similar OS is not enough for backward compatibility to work.