The purpose, as stated in the constitution, is "to promote the Progress of Science and useful Arts".
This often means protecting the profits of the IP owners, but not always, for example see "copyright misuse".