The origin of the -wyn male names and the -wen female names is actually quite interesting.
'gwyn' means 'white' but it also used to mean 'blessed'. The element was added to the names of saints, or supposed saints, particulary those with one-syllable names -wyn for male saints and -wen for female. So you have supposed daughters of Brychan - Dwynwen (patron saint of lovers) originally Dwyn; Ceinwen, originally Cain, meaning 'beautiful'; and also you have Meirwen, from Mair, the Welsh for Mary (the Virgin, obviously).
And then, of course as a PP has mentioned, there's Branwen, from the Mabinogi - both her name and her brother's, Bendigaidfran, mean 'blessed crow' and they are very probably demoted gods or demi-gods, so the 'blessed' epithet may well predate Christianity.
Over time some male names ending in -wyn, both saints' names and names invented later, were turned into female names, so as to have a child named after the father, a grandfather or an uncle in some cases, or because the family just liked the sound. So Tegwyn gave Tegwen, Eirwyn gave Eirwen, Carwyn gave Carwen, Elwyn gave Elwen, Alwyn gave Alwen (also a river name and sometimes used for that reason, as well as in the form Alwenna) - and Arwyn gave Arwen.
-wen was considered such a standard ending that names were invented with it - Anwen from Ann + -wen; Arianwen from Arian (silver) + -wen; Bronwen from Bron (breast) + wen, which is actually a name for the weasel; Blodwen from Blod, an element meaning 'flower', + -wen - these are all fairly recent names.