  Long gamma-ray bursts (GRBs) have been discussed as a potential tool to probe
the cosmic star formation rate (SFR) for a long time. Some studies found an
enhancement in the GRB rate relative to the galaxy-inferred SFR at high
redshifts, which indicates that GRBs may not be good tracers of star formation.
However, in these studies, the GRB rate measured at any redshift is an average
over all galaxies at that epoch. A deep understanding of the connection between
GRB production and environment also needs to characterize the population of GRB
host galaxies directly. Based on a complete sample of GRB hosts, we constrain
the stellar-mass function (SMF) of GRB hosts, and examine redshift evolution in
the GRB host population. Our results confirm that a strong redshift evolution
in energy (with an evolution index of $\delta=2.47^{+0.73}_{-0.89}$) or in
density ($\delta=1.82^{+0.22}_{-0.59}$) is needed in order to account for the
observations. The GRB host SMF can be well described by the Schechter function
with a power-law index $\xi\approx-1.10$ and a break mass
$M_{b,0}\approx4.9\times10^{10}$ ${\rm M}_\odot$, independent of the assumed
evolutionary effects. This is the first formulation of the GRB host SMF. The
observed discrepancy between the GRB rate and the galaxy-inferred SFR may also
be explained by an evolving SMF.
