I bought an iPhone this time around because I wanted to play with lidar and because google defaulted hard on the "free picture storage" promise. There's a lot to like about the iPhone, but anti-spam is a glaring exception. Holy shit, I assumed that Apple would at least have made an effort, even if wasn't their core expertise and the result wasn't quite as good as google's, but it's like they didn't even try. Meanwhile google put this into production years ago and they have iterated and tuned it to the point that the spam problem is almost completely buttoned down.
Google is applying spam filtering. Essentially all the text messages I want come through. All the text messages I don't are a silent notification.
Pixel applies spam filtering on calls too. Few spam calls even make it through the spam filtering. When they do make it through, and you don't recognize the number, you can use Google Assistant to screen the call, which will provide a live transcription of what the caller is saying, all using a local on-device speech recognition system. If you want to pick up, you can do so. Otherwise, you just drop the call.
I especially like the feature to "screen" a call that looks like spam, the small number that get through to me. It almost always is spam and I've wasted some of their seconds. It's not much, but I now feel like a victor rather than helpless. :)
The ability to filter per se is quite bad. The calls it decides to screen itself pass through 100% i.e. it listens to an extended warranty call or 5 star hotel call and then rings through as if it's a legitimate call. It's worth noting that only a small fraction of calls go to screen automatically, most just ring and I have to press screen button myself.