I wrote about my experience as a black developer not too long ago [1]. At first, you are shocked when you hear some insensitive comments made around you. Then you realize no one else even notices, so it must be something wrong with you. Eventually you ignore it. When someone says something stupid, you rationalize it and move on. After all, you are only just here to do a job. But then you get angry. You are angry at e…
Tangentially related: when I got a new tattoo a few years back at an artist I never been before I made some joke that tattoo artists are like dentists: they love to inflict pain on people. I immediately realized that he must have heard the same hundreds of times before, and that I said something pretty bloody stupid.
You're up close and personal for a few hours with a stranger; I'm not shy or socially awkward, but I'm also not especially outgoing; just average. Sitting in silence can be awkward for some human psychological reason, and you feel the pressure to say ... something, anything. Reflecting on my own behaviour since this, I've noticed it's in those kind of situations where I say the silliest things: when you feel a pressure to say something but you're not sure what.
I think many probably have the same experience to some degree getting a haircut or the like (although haircuts usually don't take 3 hours; or at least, mine don't).
I'd certainly like to think I wouldn't be the kind of person who would "the same stupid jokes or comments" that you mentioned – but I can point at least to once case where I've done so. There are probably others that I've forgotten.
My point is that it's hard to understand how something is perceived by someone else, especially when their experience is very different from yours, whether that's a tattoo artist or a black programmer.
An idea I had a while ago is a platform where people can post personal stories to expand on these kind of things and how it's perceived by them (about a wide variety of topics). "I didn't mean anything by it" comes off as rather weak, but it's my impression it is actually true in quite a few cases, especially these relatively minor ones: many people just don't understand what it is to be in the shoes of another person. You really need to explain this, and just saying "that's racist" isn't enough.
P.S. Don't get your ribs tattooed people. Good grief that one hurt so much more than any of the others.