The ads are provided by Google Adsense. They usually display ads based on the content or category of the pages, so here they will often show Pokemon or game-related ads.
In the settings there are two main controls:
- A list of categories that I can block. I've blocked most so-called "sensitive" categories like gambling and "references to sex".
- A list of ads that have been displayed, which I can block. I blocked a few dodgy ones that slipped through in the past.