Ahh - that would be a nice feature, wouldn't it. I've occasionally wanted something like that.
Unfortunately, InfoPath has no way of knowing whether a field is really not being used. It could be used in a view (that would be easy to figure out), or in code (much harder) or in rules, or conditional formatting, or filters, or possibly even a separate form which works on the same data file.
Ultimately, you'll have to manually weed these out.