But I have reasons to believe men and women usually perceive it differently, because they perceive affection differently.
It took me a little while to put it together. I've had a girlfriend who hated tickling, and two long term partners who liked tickling. BUT! One of them had a bdsm tickle fetish and didn't really enjoy the tickling sensation itself. The other one liked to be tickled, she could get aroused by it, but it wasn't a fetish. So I think the line is not about sex, but intimacity - including sex or not. To treat both as the same comes from a masculine's perspective, we're raised that way.
But let's exclude sexual partners examples for a while. When I was younger, I've had two particular female friends who loved to engage in tickle fights, so I assumed everyone actually enjoyed it and people only pretended not to. I slowly realized it wasn't true, especally during my first relationship. I've actually understood I had a fetish when I heard from one of my friends, who asked me If I got sexually excited by tickling too - simple as that. As soon as I became fully aware of my fetish, I naturally lost the will to friendly tickle people like I used to do. And it's not only a moral issue, I hardly feel intimate to someone. But this other friend of mine, it bugged me out... she really loved to start and keep tickle fights, and I remember how much she liked tickle talk and describe how she would torture someone for information, etc. I was sure she knew what was going on betwee us and I was sure she had a fetish. But later I realized she wasn't a fetishist at all. She liked to tickle and to be tickled by family members and, later, I've seen her tickling her children, which obviously feels gross to me.
Now. Usually men do not tickle each other to please or show affection, when they do it, it's as a form to mock each other - like when they twist each other nipples, slap each other in the balls, etc. Not to hurt, but to bully, and I think that precisely comes from how men avoid any form of physical affection with other men.
That's probably why tickle torture scenes between men are more common and may "feel" like comedy to the general public, while a women being tortured "feel" more like abuse and ulterior motivated. Which has absolute no fucking logic, of course. I think it's intuitive to most of the people, but we try to rationalize it.