Google pulled out of China, but when it was a much smaller consumer market than it now is. And then slunk back in later, to not a huge amount of success. But GDP per capita in China is probably a third of what it is in Europe - so despite having fewer people, Europe is still richer - and has more dispoable income for fripperies who might pay Google for advertising.
Also, when you're a monopolist (and Google are) then you need to maintain your monopoly in order to abuse it to make monopolistic profits. As soon as Google pulls out of one of the biggest markets in the world, they torpedo their own monopoly - and create a space where a rival can build up.
Google won't leave the EU market.