Calling functions by address
Andrew Koenig
ark at alice.UUCP
Thu Sep 1 06:14:17 AEST 1988
> From article <679 at mssx.UUCP>, by src at mssx.UUCP (Pleschutznig Andreas):
> So we thought of doing that job by declaring the addresses of the emulation
> routines and jumping to the routines by address like this
> (*addressarray[code]);
Before you travel this route, I suggest you measure the relative
time it takes to execute a switch vs. to call a function.
You may find that the switch is faster.
--
--Andrew Koenig
ark at europa.att.com
More information about the Comp.lang.c
mailing list