As for longevity, if you consider software support ending as EoL, software/OS support for a huge swath of Intel iMacs (especially those with DGPUs) was dropped by Apple quite a few OS releases ago and you have to run community patches to keep them working. Whereas similar decade old hardware still run Win 10 and Linux out of the box.
*: Don't get me wrong though, the markups are for good reason. x86 platforms don't offer anything close to Apple's ARM chip memory bandwidth (which are closer to DGPU levels). Similarly, for flash/SSDs.