My dad has a 1993 E34 M5 in Mugellorot over black, and it's got about 125k miles on the clock. That's pretty low miles, but it has been an extremely reliable car for him. In the 10 years he's had it, it has really only needed normal maintenance like water pump, hoses, and a few gaskets that started leaking oil. Solid lifters mean it still needs valve adjustments, and they are shim type, so it does cost a bit. 1993 got the slightly more desirable shadowline window trim and throwing star covers on the M System II wheels, rather than the turbine covers. All US cars were the 3.6 with a 5 speed, while Europe got a 3.8 with a 6 speed and an optional electronic suspension from 1993 to 1995. There was also an E34 M5 wagon over there. I believe all US market M5s had SLS, which uses the power steering pump to level the rear suspension. It's usually worn out by now, but is easy to delete. If you want to keep stock ride and handling, BMW still sells 535i Sport springs and dampers that match the M5 ride height and stiffness.
That S38 is one of BMW's great engines, and has one of the most badass idles and exhaust notes of any factory sedan I've driven. They have steering boxes rather than rack and pinion, so feel isn't quite on par with the 3 series cars, but M pumps and boxes are calibrated differently than plebian E34s and feel pretty good. Front suspension bushings wear quickly under hard use, but E32 750 parts are a factory upgrade that hold up well. Most of the underpinnings are shared with other E34s and aren't too expensive.
I've driven my dad's on the track and down a quarter mile a few times. It ran around a 14.8 quarter, and I don't remember what the trap speed is. Very well balanced on track, with exceptional brakes, average steering feel, and good body control for an older stock car. They'll eat the outside edge of the front tires if overdriven, though. The engine is a dream on the track, and the trans shifts much better at high RPM than at low revs. Throttle throw is a little too long, making it hard to heel-toe, but pedal placement is decent. The clutch feels very different than a normal E34 - it is stiff, long throw, and has a pronounced change in effort around engagement that can make it a little more difficult to drive smoothly on the street. A clutch stop could help.
Watchouts are poor engine maintenance, the SLS system, electronics (generally easy to fix, but the lighting control module (LKM) is a weak point), heater cores leak but are fairly easy to replace, the HVAC thermocouple in the center console has a small fan behind it that will clog with dust and vibrate/buzz, and rust on the bottoms of the doors. The seats also often get a twist due to drive cables pulling out, but this is a half hour fix that doesn't require any new parts. Thunking or vibration in the driveline is the rubber flex disc if it's around ~25mph or the center support bearing if it's under load at most speeds. Differentials occasionally pick up a whine if they don't get regular oil changes, but this is more rare on the M5. The M5's transmission is basically bulletproof. Generally very solid cars with good support and parts availability; E34s are considered to be around the high point of BMW durability. Prices vary widely - I've seen anywhere from 10k for high miles cars needing some work, up to 30+k for really good examples.
For reference, I've got an E34 525iT 5-speed and an E30 318is, and worked at a shop specializing in this era of BMW for years. I'm a little biased; these are some of my favorite cars out there.