Second Test, Lahore (day one, close):
Pakistan v Sri Lanka (317-4)
Samaraweera was one of two centurions for Sri Lanka
Kumar Sangakkara and Thilan Samaraweera hit centuries as Sri Lanka took charge on day one of the second Test.
Umar Gul got Pakistan off to a positive start with two wickets inside the first hour, but Sangakkara (104) stopped the rot with Samaraweera adding 133.
Gul claimed Malinda Warnapura for eight and Tharanga Paranavitana for 21.
Mahela Jayawardene, in his final game as captain, could only add 30 before falling to Gul but the centurions ensured the visitors ended on top.
Having put the visitors into bat, Gul drew blood early on as Warnapura was caught out in the slips by Misbah-ul-Haq.
Paranavitana, in only his second Test, looked good before falling to an impressive catch by Shoaib Malik, but then the batsmen took charge.
Jayawardene and Sangakkara put on 61 runs for the third wicket before the captain became Gul's third victim when he was caught behind.
But this just brought Samaraweera to the crease and the batsmen seemed to feed off one another's confidence as they cranked up the scoring.
Sangakkara was dropped on 55 and wicketkeeper Kamran Akmal put down a chance to claim Samaraweera when he was on 68. The duo went on to put on 204 runs for the fourth wicket.
Samaraweera was the first to reach his century, with consecutive boundaries off Gul, and Sangakkara made it into three figures with a couple of runs off leg-spinner Danish Kaneria.
With eight overs of the day left, paceman Yasir Arafat finally dislodged Sangakkara, having him caught behind.
Bad light brought procedings to a halt with 3.2 overs left, and the visitors well in control.
Pakistan: Younus Khan (capt), Salman Butt, Khurram Manzoor, Shoaib Malik, Misbah-ul-Haq, Faisal Iqbal, Yasir Arafat, Danish Kaneria, Kamran Akmal, Umar Gul, Mohammad Talha.
Sri Lanka: Mahela Jayawardene (capt), Malinda Warnapura, Tharanga Paranavitana, Kumar Sangakkara, Thilan Samaraweera, Tillakaratne Dilshan, Prasanna Jayawardene, Muttiah Muralitharan, Ajantha Mendis, Dilhara Fernando, Thilan Thushara.