It’s very difficult to state where the line might be. Often it’s the delivery, or the audience or some other factor than merely the words spoken that convey the intent of the joke.I’m not asking you if you find things that are funny to you already, funny. That would be a dumb question because it delivers a very obvious answer (yes! I find things that I find funny, funny!).
I’m asking you, at what point, is it not funny?
If anyone in the room other than you is offended? If 50% of the room was offended? If it crossed a certain opinion you had, and on which subject?
Some people have very clear lines. To each their own, but saying, “you can never joke about x or y” is too far for me. I’ve seen comedians do sets about their personal experiences with cancer and rape and they were great. Sometimes jokes which are offensive or just uncomfortable to some are coping mechanisms for others.
It’s all about context and intent.