This question is related to this question: Do deactivated plugins slow down a WordPress site?
When developing a website with custom functionality for a client, particularly a site that will expect lots of traffic, what is better from a performance perspective. To build the functionality into the theme itself or to build it into a plugin? Or is there any performance difference at all?
You’re not going to get a noticeable difference doing it one way over another. Slowness comes from what the code is doing. If you’re worried about performance, just make sure you’re caching external requests whenever you can, that includes calls to the database.