Rebuild or reset indexes
After purging workflow data, assess index fragmentation to determine if the indexes should be rebuilt or reset.
For more information, see the "Measure and reduce index fragmentation" section of the following TechNet article: Database maintenance for SharePoint 2010 Products.