Sri Lanka 134 for 7 (Kamindu 41, Phehlukwayo 3-25) tied with South Africa 134 for 8 (Miller 41, Malinga 2-11)
Super Over South Africa 14 for 0 beat Sri Lanka 5 for 0
Sri Lanka's spinners squeezed and throttled and tugged down the opposition run rate in defence of a modest score, but it was the best slow bowler on show - Imran Tahir - who saw South Africa through a tense Super Over situation, and suggested that whatever his team-mates are like, he is capable of keeping his cool in tough circumstances.
Not choking is important for South Africa. They are in a World Cup year. They have a history of wilting in the heat of a close finish. But in conceding only five runs in the Super Over, Tahir suggested there are players in South Africa's ranks who can thrive in tense circumstances. So too David Miller, who had earlier top-scored with 41 off 23 balls, before hitting a six and a four off Lasith Malinga's Super Over to set the opposition a target of 15. With Tahir in South Africa's ranks, that target always seemed unlikely for Sri Lanka.
Even before the Super Over, though, this was an intriguing low-scoring thriller, during which each team had its moments, even if South Africa were ascendant for the majority. When they had restricted Sri Lanka for 134 for 7 on a slow-ish but not unplayable Newlands surface, the hosts may have expected to cruise to victory. Dhananjaya de Silva, Akila Dananjaya and Jeffrey Vandersay, however, took a wicket apiece and conceded only 81 in their 12 combined overs.
Although the spinners were excellent, Malinga was the real star of the Sri Lanka bowling innings. He conceded a four off his second ball - and that only off an outside edge off Quinton de Kock's bat, that flew to the third-man boundary. He did not allow the opposition a boundary thereafter in regular play, bowling an especially outstanding pair of death overs, in which his figures were three runs for two wickets.
Thanks to Malinga, Isuru Udana still had five to defend off the last over of the innings. He conceded a single to JP Duminy - the last recognised batsman - first ball, then delivered two slower-ball dot balls to Dale Steyn to make the equation four from three balls. Duminy was run out soon after, but then off the last ball of regular play, perhaps, came the key moment of the innings.
South Africa had two to get, with No. 10 batsman Tahir on strike. He bottom-edged the last ball of the innings to keeper Niroshan Dickwella, who should have easily run out non-striker Steyn and won Sri Lanka the match. Dickwella, though, failed to take his glove off, and his shy at the strikers' end missed - Steyn comfortably out by a couple of metres had Dickwella hit at least one of the stumps. His team-mates' annoyance at Dickwella's mistake was plainly obvious in the break between regular play and the Super Over.
Tahir's final over was perhaps the most dramatic performance of an intense T20 match, but Miller's performance was also key to South Africa's victory. Not only did he eventually pummel Malinga - who had figures of 2 for 11 from his four overs in regular play - he had also led South Africa past 100 in the chase.
Miller had arrived at the crease with the score on 52 for 3 and South Africa tracking at less than a run a ball - Sri Lanka's spinners having tied the hosts down. He was immediately aggressive, however, slapping Vandersay for four through cover first ball, before slog sweeping him to the boundary in Vandersay's next over.
It was against Udana, though, that Miller truly accelerated, and swung the match in favour of South Africa. In the 15th over of the innings, with South Africa needing 52 off 36 balls, Miller smoked three fours, a six and a two, single-handedly taking 20 off that over.
Malinga's outstanding death overs would later see Miller dismissed, and push Sri Lanka to a position where they could dream again with South Africa's tailenders now in residence at the crease. Slower-ball specialist Udana did deliver an excellent final over, in which the only real pockmark for Sri Lanka was Dickwella's game-defining missed run-out.
Earlier, Kamindu Mendis had been the only Sri Lanka batsman who looked halfway fluent on this pitch, even if he did score all but one of his boundaries - three fours and two sixes in total - off the first eight deliveries that he faced. In that initial period, he hit his first six by top-edging Kagiso Rabada over third man, before ramping him over the same boundary next ball. Kamindu scored 41 off 29 balls, but none of his team-mates could cross 20.
Andile Phehlukwayo was the best of South Africa's bowlers, taking 3 for 25 from his four overs. Lutho Sipamla was the next best, claiming 1 for 19. All South Africa's bowlers took at least one wicket apiece.
Andrew Fidel Fernando is ESPNcricinfo's Sri Lanka correspondent. @afidelf