i like dark humor and so do a lot of my friends so i personally don't mind it even if it touches some sensitive issues as long as it is not intended to hurt others. it also really depends on the audience. i dont share any of the darker jokes i know of if i'm not 100% sure that the other person is fine with them.
Jokes that crosses the line depends on the person hearing the joke and how sensitive they are too it. Some people might not be aware of the "joke" either, so it might not seem funny to them and might take you seriously.
If it hurts said person you're telling the joke to
But imo humor is subjective, I know a lot of people don't like dark or offensive humor, I think it really truly depends on the intent of the person telling the joke