Typically for a public company, the Board (who represents stockholders/owners) wants professional Management to be "aligned" to "stockholder value". That means they are heavily incentivized to take various actions (sometimes very short term oriented) that will increase the stock price. The stock price is based on expectations of future earnings. So if layoffs improves that picture, an "efficient market" responds quickly.
Of course, "IPO" may not mean a lot of liquidity, and people here are probably making too many assumptions. One mistake in all of the comments is probably assuming there is "one SAS entity" that goes public and most of those shares are available to the public. That seems incredibly unlikely to me. Instead, I'd assume various scenarios like the founders retain 90% of the stock (only releasing some small % to IPO), or there is class A and B stock, and the public shares have no power over decisions, and/or there is a holding company that controls a subsidiary that has partially gone public (raising some funds but not giving up control). There are probably various other scenarios possible. For example, suppose Viya related business really has been having 100% growth (from a very small base). The holding company could have that business go public with some AI story. Lots of money is raised to try to give it a boost, all the problems talked about here aren't really known, maybe this small business has more of a chance, who knows. The holding company may or may not take other decisions about layoffs not related to the (on paper) subsidiary that is partially public. In short, don't assume the SAS we think we know is the SAS that goes IPO as some kind of monolithic financial entity. It will be more "creative" than that.