  The primitive equations (PEs) model large scale dynamics of the oceans and
the atmosphere. While it is by now well-known that the three-dimensional
viscous PEs is globally well-posed in Sobolev spaces, and that there are
solutions to the inviscid PEs (also called the hydrostatic Euler equations)
that develop singularities in finite time, the qualitative description of the
blowup still remains undiscovered. In this paper, we provide a full description
of two blowup mechanisms, for a reduced PDE that is satisfied by a class of
particular solutions to the PEs. In the first one a shock forms, and pressure
effects are subleading, but in a critical way: they localize the singularity
closer and closer to the boundary near the blow-up time (with a logarithmic in
time law). This first mechanism involves a smooth blow-up profile and is stable
among smooth enough solutions. In the second one the pressure effects are fully
negligible; this dynamics involves a two-parameters family of non-smooth
profiles, and is stable only by smoother perturbations.
