Nah, M3 is far more track focussed whereas the S5 is more grand tourer.
I really liked the S5 and now that the 3 series is due to be replaced, I'd be reluctant to recommend it. That being said if it was my money/budget, I'd go 335i coupe over the S5 since it'd be more affordable and IMO looks...