That is one part - the other half is just simply that the market expects a response to any perceived failure. If a publicly traded company has a bad quarter the market wants to see some corrective action and it wants it now (long term plans don’t mesh with the constant news cycle of the market). Layoffs are a way to lower your expenses and cause a sudden shift in profit numbers… even though they nearly always result in long term damage to the company.