When my companies have produced more output from the same inputs (or the same output from less inputs in the case of mass layoffs), we return the cash to shareholders by way of a stock buyback or special dividend the following quarter.
Maybe in some companies they instead give workers raises or outsize holiday bonuses, but I’ve never seen this.