Yo. Why bother at rm8k for an engine, when u can just get a 525 M50 at just over rm20k+. I just traded in my e34 525 M50 at rm25k for a newer e39 525 02/03. Aside from the newer chassis and comfort suspension of e39, I felt e34 pick-up to be better, probably due to the gear-ratio. I'm probably used to the e34, cos driven it for so long. For all I know its just psychology that e34 feels faster, cos the e39 didn't break a sweat.
You may end up paying more in getting other things replaced and also labour cost by replacing the engine, not to mention the time and money spend in doing so. Go change for a newer car. Unless you are those who gian upgrade and mod.
cheers