Most of the time when cells divide, they begin by duplicating their genetic content and sharing it between the resulting daughter cells, giving each a complete set of chromosomes. During meiosis, chromosomes do not duplicate first, and each cell receives a half-set after it divides.
While most cell division allows plants to grow, meiosis occurs specifically for producing sex cells. When an egg and sperm unite during sexual reproduction, the half-sets of chromosomes found in each cell unite to give the resulting offspring a full set of genetic material. Where meiosis occurs in a vascular plant depends on the type of vascular plant.
Spore-producing vascular plants such as the ferns develop small spots called sori on the undersides of their leaves. These sori consist of many tiny structures called sporangia. Meiosis occurs in the sporangia, producing spores with the potential to develop into structures that produce the fern's sex cells.
In seed plants, separate male and female structures within the plant undergo meiosis to produce sperm and egg cells, respectively. Microsporangia -- located in the male cones for gymnosperms and the anthers for flowering plants -- produce sperm cells through meiosis. Inside of the female cone or the ovary of the flower, megasporangia give rise to egg cells through meiosis.