glob2-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [glob2-devel] scripting language


From: martin . voelkle
Subject: Re: [glob2-devel] scripting language
Date: Wed, 25 May 2005 22:43:42 +0200
User-agent: Internet Messaging Program (IMP) 3.2.7

> >>Are you sure switch makes the same kind of code as above ? I thougth it
> >>made a lot of compare/next steps !
> >>
> >>
> >
> >With any minimally optimizing compiler, yes it does.
> >
> >
> Ok, thanks for the hint, I am quite happy now. This is the final
> argument against the class per bytecode, this can't be done much faster
> as far as I see.
>
> I have just testet gcc with a -S, and with a few cases in the switch, it
> generates the code I feared, but as I add up entries, the code gcc makes
> change to a nice label array, even if not optimizing.

Thanks for checking my optimistic thoughts. Indeed, I had never tested whether
gcc was doing it or not. I'm from the "trust your compiler" school of thought.

Martin




reply via email to

[Prev in Thread] Current Thread [Next in Thread]