That'll be because Windowserver now uses Metal 2 to render UI, so if Apple's claims that it's 10x faster than Metal 1, then that's probably where the UI performance improvements have come from.
I personally own an entry-level Early 2013 Retina MacBook Pro with a i5/HD4000, and the iterative improvements they made with each major release really shine through. A machine that was previously described in every single review as underpowered on that department especially WRT Mission Control can now handle any number of windows I throw at it at a steady 60fps, including those blurs and transparencies which I previously had to disable back in the day, and even when compiling, say, GHC. As an extra bonus, the maximum video RAM on that machine was offset from 1024MB to 1536MB at some point (either Mavericks or Yosemite). Similarly, the Mid 2014 one (i7/HD5000) I use at work can handle the main display as well as external screens (including an ultrawide) without breaking a sweat. So much for planned obsolescence.
To add to this: the Nexus 5 was released a month after the 5S. That phone got its last official update last year, I believe. It was also discontinued a full year before the 5S.
Granted, the 5S started at 4GB for 500 USD and the Nexus 5 started at 16GB for 350 USD.
Still, it's hard to support the "planned obsolescence" argument.
It could be less planned obsolescence and more that iPhone/iPad hardware has gotten many times faster over the past few years while Mac hardware has improved by 50% at best.