Halberdiers if you want to assault, Spearmen if you want to defend.
I wonder if the math supports this claim. Let's compare 40 halberdiers to 48 spearmen (both equal 240 points) both in horde formation.
Against T3 opponents:
Halberdiers -> 30 attacks -> 15 hits -> (2/3)*15 = 10 wounds
Spearmen -> 40 attacks -> 20 hits -> (1/2)*20 = 10 wounds
* if the opponent has no armor save and assuming the halberdiers didn't charge (for this comparison we always assume the spearmen do not charge) then spears are better because they will most likely have an extra rank. If, however, then opponent has an armor save (which most core troops do) and/or the halberdiers charged then halberdiers are better or at the very least equal.
Against T4 opponents:
Halberdiers -> (1/2)*15 = 7.5 ~ 8 wounds
Spearmen -> (1/3)*20 = 6.6 ~ 7 wounds
* Halberdiers are better
------------------------------
Really the only thing Spearmen have going for them is the extra rank. Let's compare the 40 halberdiers and 48 spearmen to, let's say, 24 ghouls (also 240 points). We'll assume the empire troops pass their fear check.
24 Ghouls (6x4) vs 40 Halberdiers (in horde):
Halberdiers -> 24 attacks -> 12 hits -> 6 wounds
Ghouls -> 18 attacks -> 3 will wound automatically from poison + 8 more -> Halberdiers make 2 AS - > 9 wounds
* Halberdiers have 3 complete ranks as do the ghouls. Assuming the halberdiers have full command they would lose by 2 and if they charged then they would lose by 1. In any case they wouldn't be steadfast.
24 Ghouls (6x4) vs 48 Spearmen (in horde):
Spearmen -> 32 attacks -> 16 hits -> (1/3)*16 = 5.3 ~ 5 wounds
Ghouls -> 9 wounds
* Spearmen have 4 complete ranks while the ghouls have 3. They spearmen didn't charge but they do have an extra rank and full command, so the spearmen lose by 2. The spearmen are also steadfast.
----------------------------