Well in simple terms I'd say always go for the 3 litre - but you did ask!
Running costs are the same as they are the same engine, just different sizes - even road tax costs the same.
I'm assuming you are referring to E85 Roadsters from 2003 to 2008. Just be aware that there was a facelift in early 2006 and the engines changed from the M54 to the N52 which was more powerful in both sizes.
M54 2.5s had 192 PS and 3 litres had 231PS. In the facelift there was a 2.5i that is best avoided as it only had 177PS. 2.5Si models had 218PS (so close to the pre-facelift 3 litre) and 3.0Si models had 265PS.
But the facelift N52 engine had a couple of idiosyncrasies, like no dipstick (you check oil level with a button on the dash) and an electric water pump which costs around £250 to replace - although they can last anywhere from 60K to 90K miles. That engine also revs a bit higher, to 7,000rpm.
The other thing that changed with the facelifts is there were 2 models, SE and Sport. The Sport models all got M-Sport seats as standard, as well as M-Sport steering wheel and suspension that sits 15mm lower. M-Sport seats are so popular that used ones fetch up to £750 a pair!
Having said all that it may depend a bit on what you are used to, and what you are looking for. Plus if there is a car near to you or one that has your ideal colour combination or options - heated seats are very popular in the Roadster for obvious reasons!
I've had a few of these engines in 3 Series and Z4s and they all seem capable of well over 100K miles without major issues so long as they get regular servicing.
I just hope that proves helpful, rather than confusing. :lol: