Tata Consultancy Services Ltd. reported quarterly profit that topped analysts’ estimates, helped by cost-cutting measures and a gradually improving contract flow that helped drive growth at Asia’s largest IT services provider.