Every employee is either sub-par, at-par or above-par. If you perform the minimum to not get fired, you are necessarily doing what's expected of you, you're at-par (maybe you wont get promoted but you are doing what's expected of you), and if you are doing more than you need to then you are exceeding expectations.
This thinking that you can do what needs to be done to not get fired, but still be under performing just tells me its a bad manager(s) with no clear expectation setting and communicating it and if anyone is clearly sub-par making sure its communicated early with clear expectations instead of a doing a mass layoff to try and hope fix it.
I contrast that with people that are laid off in a shrinking industry, and I have a ton of sympathy for those folks, because it's basically musical chairs around who gets to keep their jobs. Folks who are laid off in shrinking industries often need to take a large, permanent pay cut, or leave the workforce entirely.
How do you really equate your 'output' (value) with the money you are being paid? There's no direct 1:1 relation or easy formula. Even if you try to come up with an elaborate scheme of metrics, there really isn't a perfect way for it.
That said let's assume you could measure that somehow. Even then the underlying meaning of "bare minimum not to get fired" is not that you provide the exact 1:1 match of value you provide to the money you are getting paid (including benefits etc). There exists some X < 1, where you aren't getting fired but the value you provide is definitely smaller than the money you get paid. Is it 0.8:1? 0.5:1? 0.1:1?
Whatever that actual number is though, at most companies I've been at that number that lets you stay on is so low that nobody can argue that you're "just" doing your duty to extract as much value from the company for as little work as you can get away with (after all, in most cases the company is definitely trying to do that in reverse). It's so low that anybody that isn't doing the same thing gets severely demotivated. If I do my 1:1 or even a 0.8:1 or whatever and I like my job, then watching a 0.1:1 not being fired and even actively protected in some cases is awful.
That is, I've worked with people that didn't completely suck, but to quote Office Space, they always did the absolute bare minimum. Few companies have the Netflix mindset of letting people go with a large severance if they aren't top performers, so these mediocre folks can just be allowed to fester.
TBH, I've been glad as an engineer to see the company (belatedly) handle these sub-par performers, and to these folks benefit they get a fair severance and can usually find other jobs quickly.
Of course not all layoffs are like this, and often times layoffs at a large company are done "unevenly" as others have pointed out, but I have been in a company before where layoffs allowed the company to focus and perform better.