What is the toll of a function call? Is looping 200,000 times calling a function that performs a small calculation each time a lot more resource intensive than just performing that small calculation inline?

Well, according to this http://hudzilla.org/phpwiki/index.php?title=Avoid_overusing_function_calls it is, and zend.com has the following to say on it

Function calls carry a high overhead. You can get a bump in performance if you eliminate a function. Compiled languages, such as C and Java, have the luxury of replacing function calls with inline code. You should avoid functions that you only call once. One technique for readable code is to use functions to hide details. This technique is expensive in PHP.

in this page about optimizing php http://www.zend.com/zend/trick/trick-optimizing-php.php

commented: Interesting links +11