As per Hindu legend, a ruler named Vallabhadeva went incognito everyday to know about the lives of people under him. During one of his visits, a scholar told him that the ultimate goal in life is to collect provisions in summer and save for winter, which also meant that one should work during his younger days and save for his old age. Vallabadeva was not convinced and he set this as a competition among scholars to make him realize the true value of life. Vishnucitta, who would later go on to become Periazhwar, one of the twelve most revered saints of Vaishnava sect, came to Madurai from Srivilliputhur. He was believed to have been directed by the heavenly words of Vishnu and he expouned the sacred verses. He explained the concepts of Hitham and Purushartham from Vedas and proclaimed that attained the feet of Narayana could lead to salvation. Vallabhadeva was pleased with the explanation and he awarded a bag of gold to Visnucitta. It is believed that the current gopuram of Srivilliputhur Temple, was built by Periazhwar with the gold won.