The more accurate frame is that employees produce more value than their costs, so each employee is actually a profit producer. If you can increase their efficiency, then they produce more profit. Firing profit producers decreases your profit, not increases it.
"if you can hire fewer engineers to do the same job, great, but your competitors are going to hire more engineers and out-compete you." - this is correct in aggregate across the market. Of course any individual company may have other constraints that makes hiring additional people unviable. I think this is the common mistake, its easy to look at an individual company and believe that the constraint applies to all companies simultaneously.