I recently had to lay off a couple of people in my department (part of a larger cut overall) and it is honestly the hardest thing I've ever been through in my professional career.
The only saving grace is that, as developers, they could (and did) go right out and get another job immediately. Such is the way of the software industry.
Laid off isn't the same as fired. I've had to lay off people a number of times. Sometimes it's fine, sometimes it's really not. Depends on the person and circumstances. Just because it's usually worse for the person being laid off doesn't mean that it's not unpleasant for the rest of the people involved.
BTW I have also been laid off. Worked out really, really well for me as I was given a chunk of cash, paid leave and walked into another job. I obviously realise I was in a very privileged position but I just wanted to point out these things are rarely black and white.
So the person who gets told to simply find another job in a few weeks is better off than the supervisor that has to develop a plan to systematically fire their best employees over the course of months all while also not being sure when their boss will do the same to them?
It sucks all around. No one enjoys having to downsize.
The only saving grace is that, as developers, they could (and did) go right out and get another job immediately. Such is the way of the software industry.