There are good jokes. There are bad jokes.
Typically what seperates the two categories is the reaction of the audience. If they laugh, it's a good joke. If they don't, it's a bad joke. The subject of the joke doesn't matter. It's either funny or not.
I believe almost anything can be the subject of a funny joke. The joke may be in bad taste. It may be insensitive. But it can still be funny. I've laughed at jokes that are racist, steroetypical, crude, vulgar, and foul. Jokes about dead babies, 9/11, suicide, rape, and the Holocaust. Each has made me laugh to some extent or another.
I don't think any subject should be off topic for humor. We need to be able to laugh at things. We need to be able to take a tragedy or a horror and find a way to cope with it. They can help us recover. They can help us stand up and recognize that we can get past it. That said, I don't think rape jokes are appropriate at a domestic couseling event. And you probably shouldn't joke about Joe's dead brother at the funeral. Time and place matter.
But inside a comedy club, there should be the expectation that you're going to see good and bad material. Comics work on thier material constantly. Adding, tweaking and subtracting jokes to try to make people laugh. Some comics are talented, but a lot of them aren't. Some jokes are good. Some aren't. I don't get offended when a joke fails, or even when it hits too close to home. I just don't laugh. And insteadof getting offended, maybe that's what a lot of other people should do too.