Disclaimer: I am not a serious student of pop culture studies, media or film studies, sociology, anthropology, etc., etc. Moving along...
Recently I've been paying special attention to mockery in media. Anyone with a passing acquaintance with human nature would guess correctly that the trigger was when I experienced one of the groups or subcultures I identify with being mocked. (The applicable truism is that people find it hard to even care about something unless it affects them personally).
It was on a TV show some weeks ago. I won't delve into that with any greater detail, since this is one of those cases in which specific examples might distract from considering mockery as a general concept. I will add that the remark was well-aimed and well-executed, and clearly hilarious to anyone not taking it seriously. I'm not considering here whether mockery is ethical, justifiable, effective, enjoyable, or necessary (IMNSHO: the context and degree and intention are all pivotal factors). I'm also not considering self-mockery or lighthearted mockery between friends.
For me, the interesting insight I've reached after observing the mockery of one group by another is how it defines the group doing the mocking. Even casual or off-the-cuff mockery broadcasts a group's values, mores, and norms on a huge megaphone, in fact, and in more than one sense. First, a sincere mocking reinforces the identity of the group by indicating who the group is not. We are not Them. There is no intersection between our groups, because if that were true then we would be talking trash about ourselves! Second, mockery can indicate what the mocking group fears, hates, or doesn't understand. One of the primary uses for humor is coping. Before mocking another group, I may know full well that they are not all idiots or degenerates; I may possibly be on good terms with someone in that group. But if something about that group disturbs me, I can defang it by laughing at it as if it were a characteristic of an idiot or degenerate. I simply declare it unworthy of uncomfortable consideration. Third, mockery may illustrate how a group measures the status of its members, because mockery consists of bestowing an uncomplimentary status on another group. If my group equates status with intelligence, then you could reasonably expect me to mock the intelligence of other groups. A group that values fashion may mock the clothing of others. And so on and so forth. You don't mock what you don't measure, because the funny part is how low he/she/they measure up. Fourth, the method and manner of mockery can betray a group's concepts of humor or disgust. If a group mocks another group by calling them a bunch of grues, then clearly the group believes that grues are either funny or distasteful. If I mock you by calling you a jackass or an even more colorful metaphor, then I must not think much of jackasses.
You are who you mock. More practically, even mockery can be a possible vector of understanding between groups.