Ever been in a really thick crowd? Like close to the stage in a big concert, where people are so pressed together that everybody has to follow the movement of the crowd and your arms are pinned to your sides from time to time?

I think it should be even worse than that if you and 7 men behind you use all their strength to try to shove 8 other men back. Who are trying the same with you and your buddies. And possibly everybody clashing at a full run. Like in a classical greek hoplite fight.
No way to use a spear underhand in this situation. Only the first row could do one aimed thrust and then their arms would be pinned. And their spears would penetrate the opponents or the belly of the guy behind them, depending on who has the better armor. Or they would break.

In one on one combat if the phalanx is broken, or with units fighting in a looser formation, it is a differnt story. I can imagine that the underhand style is then superior. But you need space for that.