Dioecy has evolved independently several times during the evolution of flowering plants, but knowledge of the mechanisms involved is poor. Phoenix dactylifera is a dioecious species displaying strong dimorphism between pistillate and staminate flowers, and Daher et al. (pp. 255–266) describe the transition of reproductive buds from a bisexual to a unisexual stage. They find that unisexuality of date palm flowers results from cell cycle arrest of sterile sex organs, rather than from cell death.
A. Daher, H. Adam, N. Chabrillange, M. Collin, N. Mohamed, J. W. Tregear, F. Aberlenc-Bertossi, 2010, 'Cell cycle arrest characterizes the transition from a bisexual floral bud to a unisexual flower in Phoenix dactylifera', Annals of Botany, vol. 106, no. 2, pp. 255-266 http://dx.doi.org/10.1093/aob/mcq103