I have a custom-built MVC PHP framework that I am in the process of rewriting and had a question about performance and magic methods. With the model portion of the framewor
Measure it.
It certainly has a big performance hit, especially considering function calls are expensive in PHP. This difference will be even bigger in the next version of PHP, which implements optimizations that render regular access to declared instance properties significantly faster.
That said, PHP rarely is the bottleneck. I/O and database queries frequently take much more time. This, however, depends on your usage; the only way to know for sure it to benchmark.
That are also other readability problems with the magic methods. They frequently degenerate into one big switch statement and compromise code completion, both of which may be hits in programming productivity.