How offensive is 他妈的?
It is very common and, in my personal experience, has similar offensiveness as the f word in English. 

It can be offensive and quite rude: e.g. in a business negotiation, when the deal is finally broken and one side says:


  你他妈的给我滚出去 = "Get your fucking ass out of my office"


It may be used in irony among close friends which is not offensive then:
E.g. when two close friends meet after a long time, one may say:


  你最近死哪去了? 他妈的都忘了哥了! similar as "Where have you been lately? I fucking miss you!"


Hope this help to get the points.