It is certain that, during the later Early Dynastic Period, Gilgamesh was worshiped as a god at various locations across Sumer. In 21st century BC, King Utu-hengal of Uruk adopted Gilgamesh as his patron deity. The kings of the Third Dynasty of Ur () were especially fond of Gilgamesh, calling him their "divine brother" and "friend." King Shulgi of Ur (2029–1982 BC) declared himself the son of Lugalbanda and Ninsun and the brother of Gilgamesh. Over the centuries, there may have been a gradual accretion of stories about Gilgamesh, some possibly derived from the real lives of other historical figures, such as Gudea, the Second Dynasty ruler of Lagash (2144–2124 BC). Prayers inscribed in clay tablets address Gilgamesh as a judge of the dead in the Underworld.