•
•
•
•
What is DaniWeb IT Discussion Community?
You're currently browsing the PHP section within the Web Development category of DaniWeb, a massive community of 456,519 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 2,815 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our PHP advertiser: Lunarpages PHP Web Hosting
Views: 618 | Replies: 1
![]() |
•
•
Join Date: Feb 2002
Location: Lawn Guylen, NY
Posts: 11,020
Reputation:
Rep Power: 33
Solved Threads: 116
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?
Dani the Computer Science Gal
Do you run a computer-related website? Feature it in our niche link directory!
Do you run a computer-related website? Feature it in our niche link directory!
Well, according to this http://hudzilla.org/phpwiki/index.ph...function_calls it is, and zend.com has the following to say on it in this page about optimizing php http://www.zend.com/zend/trick/trick-optimizing-php.php
•
•
•
•
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.
![]() |
•
•
•
•
•
•
•
•
DaniWeb PHP Marketplace
•
•
•
•
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
Similar Threads
- Runtime Error - R 6025 - pure virtual function call (Windows NT / 2000 / XP / 2003)
- Variables not updated in JS function call (JavaScript / DHTML / AJAX)
- Can we call a User defined Function using Linked Servers ? (MS SQL)
- no matching function for call to 'strcmp(std::string&, std::string&)' (C++)
- call a function (C)
- Function call problem (HTML and CSS)
- System() Function: Info on uses & Description (C++)
- how to call this function...using menu..! (C++)
Other Threads in the PHP Forum
- Previous Thread: problem with counter
- Next Thread: Replacing strings



Linear Mode