In 2021 Google made $257 billion aka $257 000 000 000. And a profit of $76 bn aka $78 000 000 000.
It had 187 000 employees.
That works out to $1.3 million income per employee. And a net profit of $406 000 per employee.
They don't need to lay off anyone. They just want to.
I've seen smaller companies where they first shift employees around, offer everyone a choice, etc. People are only really laid off is things don't work out over many months or even years.