TIP: Click on subject to list as thread! ANSI
echo: aust_c_here
to: Frank Adam
from: Paul Edwards
date: 1996-08-25 18:06:18
subject: Passing a var.

FA> I didn't word the original question all that well, i should've said 
FA> passing a VARIABLE between a number of functions as opposed to the 
FA> functions using a global. I figure passing a variable would have to take 
FA> a few cycles, unless the compiler does something magical. 

The magical things the compiler can do are:

1. Use registers to pass parameters rather than the stack, and have the
variable ALREADY in the register.

2. Inline the called function.

You really can't tell, and in a real application, you will find that the
time taken to put parameters on the stack is NOT your bottleneck. BFN. 
Paul.
@EOT:

---
* Origin: X (3:711/934.9)

SOURCE: echomail via fidonet.ozzmosis.com

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.