If you create a basic forms library and create and publish a simple InfoPath form to that forms library, you'll notice that when you create a new form (via add document) and save it, SharePoint will automatically populate the out-of-the-box Title field with the name of the form (111.xml). You should change the library's default view to show you the Title so you can see the behavior.
However, renaming the form via Edit Properties will not update the Title field with the new name of the form (222.xml). This is where you would need a workflow.
In SharePoint Designer add a new workflow with a single "Set Field in Current Item" Action. Then configure "Set field" to "Title" and "value" to "[%Current Item:Name%].xml" using the Lookup button in the String Builder dialog. Lastly make sure you check the "Start workflow automatically when an item is changed" in the Workflow Settings and publish your workflow to the library.
Your Title field will now always be up-to-date. The only caveat is that you may need to refresh the view after your updates because the workflow may not be completed before the browser finished rendering the view/page.