I'm on planes at least once a month and in the last 9 months I've had my bag checked for size at least three times. The first was on Air Canada out of Montreal. The gate personnel were having everyone in the waiting area put your bag in the "bag sizing contraption". If it didn't fit you had to check. My bag is a 20" Eagle Creek and fits into any overhead without issue - not too long, not too deep, but it wouldn't fit and I was forced to gate check, along with at least half of the other passengers; the overheads we not close to full. The frame thickness on the bag didn't fit, so taking anything out of the bag wouldn't have helped. We purchased this bag as an approved size for European airlines (20") and it's NOT oversize for carryons.
The last few years I've mostly flown United and have not had experienced the same thing on United. But this year I've been flying American more, and there always seems to be a gate person supervisor who looks at the bags as you scan your boarding pass, and calls out people who seem to have too large of bags and try the "sizer" contraption. One time, I'd packed a electric toothbrush case in the front pocket. I used my knee to fit my suit case in the sizer, and he said " you can't force it". So I took out my toothbrush case, the bag fit without issue. A couple other times, I've been asked to place my bag in the contraption, and again no issues with my 20" Eagle Creek.
So long story short, I've never seen airlines measure or weigh carryons, it's more about fitting into the airlines "sizer frames". In addition, if you are boarding in one of the later boarding groups, you'll have to check your bag regardless as they run out of room by the time they board Groups 4 and 5.