Handsome my dog, and round-bodied,
And truly the best of dogs; Dormarth was he, which belonged to Maelgwyn.
Dormarth with the ruddy nose! what a gazer
Thou art upon me because I notice Thy wanderings on Gwibir Vynyd...
Which is quite a curious statement, because why would a real life 6th century chieftain not only present a British God with a dog (unless it was a sacrifice), but that particular hound?
It also seems quite awkwardly placed. In the lines leading into it, the dialogue is all about a terrible battle at Caer Vandwy (God's Peak Fortress), wherein few survived. Gwyn ap Nudd witnessed it all, as he was there in his official capacity as God of the Underworld. (This battle is also mentioned in the Arthurian legend The Spoils of Annwn, where we're told only seven survived amidst both armies.)
So it's 'blah, blah, lots of dead British people, blah, blah, battle - oh! By the way, do you like the lovely dog that Maelgwn Gwynedd gave me? Dormarth's the leader of my pack of Cwn Annwn, you know!' At least that's how it reads to me.
Gwyddno - the 6th century chieftain of a flooded region, which was said to have been located where Cardigan Bay now lies - agrees that the dog is very nice, and comments that he's seen Dormarth running around Gwibir Vynyd (Mountain in the Clouds). Then the conversation promptly switches to the Battle of Arfderydd.
This was a real world clash, dated to circa 573 CE, wherein two chieftains of the Old North slogged it out for sovereignty over a region stretching from Lancashire to Strathclyde, i.e. nowhere near Gwynedd. Though I have recently read at least two attempts to relocate it there, and one which reworked the dates from the Annals Cambraie in order to have Maelgwn fighting at Arfderydd, despite historians generally agreeing that he died nearly thirty years before.
However, one aspect might be relevant. Arfderydd is mostly famous for being the battle after which Merlin went mad. But It's also a renowned clash between a Pagan and a Christian chieftain, seen as one of the earliest such which may have had as much to do with religion as territorial gains.
It's the Pagan leader Gwenddoleu whom Gwyn ap Nudd mentions in the poem, after they've finished talking about Maelgwn's gift of an otherworldly dog. A link is implied, if not directly stated, between Gwenddoleu and Maelgwn.
However, I'd read it all much more specifically than that. To my mind, Gwyn ap Nudd is saying that Maelgwn's gift is to provide protection for the spiritual realm. The fact that the symbolism is a dog could be a play on Maelgwn's own name - Princely Hound, or Warrior Hound - or else could invoke the notion of a guard-dog. Both work and both were probably intended.
And the necessity for Maelgwn's role comes in the fact that Britons are battling Christians and invaders. Unless I'm reading too much into it.
(Another avenue of investigation may be the fact that St Kentigern (trans. Hound Chieftain), aka St Mungo, the legendary founder of Glasgow, was also said to have been at the battle of Arfderydd. The stories attached to him often run so parallel to those told about Maelgwn, that some are downright identical.)
The fact that it's Gwyddno speaking here could also be significant. Melkin's Prophecy states that Britons will never want for water (Britannia will indeed rule the waves). Gwyddno's lands were flooded into oblivion. However water was very sacred to the ancient Cymry. Wells, lakes and rivers tended to be populated with their own deities, and provided access to the spiritual realms. 'Water' could very easily be a metaphor for the Druidic religion.
Moreover, Gwyddno is generally viewed as the (adopted) grandfather of Taliesin. The Welsh Bardic tradition did more than anything else to preserve the legends and histories of the Old Religion, and Taliesin was its undoubted champion.
And he too had a significant series of encounters with Maelgwn Gwynedd.