[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Texmacs-dev] Efficiency of C++ switch-statements
From: |
Joris van der Hoeven |
Subject: |
[Texmacs-dev] Efficiency of C++ switch-statements |
Date: |
Mon, 10 Nov 2003 16:32:07 +0100 (CET) |
Hi *,
Can anyone provide me with some information on how well
the C++ switch-statement is being optimized?
I am interested in the following situation: I have 150 built-in
TeXmacs tags and a few places in the code where some action has
to be undertaken which is different for about 10 tags and
the same for the remaining 140 tags. So I use a switch with
a "default:". My question is: does C++ use table lookup for
immediately jumping to the right location (the tables would
clearly be quite sparse)?
Another question: if I do not put the cases in the same order
as the enumeration, does this alter the efficiency?
Thanks in advance for your help, Joris
- [Texmacs-dev] Efficiency of C++ switch-statements,
Joris van der Hoeven <=