I'm refactoring a WordPress plugin and I have two main classes with an average of 500 lines between the two. There are other files in the plugin, but these are the ones where I keep most of the functionality.
I am refactoring in order to make a more elegant code out of this monster, and separating functionality into other objects to keep my code more cohesive and friendlier for potential contributors.
My intention is to instantiate only one object every time the plugin is used, and get the rest of the functionality out of different classes with static methods (so I won't be needing their state).
Does having many classes in different files have a relevant impact on the system's performance? Considering the situation, is it worth having static functions from auxiliary classes in different files or should I keep everything in fewer files to avoid impacting the system's performance?