There are actually scientists that believe there are, and always have been, six sexual roles. Male and female heterosexual, male and female bisexual and male and female homosexual.
The heterosexual role is of course for species propogation.
The bisexual role is to be adaptable and support the tribe in whatever role is needed.
The homosexual role is a bit more specialized. A homosexual female will, by her natural choices, never be so pregnant that she will not be able to go on a hunt, or protect the cave site and the tribe.
A homosexual male will not be in the competition to get as much sperm into as many females as possible.