I was just reading this Reuters article from a few weeks ago and it's not like they're not making a tidy profit that could be spent on new fabs instead of investors...
Macquarie estimates Samsung’s chip division’s operating profit margin jumped to 47 percent last year from 26.5 percent in 2016, and will rise further to 55.5 percent this year.