is const function faster than non-const?

From: Yuming Ma (ma_yuming_at_yahoo.com)
Date: 12/08/03


Date: Mon, 8 Dec 2003 01:02:43 -0500

consider this:

class X
{
        void foo() const;
        void goo();
}

suppose that foo() and goo() has exactly the same content, is foo() faster
than goo()? what does compiler optomization does to const function?

thanks,

yuming,