  We define and study the Drinfeld-Lafforgue-Vinberg compactification of the
moduli stack of G-bundles Bun_G for an arbitrary reductive group G; its
definition is given in terms of the Vinberg semigroup of G, and is due to
Drinfeld (unpublished). Throughout the article we prefer to view the
compactification as a canonical multi-parameter degeneration of Bun_G which we
call the Drinfeld-Lafforgue-Vinberg degeneration VinBun_G. We construct local
models for the degeneration VinBun_G which "factorize in families" and use them
to study its singularities, generalizing results of the article [Sch1] which
was confined with the case G = SL_2.
  The multi-parameter degeneration VinBun_G gives rise to, for each parabolic
of G, a corresponding nearby cycles functor. Our main theorem expresses the
stalks of these nearby cycles in terms of the cohomology of the parabolic
Zastava spaces. From this description we deduce that the nearby cycles of
VinBun_G correspond, under the sheaf-function correspondence, to Bernstein's
asymptotics map on the level of functions. This had been speculated by
Bezrukavnikov-Kazhdan [BK] and Chen-Yom Din [CY] and conjectured in a precise
form by Sakellaridis [Sak2].
