Mac: 2011 27" iMac, 1 TB SSD, 32 GB of RAM, Mac OS 10.13.6
Any time you right click on any file, the Finder beachballs for a long time. Sometimes a few minutes, other times even longer.
Images files all have default icons, no 'preview' thumbnail icons.
Many programs exhibit strange behavior. Safari is slow to open, System Preferences throws errors about iCloud Drive, Adobe applications don't launch, or launch and crash.
Unsuccessful Fixes: (Not necessarily in order)
Downloaded a fresh copy of High Sierra and installed it over the old install. No effect on the problem.
The symptoms very much point to a failing hard drive. But this Mac had an SSD drive. Also I created a test user and when I log in to that account, everything runs normally. So even though it feels just like a failing hard drive, it is not.
This computer had lots of 3rd party software installed over the years, much of which was old. I went through and deleted everything that's no longer in use and everything that looks like it was sketchy.
Deleted Finder Prefs ( ~/Library/Preferences/com.apple.Finder.plist ) and rebooted. No change.
Removed most Login Items, LaunchAgents and LaunchDeamons, no change.
Installed and ran MalwareBytes. Found one minor piece of malware. Removed it. No change.
Booted off an external High Sierra volume, ran Disk Utility First Aid on problem boot drive, no change.
Delete ~/Library/Preferences/com.apple.XPC.activity2.plist and associated files. (Files in the same folder with the same name but some extra random characters added to the end)
Rebooted and all problems solved! Computer is running totally normally!
I think I'm forgetting a few things I tried. I've been fixing Macs for a long time and this really had me stumped. Nothing I tried was working. Everything pointed to a software problem in the User folder but it felt so much like a hardware problem. I'm not sure how the XPC files even caught my eye. But I knew with the problem in the User folder, with basically no software starting on system boot, and no programs manually started, and with the Finder still beach-balling as soon as you right clicked on ANYTHING, that it was almost certainly some program's prefs file mucking the whole thing up. Took about 5 hours to track it down. Hopefully if I ever come across this again, a google search will find this post :D