  We perform a series of direct $N$-body calculations to investigate the effect
of residual gas expulsion from the gas-embedded progenitors of present-day
globular clusters (GCs) on the stellar mass function (MF). Our models start
either tidally filling or underfilling, and either with or without primordial
mass segregation. We cover 100 Myr of the evolution of modeled clusters and
show that the expulsion of residual gas from initially mass-segregated clusters
leads to a significantly shallower slope of the stellar MF in the low- ($m\leq
0.50 M_\odot$) and intermediate-mass ($\simeq 0.50-0.85 M_\odot$) regime.
Therefore, the imprint of residual gas expulsion and primordial mass
segregation might be visible in the present-day MF. We find that the strength
of the external tidal field, as an essential parameter, influences the degree
of flattening, such that a primordially mass-segregated tidally-filling cluster
with $r_h/r_t\geq 0.1$ shows a strongly depleted MF in the intermediate stellar
mass range. Therefore, the shape of the present-day stellar MF in this mass
range probes the birth place of clusters in the Galactic environment. We
furthermore find that this flattening agrees with the observed correlation
between the concentration of a cluster and its MF slope, as found by de Marchi
et al.. We show that if the expansion through the residual gas expulsion in
primordial mass segregated clusters is the reason for this correlation then GCs
most probably formed in strongly fluctuating local tidal fields in the early
proto-Milky Way potential, supporting the recent conclusion by Marks \& Kroupa.
