Mail Archives: djgpp/1997/11/16/07:12:41
On 15 Nov 1997, Brian Hogg wrote:
> Functions like cprintf() are too slow and
> maybe it's something I'm doing but it should be optimized...
We can't tell unless you post some code fragment.
If your strings are constant (i.e., you don't need to format them with
"%d", "%f" and such likes), use cputs, which is faster. If you have a
buffer with video attributes ready, or if you don't care about the
attributes, use `dosmemput' to blit it directly to the VRAM.
> how big
> of a difference does the -O2 -O3 -O make to these routines?
None. `cprintf' was already compiled (with -O3) when the library was
created. Nothing you do during compilation of your program can change
the code inside `cprintf'.
- Raw text -