Hi Mike,
Thanks to Mary's kindness in looking up the bapt/marriage entries, you have his background fairly well sorted out.
The key pieces of identification were that he was brought up by his maternal grandparents, and appeared with them and other members of the Gilmour/Gilmore family in the 1851 and 1861 censuses.
If you look at the census scan you will see why he was recorded under his mother's name (Cunningham) in 1851 near the bottom of the list of Gilmores, while his mother was near the top - presumably to identify him and his half-brother as her children. Then in 1861 he was recorded under his father's name, in the Manx way, when his mother was not in the household.
I couldn't find any children for Robert Cunningham and Mary Gilmour other than Thomas bapt 26 May 1850 Braddan who was also being brought up by their grandparents, and wondered whether both Robert and Mary died young?
Perhaps Carol will be able to tell us.
This is a possible burial for her (from Brian Lawson's index):
CUNNINGHAM, Mary [aged] 40 [place] Braddan 19 Apr 1864.
Sue